Daphne Control Help
-
@bassman6805 said in Daphne Control Help:
I think it is somehow mapped to a keyboard.
If that turns out to be true, then it's actually a big plus for Daphne. Currently, standard joystick support is pretty rudimentary in Daphne. It cannot be remapped in any way and if it doesn't get assigned to js0 during your session, Daphne can't even see it. However, keyboard assignments are much more flexible here.
If the controls do end up being key-based, you'll need to discover which keyboard keys are being generated by running
evtest
on the keyboard event and then use this page to see what numbered codes those keys translate to. From there, you'd just add the numbers to their proper locations indapinput.ini
. It's admittedly a bit like decoding Little Orphan Annie's secret message, but it should work well for you if you are in fact dealing with keyboard controls. -
Ok. I think the evtest might be what I need to do. When I tried the jtest it never showed the joy0. Just event0, event1. Which I am guessing is the keyboard controller and the usb hub I had plugged in. I will try it this evening and post my results.
-
Here are the results for the evtest. Any idea on what numbers to change on the daphne.ini? 1st, 2nd, or 3rd column?
Input driver version is 1.0.1 Input device ID: bus 0x3 vendor 0x1 product 0x1 version 0x1 Input device name: "retrogame" Supported events: Event type 0 (EV_SYN) Event type 1 (EV_KEY) Event code 1 (KEY_ESC) Event code 16 (KEY_Q) Event code 17 (KEY_W) Event code 28 (KEY_ENTER) Event code 30 (KEY_A) Event code 31 (KEY_S) Event code 44 (KEY_Z) Event code 45 (KEY_X) Event code 103 (KEY_UP) Event code 105 (KEY_LEFT) Event code 106 (KEY_RIGHT) Event code 108 (KEY_DOWN) Properties: Testing ... (interrupt to exit) Event: time 1508808873.707404, type 1 (EV_KEY), code 108 (KEY_DOWN), value 1 Event: time 1508808873.707404, -------------- EV_SYN ------------ Event: time 1508808873.984816, type 1 (EV_KEY), code 108 (KEY_DOWN), value 0 Event: time 1508808873.984816, -------------- EV_SYN ------------ Event: time 1508808878.052055, type 1 (EV_KEY), code 103 (KEY_UP), value 1 Event: time 1508808878.052055, -------------- EV_SYN ------------ Event: time 1508808878.303562, type 1 (EV_KEY), code 103 (KEY_UP), value 0 Event: time 1508808878.303562, -------------- EV_SYN ------------ Event: time 1508808880.872279, type 1 (EV_KEY), code 105 (KEY_LEFT), value 1 Event: time 1508808880.872279, -------------- EV_SYN ------------ Event: time 1508808881.057428, type 1 (EV_KEY), code 105 (KEY_LEFT), value 0 Event: time 1508808881.057428, -------------- EV_SYN ------------ Event: time 1508808881.748917, type 1 (EV_KEY), code 106 (KEY_RIGHT), value 1 Event: time 1508808881.748917, -------------- EV_SYN ------------ Event: time 1508808881.916709, type 1 (EV_KEY), code 106 (KEY_RIGHT), value 0 Event: time 1508808881.916709, -------------- EV_SYN ------------ Event: time 1508808883.058113, type 1 (EV_KEY), code 1 (KEY_ESC), value 1 Event: time 1508808883.058113, -------------- EV_SYN ------------ Event: time 1508808883.261601, type 1 (EV_KEY), code 1 (KEY_ESC), value 0 Event: time 1508808883.261601, -------------- EV_SYN ------------ Event: time 1508808884.043804, type 1 (EV_KEY), code 28 (KEY_ENTER), value 1 Event: time 1508808884.043804, -------------- EV_SYN ------------ Event: time 1508808884.194038, type 1 (EV_KEY), code 28 (KEY_ENTER), value 0 Event: time 1508808884.194038, -------------- EV_SYN ------------ Event: time 1508808886.715256, type 1 (EV_KEY), code 30 (KEY_A), value 1 Event: time 1508808886.715256, -------------- EV_SYN ------------ Event: time 1508808886.910315, type 1 (EV_KEY), code 30 (KEY_A), value 0 Event: time 1508808886.910315, -------------- EV_SYN ------------ Event: time 1508808887.382060, type 1 (EV_KEY), code 45 (KEY_X), value 1 Event: time 1508808887.382060, -------------- EV_SYN ------------ Event: time 1508808887.557515, type 1 (EV_KEY), code 45 (KEY_X), value 0 Event: time 1508808887.557515, -------------- EV_SYN ------------ Event: time 1508808889.027526, type 1 (EV_KEY), code 44 (KEY_Z), value 1 Event: time 1508808889.027526, -------------- EV_SYN ------------ Event: time 1508808889.185223, type 1 (EV_KEY), code 44 (KEY_Z), value 0 Event: time 1508808889.185223, -------------- EV_SYN ------------ Event: time 1508808889.755801, type 1 (EV_KEY), code 31 (KEY_S), value 1 Event: time 1508808889.755801, -------------- EV_SYN ------------ Event: time 1508808889.923615, type 1 (EV_KEY), code 31 (KEY_S), value 0 Event: time 1508808889.923615, -------------- EV_SYN ------------ Event: time 1508808891.277758, type 1 (EV_KEY), code 17 (KEY_W), value 1 Event: time 1508808891.277758, -------------- EV_SYN ------------ Event: time 1508808891.467049, type 1 (EV_KEY), code 17 (KEY_W), value 0 Event: time 1508808891.467049, -------------- EV_SYN ------------ Event: time 1508808892.993258, type 1 (EV_KEY), code 16 (KEY_Q), value 1 Event: time 1508808892.993258, -------------- EV_SYN ------------ Event: time 1508808893.232212, type 1 (EV_KEY), code 16 (KEY_Q), value 0 Event: time 1508808893.232212, -------------- EV_SYN ------------
-
The first two columns are for keys. I've always presumed those represent players one and two respectively, so you'll want to alter the numbers in the first column for the first controller. As mentioned earlier, use this page to translate the keys into the appropriate number code. For example, I see your directional pad uses the standard up, down, left and right keys, so that that would work out to 'up' being 273, 'down' 274, 'left' 276 and 'right' 275. In
dapinput.ini
, that would look like:KEY_UP = 273 0 0 KEY_DOWN = 274 0 0 KEY_LEFT = 276 0 0 KEY_RIGHT = 275 0 0
Which might not be the best example, as that's what it's set to by default, but you get the idea. I changed the 2nd and 3rd column in this example to zeros (meaning 'none') just to emphasize the first column.
-
Thanks for the help. That solved it. This unit I have is a raspberry pi A and I'm guessing it doesn't have the power to run the game because it seems to have problems keeping up with the screen. Maybe it's better suited for a Pi 3?
-
@bassman6805 said in Daphne Control Help:
Thanks for the help. That solved it. This unit I have is a raspberry pi A and I'm guessing it doesn't have the power to run the game because it seems to have problems keeping up with the screen. Maybe it's better suited for a Pi 3?
Whats the game?
-
Dragon's lair
-
I believe it wasn't until the Raspberry Pi 2 that MPEG-2 could be decoded in software. However, there is the option of buying a £2.40/$3.33 license for hardware MPEG-2 decoding on the Raspberry Pi 1. Someone knowing more about the back-end of Daphne would need to confirm whether or not this would affect Daphne specifically, but I used to watch my own DVD (MPEG-2) backups with Kodi on my Raspberry Pi 1 using this and it worked very well there.
-
@mediamogul said in Daphne Control Help:
The first two columns are for keys. I've always presumed those represent players one and two respectively
That's very helpful. I have looked at those numbers many times and always wondered why they had two inputs for one player but it's actually one input for two players. I would guess the joystick input is a bonus for those console users. :)
The ini file has this at the top:
# Daphne cutom keyboard and joystick mapping # # Each input is mapped to 2 keyboard keys and one joystick button. # A joystick's first analog stick is also automatically mapped. # # The first two numbers are SDL keyboard codes (or 0 for "none") # Find keyboard codes here: # http://www.daphne-emu.com/mediawiki/index.php/KeyList # # The third number is the joystick button code (or 0 for "none") # Since 0 is reserved for special meaning, joystick button 0 is identified # as 1 here. Button 1 is identified as 2, and so on. # # Find the button you want to map by running: # jstest /dev/input/js0
-
@riverstorm said in Daphne Control Help:
but it's actually one input for two players.
That's my guess. Most of the actual Laserdisc cabinets I've seen over the years featuring two player games, make use of one joystick and rely on the players to trade off when it's their turn. It could be nice to have separate controllers mapped so that you don't have to pass one back and forth across a room. On the other hand, having two sets of controls would rely heavily on the honor system to prevent the competitors from sabotaging each other as they play.
-
@mediamogul said in Daphne Control Help:
Most of the actual Laserdisc cabinets I've seen over the years featuring two player games, make use of one joystick and rely on the players to trade off when it's their turn.
I remember those days standing off to the side and moving in place for you turn. The popular games had quarters on the marquee for the next player. Or just adding a few extra for your own. Dragon's Lair having a TV on top and a crowd gathered around it watching each player memorizing the moves. We had a few crazy people that hung in our group that would lift the marquees up and out and reach inside. Some games had a credit button down inside aways.
Next time I have it up I will map the secondary and try it out. I know you do some advanced work with controllers. Two keys for each action would pretty much force 2 players to 1 device (keyboard/IPAC mappings) but then again that could just as easily be 2 sets of controls to one device like an IPAC. Just catching up with what you wrote above being the honor system. :)
-
@riverstorm said in Daphne Control Help:
then again that could just as easily be 2 sets of controls to one device like an IPAC.
Very true. The logic behind Daphne's unconventional control implementation is hard to get a handle on. With all the issues regarding the joystick alone, It almost seems like the whole thing was added in haste as an afterthought. Still, it works well enough with some effort and it's great to be able to play these games on the Pi. Daphne's addition to RetroPie was the whole reason I started using it to begin with.
-
@mediamogul said in Daphne Control Help:
Daphne's addition to RetroPie was the whole reason I started using it to begin with.
Wow, then it might be worth mentioning if you don't know there's was a HD version of Dragon's Lair and Space Ace floating around which was derived from the original HD or Blu-ray discs. Someone put a ton of work into manually extracting, cutting, timing and building all the video to parse and work with Daphne as you can't use the disc itself directly/automatically.
I believe the HD and blu-ray discs were created using cleaned up original negatives vs the original laser disc. They look much, much better than the "stock" video files. Being a Daphne fan you would love it as they look and work great on the Pi.
I am presume if you own the HD or Blu-ray it might be worth looking into as it seems it would be legal to use as they are the same files you purchased already. Both HD and blu-ray came from the cleaned up originals. It does seem to be a gray area but worth mentioning.
Nothing like that prepubescent crush on Daphne that you could never admit to your friends as a teenager but don't care as an adult. Lusting over pixels, those were the days of complications or so we thought. :) It was about as good as Lady Lisa in Adam Sandler's Pixels. Bad movie but some classic moments.
-
@riverstorm said in Daphne Control Help:
a HD version of Dragon's Lair and Space Ace floating around
I actually do have it and have been meaning to incorporate it into my RetroPie install. I've played the game in so many forms over the years. I used to be able to get through the whole thing on one life, but I haven't tried that in some time. The most unusual time I've ever played the game was on a Tandy computer back in the day. A friend of mine had it and we wanted to play it one afternoon. A scene would take forever to load, so we would go outside and play some basketball while we waited. Occasionally we'd go in and the scene would be ready. We'd input our one or two movements to hopefully move forward and the whole thing would start loading again. I don't remember us getting very far.
-
@mediamogul said in Daphne Control Help:
The most unusual time I've ever played the game was on a Tandy computer back in the day.
That's impressive to get through with one player. I was never quite that good but the enjoyment was off the hook. You'll enjoy the updated graphics.
That was my first computer I actually purchased fully out of my own pocket. Tandy 1000 HX with dual 3.5 floppies that held a whopping 720KB per floppy. It had 256KB of RAM expanded to 640KB. It seems weird that those old systems worked in less than 1MB of RAM. No hard drive.
We also would type in old BASIC programs into a VIC-20 similar to Zork but smaller. Back then it was still fun even knowing every possible outcome to every decision.
I have no idea how we survived the incredibly long load times on the C64. I do remember some of the games like Karateka taking 20 to 30 minutes to load.
Some say Moore's Law is coming to a close well at least for silicon. I suppose that's ok we'll just use our computers longer or prices won't drop as quickly or who knows really. I don't know if it's Intel or consumers driving the market to buy bigger and better every few years or companies like Apple that make it a yearly party to repurchase everything. It hardly seems a necessity nowadays but technology is interesting none the less!
Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.
Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.