Robot Follow Project

Hello,
I am trying to make a rolling backpack that can follow the user around wirelessly. The idea is from YouTube.com/thebenheckshow. My parts that I currently have are as follows.
2 Arduino Unos
3 HC-SR04 Ultrasonic Range Finders
2 Motors
1 Motor Shield
I have it all hooked up like it should be but am facing a problem. No matter what I try, I can not get the ultrasonic sensors to communicate with each other. One sensor is hooked up to an Arduino and all it does is ping. The other 2 sensors are hooked up to the other Arduino and try to listen to a ping. I obviously did not plug in the trig pin because they are supposed to be receiving. I need help with this problem and also I need help finding something very lightweight that could be the “backpack” Any guidance is appreciated.
Thanks

The below might be of interest.

http://revision3.com/tbhs/robotluggage

I have seen this video many times. They just don’t go into enough detail. I have even talked with the guy in this video and he told me I did not have to use the Xbees for it to work. Plus I’m using different sensors, motors, and a different Arduino.

Plus I'm using different sensors, motors, and a different Arduino.

And some code that doesn't work, but that you don't want to share. And, yet, you want us to tell you what is wrong with it. Good luck with that approach.

Hello all, I am trying to make a robot that will follow a person around using the hc-sr04 ultrasonic sensor. I have 3 hc-sr04's and 2 Arduino Uno's. At the moment I am not going to worry about motors so I am not listing them. 2 receiver sensors are connected to one Arduino and the other transmitter sensor is connected to the other Arduino. I saw this code that I modified (credit to youtube.com/thebenheckshow) and am having some trouble with it. This is the code for the robot:

boolean oneFire = false;
boolean twoFire = false;
boolean finished = false;
long setPoint1 = 0;
long setPoint2 = 0;
long difference = 0;

const int echoPin1 = 7;
const int echoPin2 = 6;

void setup(){
  pinMode(echoPin1, INPUT);
  pinMode(echoPin2, INPUT);
  Serial.begin(9600);
}

void loop(){
  long timeout = 0;
  long distance = 0;
  oneFire = false;
  twoFire = false;
  finished = false;
  setPoint1 = 0;
  setPoint2 = 0;
  difference = 0;
  
  while ((oneFire == 0) || (twoFire == 0)){
    if (((PIND & 0x10) == 0) && !oneFire){
      oneFire = true;
      setPoint1 = timeout;
    }
    if (((PIND & 0x20) == 0) && !twoFire){
      twoFire = true;
      setPoint2 = timeout;
    }
    delayMicroseconds(1);
    timeout++;
    if (timeout > 19000)
      break;
  }
  difference = setPoint1 - setPoint2;
  distance = (setPoint1 + setPoint2)/10;
Serial.println(difference);
}

The code for what the human wears is simply:

const int trigPin = 12;

void setup()
{
  pinMode(trigPin, OUTPUT);
}

void loop() {
      digitalWrite(trigPin, LOW);
      delayMicroseconds(2);
      digitalWrite(trigPin, HIGH);
      delayMicroseconds(5);
      digitalWrite(trigPin, LOW);
}

Again, I am not worrying about motors because once I get valid readings, The motor part will be easy. When I upload both, point them at each other, and start the serial monitor, all I get is 0. Any help is welcome. Thanks

The below discussion might be of interest.

http://forum.arduino.cc/index.php?topic=229493.msg1656725#msg1656725

Sorry. I had to make a new post because my last one did not have enough information.

Sorry. I had to make a new post because my last one did not have enough information.

No, you didn't, any more than I had to make a new post to reply to you.

may i ask how far have you gotten into this project?

i am also planning on building somthing like this

did the code work\?

Please don't post multiple topics for the same question.