Solved GPIO with RPi 1 (26 PIN GPIO)
I cannot configure my (BarTop) Joystick.
And here is, what I tried in my .conf file.
(of course I also tried standard config)
------------ D2 - GPIO Controllers ------------
enable controllers on GPIO with mk_arcarde_joystick_rpi (0,1)
mk_gpio arguments, map=1 for one controller, map=1,2 for 2 (map=1,map=1,2)
Custom mk_gpio arguments,
map=5 gpio1=Y-,Y+,X-,X+,start,select,a,b,tr,y,x,tl,hk for one controller,
map=5,6 gpio1=Y-,Y+,X-,X+,start,select,a,b,tr,y,x,tl,hk gpio2=Y-,Y+,X-,X+,start,select,a,b,tr,y,x,tl,hk for 2 (map=5,map=5,6)
map=5,6 gpio1=gpiox,gpioy,gpioz,.....,gpiou,gpiov gpio2=gpiox,gpioy,gpioz,.....,gpiou,gpiov
where gpiox,gpioy,gpioz ... are NOT pin numbers on the connector, BUT location gpio numbered as in
Set pin to -1 to disable it
MCP configuration : GPIO and MCP can be used together. You can mix them.
map=0x20,0x21 for 2 mcp23017 on i2c bus
#controllers.gpio.args=map=0x20,0x21,5,6 gpio=4,17,27,22,10,9,25,24,23,18,15,14,-1 gpio2=11,5,6,13,19,26,21,20,16,12,7,8,-1
It just doesn't work at all.
@Raketenmann You need to check with a ssh connection and linux commands that le mk_arcade module il well loaded. After, use evtest to test each button and joystick direction. Which rela**e of rpi1 do you have ? 512B b+ ?
thanks for the quick answer.
The module is loaded - it seams to me:
Module Size Used by Tainted: G
mk_arcade_joystick_rpi 4442 0
And here is the output from the evtest:
Input driver version is 1.0.1
Input device ID: bus 0x15 vendor 0x1 product 0x1 version 0x100
Input device name: "GPIO Controller 1"
Event type 0 (EV_SYN)
Event type 1 (EV_KEY)
Event code 304 (BTN_SOUTH)
Event code 305 (BTN_EAST)
Event code 307 (BTN_NORTH)
Event code 308 (BTN_WEST)
Event code 310 (BTN_TL)
Event code 311 (BTN_TR)
Event code 314 (BTN_SELECT)
Event code 315 (BTN_START)
Event code 316 (BTN_MODE)
Event type 3 (EV_ABS)
Event code 0 (ABS_X)
Event code 1 (ABS_Y)
But no reaction on any input.
RPi Version: Pi Model B Rev 2
(thats the output from cat /sys/firmware/devicetree/base/model)
@Raketenmann which release of RB are you running because with 6.0 I made a mistake in the mk_arcade module preventing pi0 ans pi1 to work with gpio see here https://github.com/recalbox/mk_arcade_joystick_rpi/issues/71. Please try the last beta 3 or DL the new mk_arcade_joystick_rpi.ko at https://mega.nz/#!y9kCEI7I!7HdyKzhWS4HhfVgpvj7SM9RbnLwMUlGXoUqcxzuFCQM
replace the /lib/modules/4.14.62/extra/mk_arcade_joystick_rpi.ko with the new one and enjoy
it might be a stupid question. But how to copy the file?
cp: can't create '/lib/modules/4.14.62/extra/mk_arcade_joystick_rpi.ko': File exists
Sure. But if I try to delete it - even with root / su
rm: can't remove 'mk_arcade_joystick_rpi.ko': Read-only file system
BTW - Recalbox UI shows there is an update available if I switch to "BETA". But the download fails.
mount -o remount,rw /
Thank you Gentlemen!
Not perfect. But I received a first feedback while configure controls. Rest will be easy and fixed in the config file later today.
You may close this!
@raketenmann Do not try to update :), It would downgrade to 6.0 I think
First I tried to update. Did not worked.
Thats why I changed the File by using the shared folder and SSH.
Now- as it works - I will keep it until the next official release where you hopefully take care on RPi 1 users.
Again: great support.
@raketenmann I hope to :), but Pi0 is very close to Pi1 of first gen... so it shoulb be