Extra Inputs / Outputs pins on RSMedia

2 posts / 0 new
Last post
Helibot
Helibot's picture
Extra Inputs / Outputs pins on RSMedia

This post is for Grazygeorge who was interested to hear about possibilities for extra IO pins on RSMedia.

Back in 2008 I found a way to use six extra I/O pins on RSMedias main board.  The details of this was posted to another forum (which is now defunct).  So I am reposting it on Robocommunity now. Everything below is almost identical to what I posted in 2008...

I identified 6 pads on the RSMedia’s main (linux) board that can be used for general input or outputs.  You can solder wires to these 6 pads, then you can use software to configure the correct processor pins to write or read data to the pins.

In short here are the results:-

RSM Main board label

MX9328MXL

Signal

J11-9  

PD11

J11-12

PD17

J11-14

PD19

J11-15

PD20

J11-16

PD21

J11_21

PD26

 

PAD Overview

The pads I have found are on the TOP of the media board.  (They are actually visable and quite accessable if you remove the insert behind his neck.)

They are marked with white writing as J11-9,J11-12,J11-14,J11-15,J11-16,J11-21.

Note that 5 are grouped together and one (J11-21)is near the top of the board (the pad near the edge).

I have assumed that the pad for J11-9 is next to the white text.
I have assumed that the pad for J11-12 is away from the white text.

The red circles in picture below shows the general location of the pads.

ExtraIOPads

This photo shows the board after I installed 5 wires:

ExtraIOPadsandWires

Tips for connecting the wires

These pads are small – very small – you need a fine tipped soldering iron (or a bigger one filed until it is really sharp). I recommend using some soldering fluid (buy it from an electronics store) it will make the solder flow easily, so the solder only goes on the pad  (just dip the solder iron and wire into the fluid before you solder it) Only use the smallest amount of solder. I recommend using ‘wirewrap’ wire – it is very fine (AWG30).

 

Signal Overview

PD1-31 are the Port D GPIO (General Purpose Input Output) pins on the MX9328MXL processor used on RSMedia main board .  They can also be used for an LCD controller (fortunately the RSMedia interfaces its LCD via a different method!!).
So this leaves these pins free for use!!

To drive these pins from software you need to setup a collection of registers in the GPIO area then you set/clear a bit in a data register to set the signal high (3.3V) or low (0V). You can read a bit from a register to read an input.

 

Software

“You can write a bit to a data register to set the signal high .You can read a bit from a register to read an input”
Sounds easy doesn’t it – well it usually is for a microprocessor …..unless you are running Linux.

Linux does not allow user programs to write to hardware registers. The kernel is allowed to write to registers , but noone has been able to create a new kernel for RSMedia.

But all is not lost…..Linux supports loadable modules, these allow you to load code that can run in the kernel (and can therefore write/read hardware registers ).

Fortunately the MX1ADS development board (which seems to be what the RSMedia main board is based on) comes with an example ‘hardware bridge’ device driver.  I modified this to work on RSMedia and allow user programs to modify the registers.  I will post details of this (including source and examples ) in another post.

(Actually I need to dig the source out of an old Redhat VMware image and find/write some instructions, so its likely to be a few days.....)

Cheers

  Helibot

Helibot
Helibot's picture

Hi All,   

 I have now put together the software needed to access the I/O ports. I called it the 'RSM IO toolkit'.  This software will allow extra I/O pins on the RSMedia main board to be set to Low (0 Volts) or High (3.3volts) OR the pin can be an input so the software can read if the voltage on the pin is High or Low.
There are two ways you can use the toolkit:

  1. Use the programs supplied from scripts or the command line. You wont need to compile any code todo this. So this is fairly easy to do.
  2. Call the functions supplied from your own program. You will need to write code and compile it todo this. This is more complex but will be required if you want todo fancy things that require fast or accutate timings (like connecting a IR transmitter or receiver). Anyone with basic C coding skills should be able modify the example program for their own use.

Please download the software from here: RSM IO Toolkit on RSM Devkit Web site. After downloading see the file  "RSMedia_IO_Toolkit_V2.html" in the archive for detailed instructions on setup, using the supplied programs or modifying and compiling the source for you own use.

Cheers
 Helibot