Testing and Using the External Data Bus on T20

I am trying to do some testing on the external data bus of the T20 on a Evaluation board carrier.

I have an ARM based micro controller (LPC1768) that will send a string “Hello” (characters sent one at a time, each is sent after 100ms delay) to the GMI_D0 to GMI_D7 pins of the evaluation board.

I have received a character based GMI driver for using the External Data Bus on the T20 module.
(this driver was written by Brandon Shibley of Toradex, source code)

I have included this driver as an inbuilt kernel module. It is available as a character devices with major number 97

cat /proc/devices
97     tegra-nor

I am able to make a character special device for this using:

mknod /dev/gmi c 97 0

I am able to send repeating 0x00000000h to the data bus using this simple script I created:


echo "Press [Ctrl+C] to exit"
while true
      echo -en "\\x00\\x00\\x00\\x00" > /dev/gmi

I was able to observe that this script works because there was a voltage change on the data pins when script was running and when it was not. This is the basic methodology I have used for writing to the external bus. For reading the data bus, I use cat /dev/gmi , but I just receive a stream of non character data (this must be the correct behaviour I am guessing)

Finally, I have realized that my whole approach for communication using GMI is insufficient. What kind of user-space application do I need to write to achieve this. I am unable to find much information on this anywhere, so can someone please provide examples.

Have a look at this document Accessing hardware from userspace for information/hints on how to communicate with h/w from userspace.

I will take a look at it