Author Topic: Joystick configuration with SDL2 on Linux  (Read 3733 times)

Offline hatta

  • New Member
  • *
  • Posts: 1
  • Karma: +0/-0
Joystick configuration with SDL2 on Linux
« on: July 04, 2024, 04:59:14 PM »
I am running FB Neo with SDL2 on Linux.  Only Player 2 gets a joystick. 

Not sure where the joystick configuration is stored.  How do I fix this?

Code: [Select]
FBNeo v1.0.0.03
Loading config from /home/hatta/.local/share/fbneo/config/fbneo.ini
Found a game controller: Logitech Dual Action
*** Starting emulation of cadashf - Cadash (France).
Cheat cpu-register INIT.
Hi Score Memory Range 0 Loaded from file
68K #1 Rom Length 080000, (4 roms)
Z80 #1 Rom Length 010000, (1 roms)
Char Rom Length 00080000, (1 roms, 0x000000 tiles)
Sprite A Rom Length 00080000, (1 roms, 0x000000 tiles)
Loading program (c21_19.ic11)... (OK)
Loading program (c21_21.ic15)... (OK)
Loading program (c21_18.ic10)... (OK)
Loading program (c21_20.ic14)... (OK)
Loading program (c21-08.38)... (OK)
Loading graphics (c21-02.9)... (OK)
Loading graphics (c21-01.1)... (OK)
YM2151: Using FM-Timer.
BurnTimerInit: base index 0, #chips 1
BurnTimer chip_base: 0
YM2151: Using Buffered-mode.
Hi Score Memory Range 0 Initted
SDLSoundInit (44100Hz) (6000FPS)
Game resolution: 320x240@60.000000
bbp: 32
setting logical size w: 320 h: 240
nVidImageWidth=320 nVidImageHeight=240 nVidImagePitch=1280
Malloc for video Ok 307200
p1 coin 5
p1 start 1
p1 up ARROW UP
p1 down ARROW DOWN
p1 left ARROW LEFT
p1 right ARROW RIGHT
p1 fire 1 Z
p1 fire 2 X
p2 coin 6
p2 start 2
p2 up Joy 0 Up (Y negative)
p2 down Joy 0 Down (Y positive)
p2 left Joy 0 Left (X negative)
p2 right Joy 0 Right (X positive)
p2 fire 1 Joy 0 Button 0
p2 fire 2 Joy 0 Button 1
reset F3
service 9
tilt T
dip code 0xFE
dip code 0xFF
loading state 0 /home/hatta/.local/share/fbneo/config/games/cadashf.fs
Applied Hi Score Memory Range 0 on frame number 124
saving state 0 /home/hatta/.local/share/fbneo/config/games/cadashf.fs
 ** Emulation ended (running for 2.58 seconds).
    100.00% of frames rendered (151 out of a total 151).
    60.00 frames per second (average).

Offline taoenwen

  • Newbies
  • *
  • Posts: 12
  • Karma: +0/-0
Re: Joystick configuration with SDL2 on Linux
« Reply #1 on: July 05, 2024, 01:21:06 PM »
I am running FB Neo with SDL2 on Linux.  Only Player 2 gets a joystick. 

Not sure where the joystick configuration is stored.  How do I fix this?

Code: [Select]
FBNeo v1.0.0.03
Loading config from /home/hatta/.local/share/fbneo/config/fbneo.ini
Found a game controller: Logitech Dual Action
*** Starting emulation of cadashf - Cadash (France).
Cheat cpu-register INIT.
Hi Score Memory Range 0 Loaded from file
68K #1 Rom Length 080000, (4 roms)
Z80 #1 Rom Length 010000, (1 roms)
Char Rom Length 00080000, (1 roms, 0x000000 tiles)
Sprite A Rom Length 00080000, (1 roms, 0x000000 tiles)
Loading program (c21_19.ic11)... (OK)
Loading program (c21_21.ic15)... (OK)
Loading program (c21_18.ic10)... (OK)
Loading program (c21_20.ic14)... (OK)
Loading program (c21-08.38)... (OK)
Loading graphics (c21-02.9)... (OK)
Loading graphics (c21-01.1)... (OK)
YM2151: Using FM-Timer.
BurnTimerInit: base index 0, #chips 1
BurnTimer chip_base: 0
YM2151: Using Buffered-mode.
Hi Score Memory Range 0 Initted
SDLSoundInit (44100Hz) (6000FPS)
Game resolution: 320x240@60.000000
bbp: 32
setting logical size w: 320 h: 240
nVidImageWidth=320 nVidImageHeight=240 nVidImagePitch=1280
Malloc for video Ok 307200
p1 coin 5
p1 start 1
p1 up ARROW UP
p1 down ARROW DOWN
p1 left ARROW LEFT
p1 right ARROW RIGHT
p1 fire 1 Z
p1 fire 2 X
p2 coin 6
p2 start 2
p2 up Joy 0 Up (Y negative)
p2 down Joy 0 Down (Y positive)
p2 left Joy 0 Left (X negative)
p2 right Joy 0 Right (X positive)
p2 fire 1 Joy 0 Button 0
p2 fire 2 Joy 0 Button 1
reset F3
service 9
tilt T
dip code 0xFE
dip code 0xFF
loading state 0 /home/hatta/.local/share/fbneo/config/games/cadashf.fs
Applied Hi Score Memory Range 0 on frame number 124
saving state 0 /home/hatta/.local/share/fbneo/config/games/cadashf.fs
 ** Emulation ended (running for 2.58 seconds).
    100.00% of frames rendered (151 out of a total 151).
    60.00 frames per second (average).

p1 up ARROW UP
p1 down ARROW DOWN
p1 left ARROW LEFT
p1 right ARROW RIGHT

While I know nothing about SDL, from what you've provided, it appears that the P1's directional button setting is the default keypad, have you tried switching to the controller you specified?