0

Arduino Joystick Recorder

I have built this little setup, which is supposed to record and replay input from a classic 9-pin Joystick. I connected the 9 pin connectors to the Arduino, read the input on the left side from the Joystick, and then passed it to the right side by setting the corresponding pins to HIGH.

It does work, and I can play games on the Commodore 64, however, I noticed that with this setup current is passed to the Commodore 64, which is very likely harming the machine a lot (I stopped immediately after noticing).

So my question is: how do I need to modify this setup so that no current is going from the Arduino to the Commodore 64 anymore?

Picture of the setup:

Setup

ocrdu
1,7953 gold badges12 silver badges24 bronze badges
asked Jul 17, 2017 at 19:22

1 Answer 1

2

I would isolate the two devices using opto-isolators.

schematic

simulate this circuit – Schematic created using CircuitLab

Turning the output ON will illuminate the infra-red LED in the opto-isolator which turns on the photo-transistor connecting the input to GND. Both devices are then completely galvanically isolated (unless of course you take power from the C64 for the Arduino).

Another option, if you don't care about galvanic isolation, is to just use a simple transistor (small signal NPN or logic level N-channel MOSFET) to make an Open Drain output:

schematic

simulate this circuit

Again, set the output HIGH and the transistor will turn on connecting the C64 input to ground.

answered Jul 17, 2017 at 19:29
3
  • Thank you (again, I guess, as you pop up with solutions for every single question I ask ;) ) Majenko. I will look into both options, that was very helpful. Commented Jul 18, 2017 at 6:59
  • @Majenko can it be transistor 2N2222? Commented Aug 3, 2022 at 12:48
  • @MichałStępień Yes, that is an ideal and common transistor. Commented Aug 3, 2022 at 15:42

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.