Commodore 64 remote controlled car

In this experiment, I connected a remote controlled car to the Commodore 64 user port. It is a nice experiment, which you can carry out with your children or grandchildren.

Subscribe my YouTube channel ValorosoIT. Retro technology, vintage audio, retro computers, experiments and tests. Retroprogramming, Basic. Commodore, IBM, Atari, Apple, Texas Instruments, Amstrad, MSX.

Hardware connections

To connect the remote controlled car to the Commodore 64 user port, you must immediately open and modify the remote control.

Commodore 64 radio-controlled car, internal remote control switch electronic card

With the remote control at my disposal, I therefore realized that the 4 buttons that control the machine all have a common ground contact.

The wiring diagram to make is the following, but be careful: it is valid only if your remote control is similar to mine and works at a voltage lower than 5V.

Commodore 64 radio controlled car, wiring diagram for user port connection, diode, switch, RC car

I connected 5 wires to the various contacts: the ground and also the 4 controls of the toy car: forward, backward, left and right.

Commodore 64 radio controlled car, electrical cable connection, forward, backward, left, right, gnd, ground
Commodore 64 radio-controlled car, parallel connection to controls, modification, welding, connection

Then, I took the electrical cables out of the remote, using an existing hole.

To simulate pressing the remote control buttons from the Commodore, you must then ground the signal of each button. For example, if you want to drive the machine forward, you need to ground the feed button signal.

To connect these wires to the Commodore user port, I could have used the usual 4 relay and optocoupler interface that I use in my experiments. I have described it in various articles, including this. The solution of the relay card is valid if the remote control works at a voltage higher than that of the Commodore (for example 9V), or if the switches do not have the common negative.

Electric heater interface 4 relay outputs 10 Ampere 10A, user port Commodore 64 optocouplers, 5V power supply

In this experiment, I connected the wires directly to the Commodore 64 user port, in order to simplify the project. To prevent the Commodore's 5V from entering the remote control, which instead works at 3V, I used 4 1N4148 diodes. In this way, only the logic 0 (the signal to ground) will be able to pass from the Commodore to the remote control, activating it. As already explained, this trick applies to a remote control that works with a voltage lower than that of the Commodore, which is 5V.

Commodore 64 remote controlled car, user port diodes

Remember to turn on the Commodore 64 BEFORE the toy car, otherwise it will move without your consent!

Commodore 64 remote-controlled car, commands in Basic

If you have followed the correspondence of the signals indicated in the above wiring diagram, here are the commands to control the remote controlled car from the Commodore 64.

Radio controlled car from Commodore 64, POKE 56579 command from Basic, forward, backward, left, right

Turn right:

POKE 56579, 1

Turn left:

POKE 56579, 2

Going back:

POKE 56579, 4

To move on:

POKE 56579, 8

Finally, to stop the Commodore 64 remote controlled car:

Follow me on Instagram channel. Retro technology, Commodore, vintage audio, retro computers, experiments and tests. Retroprogramming, Basic. Commodore, IBM, Atari, Apple, Texas Instruments, Amstrad, MSX.

POKE 56579,0

Basic program to drive the radio-controlled car with the Commodore 64

The program I created in Basic performs these operations: in fact, it converts the signals it receives from the joystick, and then drives the Commodore 64 user port. You can download it at the bottom of this page.

To load the car's control program, I use the Kung Fu Flash, which allows you to start it immediately when the Commodore is turned on.

Commodore 64 radio-controlled car, Basic control program, joystick in port 2, command sequence

The joystick connects to Commodore port 2. It is possible to control the remote-controlled machine by moving the joystick. The yellow dot next to the writing "COMMAND:" indicates A (forward), I (back) and even if there is a direction: “<“ left and “>” right. It changes color according to the direction of movement of the radio controlled car.

Furthermore, being connected to a computer, the toy car can also execute preset sequences of commands. In the Basic program, I have included a simple sequence, which is activated by pressing A.

Finally, X ends the execution of the program, also stopping the radio-controlled machine. Before turning off the Commodore, remember to turn off the toy car.

Commodore 64 remote controlled car, program action sequence, road test

Connect the joystick to the remote control, without going through the Commodore

The joystick, like the remote control I used, also uses switches with a common ground. To connect the joystick directly to the remote control of the toy car, without going through the Commodore 64, simply connect the common negative of the remote control switches to pin 8 of the joystick connector.

The other remote control signals must be connected to the respective pins of the joystick connector (contacts 1 to 4).

Normally, the Commodore 64 joystick port pinouts are viewed from the computer side.

Commodore 64, pin pins pinout joystick port connections, DB9 male

In this case, we have to turn the view upside down: we have to take the signals from the joystick and not from the computer.

Commodore 64, pin pins pinout connections joystick side connector, DB9 female
Commodore 64, joystick port connection pinout functions, up, down, left, right, up, down, left, right, fire, shot

List of the program in Basic

And here is the listing of the program in Basic to drive the remote controlled car from the Commodore 64.

The program is available in two formats:

Credits: in the video tutorial, SID music is Tune Nr. 2 by Klaus Grøngaard (Link).

Subscribe my YouTube channel ValorosoIT. Retro technology, vintage audio, retro computers, experiments and tests. Retroprogramming, Basic. Commodore, IBM, Atari, Apple, Texas Instruments, Amstrad, MSX.

Do you like this page? Share it:

Posted in Retro Computer, Retro Technology and Vintage Electronics, All articles.

Leave a Reply

Your email address will not be published. Required fields are marked *