Hercules platform

Hi I’m going to order a 4WD Hercules Mobile Robotic Platform to automatically carry completed part from one room to another at our business. What items do I need to attach the sensors to the controller. Also are the sensors 180 degree sensing or more linear? I would like to order all at once.

Thanks

There are five digital pins broken out, as well as two analog pins, I2C and serial. It’s really up to you to determine which sensors to attach, but we would suggest the following:
1x Line sensor
3x Distance sensors (infrared or ultrasonic)

Connections to the analog pins are a bit harder since the manufacturer chose a specific connector, but all the necessary pins are there.
You may also need some sort of way to tell it to retrace its steps.
The ultrasonic distance sensors normally have a detecting profile (not 180 degrees though). Infrared are a bit more conical.
Note that the line sensor would be used to follow a line you trace on the floor (electrical tape for example) and the distance sensors would be used to detect any obstacles in its path.
You would need to program the robot to do what you wanted.

Hope this gives you some ideas.

What would be a good way to tell it to retrace its steps?

Hi,

Retracing it’s steps is usually done on a software side. The best way to do this is to use a motor encoder to track how many times your wheel rotates. Knowing that, you can figure out how much distance it has traveled.

Now once you have this hardware setup, what you need to do is to implement dead-reckoning (google it, it’s pretty cool, used in ship navigation). Essentially, using deck-reckoning, you store a vector of positions and direction. You could use North, South, East, and West.

Now if you don’t have a programming background, this may be very confusing.

Every time your robot turns in a specific direction, you record that turn as a vector and you track how far it goes in that direction. Every-time you turn, you also flip the relative direction of each vector (this is dead-reckoning) such that when you reverse, you simply reverse each position vector.

The best data structure to do this with is a stack. Using a stack you would push vectors containing

  1. a distance
  2. a direction

and you would iterate through the stack every turn to apply dead-reckoning.

When it comes time to reverse, you simply pop and reverse the direction of each vector in the stack. The dead-reckoning off-loads any thinking you have to do when you clear the stack.