I decided to do some electronics and software testing before finishing building the second leg of my DARwIn-OP robot.
I wired my ODROID-XU with the GY-80 10DOF module using the I2C bus on the LCD connector (CON15) and a PCA9306 to adjust communication voltages.
The following is the connection diagram tested:
This 10DOF can be powered from 2V to 5.5V (VCC_IN). Its sensors are internally powered at 3.3V, but according to this documentation its I2C interface is rated at VCC_IN, so the PCA9306 has to translate from ODROID-XU’s 1.8V to VCC_IN (and not to 3.3v).
This 10DOF has 4 I2C devices in the following addresses:
0x1E: 3-axis compass (HMC5883L chip)
0x69: 3-axis gyroscope (L3G4200D chip)
0x53: 3-axis accelerometer (ADXL345 chip)
0x77: pressure and temperature sensors (BMP085 chip)
With this small C program, the accelerometer chip can be query in order to detect it and verify the setup. I am currently testing Ubuntu Server 14.04 off the shelf on the ODROID-XU, which includes the GCC compiler by default.
Now that I have I2C communication running, I followed the chips documentations and some googled examples in order to write some draft C++ classes to read the 10DOF sensors. They are available in this Code Section in the SourceForge repository for cloning the DARwIn-OP Robot.
I could successfully test the 10DOF powering it (and the PCA9306) with 3.3V and 5V, but at 3.3V they draw 0.024A (or 0.079W) and at 5V they draw 0.085A (or 0.425W). So in my final DARwIn-OP design I will most probably include a 3.3V regulator to lower consumption.
The original DARwIn-OP Robot uses an on-board 1.6 GHz Intel Atom Z530 computer and a CM-730 ARM controller board. This controller board includes a 3-axis gyro, a 3-axis accelerometer and a Dynamixel bus to interface with the robot’s servos.
I intend to use an alternative electronics based on a more powerful ARM computer plus several peripherals. For the main computer, my current choice is the ODROID-XU which is a quad Cortex-A15 1.6GHz CPU with 2GB RAM.
Instead of using a controller board, I’ll be using a USB2AX to interface the Dynamixel servos and I’ll use I2C components for the gyroscope and accelerometer.
On the picture are shown the components that I already got and that I’ll be testing:
I2C 12 bit 4 channels ADC (ADS1015 chip)
I2C voltage-level translator (PCA9306 chip)
I2C 10DOF with 3-axis gyro, 3-axis accelerometer, 3-axis compass, temperature and pressure sensors (L3G4200D, ADXL345, HMC5883L, BMP085 chips)
I’ll be using the native I2C interface I2C_0 that is available in the LCD connector (CON15) in the back of the ODROID-XU (the schematics are available through a customer email request to Hardkernel).
The LCD connector is an IPEX 40 pin with 0.5mm pitch. I got some a couple of cables from Ebay, but now I saw that Hardkernel (the maker of the ODROID) is also selling the cable. The pin configuration that I’ll be using for the I2C interface is:
4 – 1.8V
6 – SCL
7 – SDA
10 – GND
The ODROID-XU’s I2C interface is rated at 1.8V, so I’ll be using the PCA9306 to translate it to the rest of the I2C components which are rated at a higher voltage.
The DARwIn-OP requires a gyroscope and an accelerometer, but I am interested also in using the compass and the force sensors (through the AD converter) for a future version of the DARwIn-OP feet.