Tim's Cybot Arduino NANO Remote Control

by Palingenesis in Circuits > Arduino

2656 Views, 9 Favorites, 0 Comments

Tim's Cybot Arduino NANO Remote Control

Cybot_Remote_001.png
Cybot_Remote_002.png

This project is to create an Infrared Remote Control to control the Original Cybot received with the magazine Ultimate Real Robots, started back in 2001.

Reason for making the remote:(a little history)

Before the issue of the parts for the IR handset, Cybot was put into different modes by selecting DIP Switches. (There was no issue with Cybot while this was the case) When the IR Handset was issued, things changed. A processor was upgraded to change the function of the DIP Switches. The DIP Switches where then used to set the channel used by the IR Handset so that more than one Cybot could be used together at the same time. (Up to 16 Cybot could be controlled with the Infrared Controls ) However, when the Infrared-Download-Board was issued, there where problems. Not all the boards where manufactured the same, there where issues that made some not work correctly or not work at all. There was a fix issued but this did not fix all. I was one of the unlucky ones, nothing worked for me from there on, everything relied on the Infrared Handset working.

If you, like me, was one of the unlucky ones that had the same problem, you may wish to dig out your old box of Cybot bits and make this Infrared Controller to control it.

The only thing I could not do is: Voice Control and PC LINK

The Remote in Action

Tim's Cybot Arduino NANO Infrared Remote Controll (2)

I had trouble focusing, I used my old phone to make the video.

Cybot

Cybot_Remote_003.png

I'm sorry, but unless you have a Cybot, then this is not much use for you.

But if you know anyone that has one:

May be this will resurrect those dormant little fellows, hiding away in those dusty closets :)

Lets Start. First the Prototype.

Cybot_Remote_004.png
Cybot_Remote_005.png

Before making the handset I built a prototype to test thing out and make sure my code worked.

R8 and R9 are pullup resistors for the I2C bus. a lot of people forget to add these to the circuit, but they are required. (one pair per bus, not device)
As a rule of thumb to the resistors are added to the master, but as the Arduino could be used as master or slave and to keep things simple, internal pull are not used in the library.

I have used Internal Pullup Resistors for the Pins connected to the switches. So all Switches are to close to Ground.

The Resistor / Capacitor Pairs R1 to R7, C1 to C7 are to compensate for bounce. (so are not necessary if you want to do a quick test, I recommend them for stability)

Q1 is the driver for the Infrared LED (940nm). This is so full power is used by the LED to transmit the signals. (again if testing next to your Cybot, Q1, C8 and R11 can be removed. Connecting R10 and LED1 in series between Pin D3 and 5v should work)

I created the circuit using Fritzing, so here is the file so you can view it better: Arduino_Handset.zip

Program the Arduino

Cybot_Remote_006.png

After making the prototype from the circuit above you will need to upload my HEX file to the Arduino NANO.

I use this uploader to do this: XLoader.

I have done a HEX file for the NANO and the UNO. (as far as I know they are both the same)

Arduino NANO: Tims_Cybot_Transmitter_Nano_Atmaga328P_Internal_Pullup.hex

Arduino UNO: Tims_Cybot_Transmitter_Genuino_Uno_Internal_Pullup.hex

For the Built version I use External Pullup Resistors.

Arduino NANO: Tims_Cybot_Transmitter_Nano_Atmaga328P.hex Using External Pullup Resistors.

Arduino UNO: Tims_Cybot_Transmitter_Genuino_Uno.hex Using External Pullup Resistors.

(I don't know if HEX Files have the bootloader in them, but I did these HEX Files with it configured to Old Bootloader for the NANO)

XLoader is an easy program to use, you don't need to install it, it is a standalone program that runs from wherever yo put it. You tell it where the file is and tell it where to send it.(the port your NANO is plugged into)

Next Step Is to Make a Functional Usable Handset.

Cybot_Remote_007.png

Rather than make one circuit board and mount everything to the one board, I have decided to make this project modular.

By making it modular, some modules may be found on the internet.

Also, you will see from the sketch, I like show all the inner workings of my projects :)

List of Components / Modules:

Cybot_Remote_008.png

Arduino NANO

Cybot_Remote_009.png

The chip needs to be ATmega328 (If you are using China Clones)

This program uses 90% of both SRAM and EEPROM

OLED

Cybot_Remote_010.png

Mono (Black and White)

0.96 inch 128 x 64 pixels I2C connection

Rotary Switch With Push Button

Cybot_Remote_011.png
Cybot_Remote_012.png
Cybot_Remote_013.png

I made this board my self.

I wanted external pullup resistors and de-bounce on all switches. Some rotary switch modules can be found on the internet.(be sure they have pullup resistors on the board)

It can be made on a Perfboard.

Here is a Fritzing file: Tims_Rotary_Switch.zip
(Obviously the wires go under the board)

Infrared Transmitter

Cybot_Remote_014.png
Cybot_Remote_015.png
Cybot_Remote_016.png

I made this board my self.

