Motors are driven by a L293D driver IC, capable of handling 1.2 Amps.
I'm using the PWM Modulator for power control to the motors and the SPI interface for several digital
outputs , so as changing the direction and brakes of the motors. This is simply done with a 74HC164
shift register, giving 8 digital outputs.
Waypoint and speed are measured by a small driver routine in the kernel
, interrupts are issued by the interrupter wheel, and a timer routine counts
these pulses per second to measure speed. Development of software concentrates
on 1. accessing the sensors and then 2. simple orientation algorithms to
explore its environment. Future goals might include a small vacuumcleaner
or similar application.
Here now the first software pieces:
Obtain the updated sources from uClinux Source.
Interrupt driven routines must be included in the kernel, so a change
in kernel compilation is necessary.
For the robot some kind of odometer and tachometer was necessary, so
i wrote a small driver as a misc device and included it in the make process
of the kernel. You could also remove another device and rename yours to
this , but make sure the entry points are named like the original ones,
or your device will be ignored on startup. My driver checks for hardware
interrupts from both wheels and counts them , plus checks every second or so for the number
of pulses counted so far for speed measuring. Both can be read through
the /proc/speed device. Any writing to /dev/speed resets the counters.
Here is the driver: speedy.c
I've written some small 'userland programs' to set the SPI,
the PWM, and measure distances
with the Sharp Sensor.
Initing the hardware is done in one common program here.
Extract the routines you need at your convenience.
If you are interested in using an LCD panel with 2.4.x kernels, take a look at the Framebuffer driver.
You need to modify the file Framebuffer memory manager and include your new driver
into the build process of the kernel. Please don't run this on another architecture, it will crash.
Instructions on integrating the framebuffer into the kernel build can be found here .
Currently I am using the 2.0.39 version of the kernel , it seems to be much smaller and has full console support on the LCD
Email me for Questions and suggestions.