Hello all,
I wail back I posted some information on using an Arduino as a I2C Sensor controller to use with the EZB3&4
I will post this in 3 stages ..
Stage one.. right here right now.
In this video you can see how im using the arduino to read the ultrasonic sensor . that in turn is being read by the EZB board via I2C.
This is the only code needed to read the ping for the EzBuilder script
print(I2CRead(0, 2,6 ))
The code for the Arduino is
#include
void setup()
{
Wire.begin(2);
Wire.onRequest(requestEvent);
}
void loop()
{
delay(100);
}
void requestEvent()
{
long duration, inches, cm;
pinMode(9, OUTPUT);// attach pin 3 to Trig
digitalWrite(9, LOW);
delayMicroseconds(2);
digitalWrite(9, HIGH);
delayMicroseconds(5);
digitalWrite(9, LOW);
pinMode (8, INPUT);//attach pin 4 to Echo
duration = pulseIn(8, HIGH);
// convert the time into a distance
inches = microsecondsToInches(duration);
cm = microsecondsToCentimeters(duration);
String outtoezb;
outtoezb += "D1=";
outtoezb += inches;
outtoezb += ":";
char tempout[outtoezb.length() + 1];
outtoezb.toCharArray(tempout,outtoezb.length() + 1);
Wire.write(tempout);
}
long microsecondsToInches(long microseconds)
{
return microseconds / 74 / 2;
}
long microsecondsToCentimeters(long microseconds)
{
return microseconds / 29 / 2;
}
Phase two will be adding the 3 other ping sensors and a temp sensor to the arduino . I hope to have it all encased together will plugs and off the project board.
I will follow up on this thread as the next phase is done I will provide the code for EzBuilder as well as the arduino code.
Hope yall can use it.
By Luis Vazquez
— Last update
Other robots from Synthiam community

Hablijack's Project: Marvin
Hey, here´s my first robot-project. I proudly present MARVIN tadaa As you can see, I´m still working on it ... the...

Fxrtst's Project Gargantua (Or Gar)
Project: By request, my 6 year old son wanted me to design and build him a Hexapod. So I started to whip up some designs...

Robot's Irobot Create With An Arm
Heres my first attempt of using a V3 EZ-B and controlling an iRobot Create robot with a 6 servo arm attached. The video...
Any updates for using more then 1 ping sensor?
This is a very old deprecated thread. You can use as many ping sensors as the hardware supports. The ARC software supports arduino connections directly. Check the getting started guide (link on top of this website) for information.