Pal, an obedient autonomous truck

abraxas1's picture

Description: 

Hey, a home for my robot, Pal.

I got tired of carrying my electric RC truck around from hill to hill while working it up in the dirt. just seems kinda of humiliating to both of us, ya know?

Also, I think one of the best/simplest ways to instill a sense of awareness in a robot is for it to know where you are. towards that goal i''m adding some ultrasonics and some brains to it so it will follow it's control unit around like an obediant doggy. 

maybe can also make it do circles or something cute. we'll see.

working on all the basic elements of the code now using a DsPIC33 chip from Microchip. it can control 3 servo channels, drive the 40KHz US transmitter, and rip in from the onboard ADC at this point in time. work is proceeding...

i'm hoping to implement either a kalman or particle filter in the future, would like some experience with that type of code.

michael

Your rating: None
Scheda's picture

Sounds like a pretty cool

Sounds like a pretty cool project. Post pics as it goes along so we can see what kind of stuff you're doing with it.
BaseOverApex's picture

Sensing

Sounds impressinve. How are you detecting the location of teh "control unit"?
abraxas1's picture

Ultrasonic Beacon

my plan is to have the control unit act as an US repeater, when it hears a beep, it replies with a beep. also with some pulse identification, i believe, for enhanced echo-immunity.

for a direction heading i'm going to try first using a 360degree pan stage on the truck, cause it will be neat to have that thing swinging around and locking in on "you", but i'm really interested in trying a InterAuralDelay technique also; have three US receivers in a triangle shape on the truck and be able to get a direction heading on every pulse.....

 

since it's mostly software at this point, pictures aren't very interesting. but soon they should be!

 

then the next challenge will be to implement a Kalman filter or particle filter for localization. that's something i'm interested in getting some practical experience on.

 

Thanks for the comments! 

michael

 

 

abraxas1's picture

Pal System Block Diagram

here's a shot at the overall design.

i would like to be able to switch between autonomous, on-board PIC control, or regular 4x4 truck rip-up-the-road control.

i guess those NPN transistors shouldn't really be neccessary, i didn't want to burden the PIC with the menial task of supplying current though. 

 

Pal System Block Diagram

abraxas1's picture

Pal Timer Allocation

here's my working layout for getting the 40 KHz ultrasonics generation and 20mS RC servo signal and etc working in a dsPIC33FJ128GP802

 Pal Timer Allocation

 

abraxas1's picture

Basic Ranging working now

i rigged up a very simple, 1D "test range" using a 2.5" diameter plastic tube a meter long (empty plotter paper tube). i put a transmitter and receiver at one end and a sliding plug at the other end.

it works nice enough, but there are standing wave issues. i have the transducers stuff in some foam, and the foam doesn't absorb the ultrasonic very well, so it echos. i might try just hot-gluing the transducers to the inside of the tube and leave the rest of it open. but it doens't really matter, i just tune to a slightly different position.

Pal Delay Tube

 

 

abraxas1's picture

Delay Tube Scan

Delay Tube Scan 01guess the standing waves in the tube are worse then i thought. still not sure it matters though, unless i want to use this for some quantitative calibration, which shouldn't be necessary. The graphs were made by sampling every 100mS for 10 seconds, making 100 points, as i slowly pushed in the plunger on the tube resulting in shorter distances.

the red curve is the received and digitized signal from the ultrasonic transducer. i'm using bunches of 3 pulses seperated by 1.25mS or so. each point is 50uS and they start with the generation of the first pulse.
The Blue curve is a very simple "gating" correlation anticipating the three peaks and 1.25mS space between them. the highest peak will always correspond to the rising edge of the first pulse. I anticipate a much better algorithm here, but this seems to be reliable in the delay tube anyway

The green curve is the value of the three peaks in each pulse averaged together. here you can clearly see the standing wave behavior of the tube.

The yellow curve is the delay measured, in uS. each point is 50uS so this corresponds to which point the first rising edge is detected at, times 50uS. i suppose the glitches are due to the massive standing wave signals at some positions. at certain exact spots the signal would seem to disappear completely.

now to work up a scanning routine for panning motor, PID lock-in detection....
abraxas1's picture

Pal Rover1 Board Layout

ok, finally got around to getting off the explorer-16 development board and building up my own. i simply used a board from Radio Shack, it was sized pretty well to this app, though the copper is such poor quality it's amazing.

when i get the schematics all updated i'll post that too.Pal Board Layout

 

 

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.