Active Threads | Active Posts | Unanswered Today | Since Yesterday | This Week
MAME Jump to new posts
c64 super sketch Golden Child 09/17/19 08:08 PM
Thanks to a suggestion from rfka1, I thought I'd try my hand at figuring out the Super Sketch on the c64.

It looks like it just reads the potentiometer inputs, so let's do some driver mangling to see what happens:



Code

add some member variables to hold an analog inputs


-               m_va15(1)
+               m_va15(1),
+m_test_joy1x(*this, "TEST_analog_joystick_1_x"),
+m_test_joy1y(*this, "TEST_analog_joystick_1_y")
+

+
+required_ioport m_test_joy1x,m_test_joy1y;
+
 };
 
 
add some defines for an analog input
 
+
+#define JOYSTICK_DELTA          80
+#define JOYSTICK_SENSITIVITY    50
+#define JOYSTICK_AUTOCENTER     80
+
+

+        PORT_START("TEST_analog_joystick_1_x")      /* Joystick 1 X Axis */
+        PORT_BIT( 0xff, 0x80, IPT_AD_STICK_X) PORT_NAME("TEST Joystick X")
+        PORT_SENSITIVITY(JOYSTICK_SENSITIVITY)
+        PORT_KEYDELTA(JOYSTICK_DELTA)
+        PORT_CENTERDELTA(JOYSTICK_AUTOCENTER)
+        PORT_MINMAX(0,0xff) PORT_PLAYER(1)
+        PORT_CODE_DEC(KEYCODE_4_PAD)    PORT_CODE_INC(KEYCODE_6_PAD)
+        PORT_CODE_DEC(JOYCODE_X_LEFT_SWITCH)    PORT_CODE_INC(JOYCODE_X_RIGHT_SWITCH)
+
+        PORT_START("TEST_analog_joystick_1_y")      /* Joystick 1 Y Axis */
+        PORT_BIT( 0xff, 0x80, IPT_AD_STICK_Y) PORT_NAME("TEST Joystick Y")
+        PORT_SENSITIVITY(JOYSTICK_SENSITIVITY)
+        PORT_KEYDELTA(JOYSTICK_DELTA)
+        PORT_CENTERDELTA(JOYSTICK_AUTOCENTER)
+        PORT_MINMAX(0,0xff) PORT_PLAYER(1)
+        PORT_CODE_DEC(KEYCODE_8_PAD)    PORT_CODE_INC(KEYCODE_2_PAD)
+        PORT_CODE_DEC(JOYCODE_Y_UP_SWITCH)      PORT_CODE_INC(JOYCODE_Y_UP_SWITCH)
+
+
 INPUT_PORTS_END
 

mangle the sid_pot reads, we'll just always return the m_joy1x or m_joy1y for cases 1,2,3.
 
READ8_MEMBER( c64_state::sid_potx_r )
 {
        uint8_t data = 0xff;
 
        switch (m_cia1->pa_r() >> 6)
        {
       
       case 1:
       case 2:
       case 3: data=m_test_joy1x->read(); break;

        }
 
        return data;
}
READ8_MEMBER( c64_state::sid_poty_r )
 {
        uint8_t data = 0xff;
 
        switch (m_cia1->pa_r() >> 6)
        {

       case 1:
       case 2:
       case 3: data=m_test_joy1y->read();
       break;
        }
 
        return data;
}


then you can change the potx and poty values with the analog input, and the digital joystick up/down/left and right will do the buttons for the pad.


To get past the initial screen put the joystick down in the lower right and press the digital down (I think that's the menu button).

[Linked Image from i.imgur.com]
[Linked Image from i.imgur.com]
some drawing (as best as I can with the numeric keypad masquerading as an analog joystick setting the analog speed/sensitivity to low values, I can't get the MouseX to map into the analog input in the UI menus)
[Linked Image from i.imgur.com]

I found a different SUPER-SKETCH.D64 but I could never get past the menu, wasted a few hours with that. There's also a .crt file but I couldn't get it to load.


make -j4 SOURCES=src/mame/drivers/c64.cpp SUBTARGET=myc64

./myc6464 c64 -joy1 joy -flop ../../supersketch-Uncredited-sb168350-Page-ZimmermanSet2.d64


There's still some puzzles to figure out (like why it wants to clock in a bunch of reads from the digital joystick inputs), but at least it does something.
0 18 Read More
Non-Windows MAME Support Jump to new posts
Re: 0.213 arcade OSX Popeye audio bug MacBox360 09/17/19 07:54 PM
Just compiled the GitHub snapshot, I confirm the issue is gone. Thank you very much! :-)
18 248 Read More
MAME Jump to new posts
Re: BletchMAME 1.0 has been released Bletch 09/17/19 02:05 PM
Googling around further, it sounds like if wxUSE_STD_STRING is off, then wxString doesn't derive from std::basic_string at all. I'm pretty dependent on that, and if that is indeed the case I suspect you may have bigger problems.
11 737 Read More
MAME Jump to new posts
Re: PC/XT/AT (inside) WIP topic rfka01 09/16/19 10:25 AM
I've uploaded an archive with stuff for the Toshiba T3200 Laptop.
2,604 4,316,850 Read More
MAME Jump to new posts
Re: TMS-09xx/1xxx thread (was New Dumps) hydef 09/15/19 09:17 PM
Added Judge and changed tons of games. Mainly remade all of the Wide Screen games

[Linked Image from ]

Thanks for the info about the bubbles and stuff, sorry I haven't been replying to it all, I've been trying to make loads of adjustments. I added bubbles to more games than you said, like Chef and Popeye because I saw them on some pictures but if no one likes them, just override them with some blank pngs.
3,308 2,002,900 Read More
MAME Jump to new posts
Re: 8bit Apples - Apple I, II, /// and the 16 bit GS R. Belmont 09/15/19 08:04 PM
I didn't know the Wico trackball existed. Should be easy enough to hook up. That code indicates they won't accept values > 0xdc, and that's obviously to keep the character out of the score area on the right.

Apple paddle support too!
491 68,429 Read More
MAME Jump to new posts
Re: Mindset driver? TSCHAK 09/13/19 07:50 PM
Just letting you know, I have to give this machine back, soon...

-Thom
70 5,905 Read More
QMC2 Jump to new posts
Re: QMC2 Invalid Configuration couriersud 09/11/19 07:56 PM
No problems here with 0.196 (SVN R8298): Ubuntu 16.04 and mame 0.213.

Originally Posted by R. Belmont
Yeah, Rene is still recovering from a stroke. Everyone reading this please take care of yourself!


Yes, how true. And don't push anything you'd like to do into the future. Do it now.
3 90 Read More
Who's Online Now
2 registered members (Dorando, 1 invisible), 82 guests, and 3 spiders.
Key: Admin, Global Mod, Mod
ShoutChat Box
Comment Guidelines: Do post respectful and insightful comments. Don't flame, hate, spam.
Forum Statistics
Forums9
Topics8,683
Posts114,009
Members4,863
Most Online510
Aug 26th, 2019
Powered by UBB.threads™ PHP Forum Software 7.7.3