Main Board
From Opensprints
The Main Board, aka the USB interface board, is basically an Arduino piggyback board that provides a safe and convenient interconnect for the sensors. Ethernet cables are used to connect the sensors to the Arduino. Extensive prototyping area on the board allows for ease of extending the functionality of the system.
Contents |
[edit] Assembly
- Press in four RJ45 Jacks.
- Solder in RJ45 Jacks.
- Install Power LED (and resistor).
- Get your parts ready to install the Arduino Board.
- Install Standoffs.
- Install male headers.
- Get the rest of your parts ready.
- Install End Panels.
- Screw PCB to case.
- Screw Case Together.
- Install Adhesive Feet.
- Install Stickers.
Stickers! Now you are ready for the Firmware update.
[edit] Tips & Tricks
If you didn't buy a kit directly from OpenSprints, but you are using these instructions, these tips will help.
- Install blinker LED with anode connected to Arduino pin 13, and a resistor connected between the LED's cathode and GND. A good resistor value for white, blue, or green LEDs is 100 Ohms. A good resistor value for red, yellow, or orange LEDs is 220 Ohms. The newest version of the interface PCB has pads for the LED and resistor.
- Cutting your own End Panels. Cut the face plates of the project box to make openings for the USB jack and the RJ45 jack(s), and slide the face plates into place on the project box. This will add much needed structural support to the enclosure in the event it is stepped on, however you can omit this step. Here are the CAD drawings for the parts if you wanted to get them professionally cut:
- Enclosure: Click on the User Prints tab
- Ethernet Jack: Click on the Product Drawings
- Arduino Board:Schematic & Reference Design
[edit] Updating Firmware
SKIP THIS STEP if you bought a pre-assembled and tested system. The pre-assembled systems already have this step done for you.
If you intend to use a USB Flash Drive, DO NOT install this step on the USB Flash Drive -- you will run out of room. Instead install the firmware from windows or mac.
In order for the Arduino Environment to be able to talk to the Arduino, the OpenSprints app should not be running.
- Have your Main Board and USB 2.0 A / B Cable handy and ready to go.
- After you have downloaded and installed the latest Arduino Environment for your Operating System, open up the Arduino Environment. Make sure the OpenSprints app is not running at the same time. Linux users: install the dependencies as described in the Arduino Environment site.
After you have downloaded and installed the latest Arduino Environment for your Operating System, open up the Arduino Environment. - Select the correct board and device / serial port from the "Tools" menu. If you are nervous about which one to pick, just unplug the other USB cables on your computer before you do this.
- After you have downloaded and installed the latestOpenSprints software open the firmware directory.
After you have downloaded and installed the latestOpenSprints software open the firmware directory.- If you have installed the OpenSprints software via the Ubuntu repository, copy the directory /opt/opensprints/firmware/arduino/basic_msg/ to your Desktop and then in the Arduino environment, open basic_msg.pde in the directory on the Desktop.
- Open the OpenSprints basic_msg.pde in the Arduino IDE and then click the "Upload" button -- marked with the red arrow in the picture.
- If you see Done Uploading at the bottom, OpenSprints basic_msg.pde was loaded successfully.
- Visually verify that the firmware was successful. Plug in the sensors. You were successful if they light up red instead of red and green. If both the red and green lights come on (especially in ports 1 & 2) it means the default Arduino firmware is still on there.
[edit] Troubleshooting
Follow these instructions if the software doesn't seem to be responding when the people pedal. This step by-passes the software to see if the hardware is sending data to the computer.
[edit] Setup for testing under Linux
- Run gtkterm
- Configure the port (Configuration -> Port) and select the following values:
- Port: /dev/ttyUSB0
- Speed: 115200
- Parity: none
- Bits: 8
- Stopbits: 1
- Flow Control: none
- End of line delay: 0
[edit] Setup for testing under Windows
- Install and run PuTTY.
- With the Arduino connect to the PC, go to Hardware Manager and determine which COM port the Arduino is connected to.
- Configure the port:
- Click on the Serial radio button.
- COM?, as determined in previous step.
- As far as I remember, everything else should be default.
[edit] Running a fake race
Once the chosen terminal is configured as per the previous step, you should see a cursor with nothing going on. Type the letter 'g' on the keyboard. Nothing should happen for a few seconds (during the countdown - "4, 3, 2, 1, 0, go!"). Then you should see a stream of numbers and letters filling the screen.
This is an example of what you might see in the terminal at an instant:
1: 0 2: 0 3: 0 4: 0 t: 15311
Test the hardware by waving a magnet in front of the hall effect sensor. (Turn the magnet around until the tick LED flashes. That will be the correct orientation of the magnet.)
Every time you wave a magnet in front of the hall effect sensor you will see the number following the corresponding sensor increment. So if you caused a tick on sensor 2, the following report will look like this:
1: 0 2: 1 3: 0 4: 0 t: 15562
At this point, if all the sensors are behaving as expected, it's time to install and start running the PC application. Check out the page on software installation.
[edit] Complete Testing Process
- Program the arduino with firmware.
- Test each RJ45 port on each sensor as it's completed to make sure the White LED lights up when the magnet passes by the HE. The default Arduino firmware will light up both the Green and Red LEDs when it has power, the OpenSprints firmware will only light up the Red LED.
- Full system integration test
- Connect all 4 sensors to the interface board
- Run a serial monitor program (Arduino environment, putty, gtkterm, etc.)
- Run the magnet by each of the sensors and make sure messages sent from interface board correspond to the ticks that you are creating on the HE's.
- Verify the Stop/Go LEDs. (or you could verify the stop/go lights in step 2 if you want).