There are some modules on the internet, but be sure to get one that has a driver. (has a transistor to power the IR LED from the power supply)

It can be made on a Perfboard.

Here is a Fritzing file: Tims_Infrared_Transmitter.zip
(Obviously the wires go under the board)

Control Buttons

Cybot_Remote_017.png
Cybot_Remote_018.png
Cybot_Remote_019.png

Luckily I had a 4 button panel I removed from an old Epson printer.

This panel has pullup resistors and de-bounce components fitted to it. But not every one has a box full of old bits to use, so here is the circuit.

It can be made on a Perfboard.

Here is a Fritzing file: 4_buttons_with_Debounce_and_Pullup.zip
(Obviously the wires go under the board Apart from one)

A Note on making it on a Perf-Board, the top and bottom fits into plastic parts I made on my 3D Printer.

The size of the board should be 65mm X 40mm.

When fitting the plug to the cable, note that the pins are as follows:

Left Forward = pin D7

Left Reverse = pin D8

Right Forward = pin D6

Right Reverse = pin D9

Power and I2C Bus-Board

Cybot_Remote_020.png
Cybot_Remote_021.png
Cybot_Remote_022.png

To make things easy to connect all the components together I have made a Bus-Board for the power and I2C.

Putting the I2C bus on the board with the power makes it easy to add the 2 Pullup Resistors required for the I2C Bus. (As I have only one I2C component, I only needed to fit 2 headers on that bus)

It can be made on a Stripboard.

Here is a Fritzing file: I2C_Bus.zip

To Connect All the Components Together a Few Cables Need Making.

Cybot_Remote_024.png
Cybot_Remote_023.png

3D Printed Parts.

I include a picture with each file to show the orientation they are printed.

Base

Cybot_Remote_025.png

STL File: Base.stl

Switch Side

Cybot_Remote_026.png

STL File: Switch Side.stl

NANO Side

Cybot_Remote_027.png

STL File: NANO Side.stl

Battery Clip

Print Battery Clip.png

NANO Clip

Print NANO Clip.png

STL File: NANO Clip.stl Also need to make a mirrored copy

Encoder Nut

Print Encoder Nut.png

Encoder Knob

Print Knob.png

STL File: Knob.stl

Button PCB Support

Print PCB Support.png

STL File: Button Support.stl

2 are required.

OLED Support

Print OLED Support.png

Assembly (step 1)

Assembly001.png

The first parts to fit are:

The Switch to the Switch Side. (2 x small screws)

Infrared Transmitter Module to the Base. (2 x M3x10 flat end self tappers)

Power and I2C Bus-Board to the Base. (2 x M3x10 flat end self tappers)

Rotary Switch Module to the Base. (M7 Nut)

Place Battery with Battery Clip on Base.

Fit Switch Side to Base over the Battery Clip. (2 x M3x10 flat end self tappers)

Fit cables from the Switch to the Battery and the Arduino NANO.

The Cable to the Arduino NANO goes to the pins VIN and GND.

Assembly (step 2)

Assembly002.png

Before fitting the Arduino NANO to the base, it is a good time to fit some of the cables to the Arduino.

See picture above for cable lengths and ends.

Arduino to Power-Bus. The split connector end goes to pins 5V and opposite GND.

Arduino to I2C Bus. Connect to pins A4 and A5.

Arduino to Encoder Buttons. Connect to pins A0, A1 and A2.

Arduino to IR. Connect to pin D3.

Assembly (step 3)

Assembly003.png
Assembly004.png

Now the Arduino can be fitted in place. (lower cables need to be bent up )

Then:

Arduino to Power-Bus. Connect to pins on the Bus-Board, 5V to VCC, GND to GND.

Arduino to I2C Bus. Connect to pins on the Bus-Board, A4 to SDA, A5 to SCL.

Arduino to Encoder Buttons. Connect to Encoder Module.

Arduino to IR. Connect to Infrared Module.

Connect Power Bus to IR.

Connect Power Bus to Encoder Module.

Connect Power Bus to OLED. (just to the power bus at the moment)

Connect I2C Bus to OLED. (just to the I2C bus at the moment)

Assembly (step 4)

Assembly005.png
Assembly006.png

Next is to fit the NANO Side.

This has 2 NANO Clips attached (1 x M3x10 flat end self tapper in each)

Assembly (step 5)

Assembly007a.png

Next is to fit the Button Board Supports to the Button Board.

Assembly (step 6)

Assembly007.png

Next is to connect the Button Board and the OLED

The cables for the Button Board go through the NANO Side Support.
Power Cable goes to the Power Bus.

The Button Cable connects as follows:

Left Forward = pin D7

Left Reverse = pin D8

Right Forward = pin D6

Right Reverse = pin D9

The OLED connects to the previously connected cables to the Bus Board.

Assembly (step 7)

Assembly008.png

Now the Button board and OLED Support can be fitted to the top. Also the Knob for the Rotary Encoder.

Assembly (step 8)

Assembly009.png

Finally fit the OLED to it's support. (2 x M2 self tapping screws)