Servers by jDrones

I2C Maxbotix range finder on Pixracer

pixracer
rangefinder

(chris rey) #1

Hi, no problem configuring my I2C Maxbotix on Pixhawk, can see the range. But when I try to install it on Pixracer, I have to use an I2C multiplug connected to the GPS as there is no I2C connector on Pixracer (didn’t find any). So in MP I selected Maxbotix I2C in Range Finder page, but nothing happends. Do I have to change a parameter in SERIALX_PROTOCOL? How to use both GPS and Range Finder? Thanks, Chris


(ppoirier) #2

You need to split the signals from the PixRacer connector, take a look at this


(chris rey) #3

I already did this using a splitter


(ppoirier) #4

I mean you have to split the serial (TX-RX) and I2C (SDA-SCL) you need to split the GROUND and VCC as well.
If you dont want to mess with cables, I think this product is made for it:
https://store.mrobotics.io/product-p/auav-i2c-hub-mr.htm


(chris rey) #5

thanks for your answer, but did you see my splitter on the pict? do you think this is not doing the job? for me I2C is a kind of bus and should work as this, no? maybe I’m totally wrong, but I use the same type of splitter on my Pixhawk, the difference is that it is connected directly to the I2C connector.

I have a message in MP Bad Lidar health, and 0 in the Range indicator, so I assume the connection part is ok, this is just with the serial protocol configuration that something must be wrong SERIAL_3 is for GPS and SERIAL_4 is for Frsky, so do I have to configure something specific for another SERIAL?


(ppoirier) #6

Your spiltter is I2C only, the other model is I2C and Serial specially made for PixRacer an you will need the correct set of cables as well.

Otherwise you need to build it from scratch.


(chris rey) #7

Sorry but this is a specific splitter for Pixracer with jst GH 6pins connector, that splits to 4 I2C and 1 6 pins serial output. I think this is not the problem, the problem is in the configuration of the serial ports. If the Range Finder sensor was not connected, I wouldn’t have the message “Bad Lidar health” in MP.


(ppoirier) #8

Ok so if we assume that:
the splitter works ok,
you have the right set of cables
the Mavbotic is powered with the right vcc (5 volts)
there is no other I2C conflicting devices
you are running with a recent firmware release
and the sensor is setted correctly
Then it should works OK


(chris rey) #9

@ppoirier thank you for your precious time.


(chris rey) #10

Ok, as I thought, my wiring with my splitter was OK. Now when USB connected with MP, my Maxbotix sensor works perfectly! (I was in UDP before). But when connected through UDP it doesn’t provide any range values. 0. So I assume there is a conflict between the 8266 Wifi module and the Maxbotix I2C module, sharing something together? Is this a parameter in the SERIAL things I can adjust somewhere?
I’m sure it will help also other people.
Thanks, Chris


(ppoirier) #11

Looks like a power supply issue for me
Leaving the USB plugged in, try connecting with UDP


(chris rey) #12

thanks, just did the test 1st usb connected, I get the range value, then I clicked on disconnect and selected UDP, without disconnecting usb cable and range value was on 0 again. I also did the procedure with 11.1V battery connected, same result.


(ppoirier) #13

We are gerring close to the source… what release have you loaded on the PixRacer?


(chris rey) #14

yes, hope so! yesterday 3.5.2 and this morning the latest 3.5.3.


(ppoirier) #15

Thats pretty up to date :wink:
Do you have a ftdi serial to usb or a telemetry radio to check if this signal is corretly fed through serial telemetry?


(chris rey) #16

yes, have FTDI to usb, or FrSky Telemetry Taranis Q X7 can try this Monday, if you have any instructions. a nice weekend, Chris


(ppoirier) #17

Basically you set the serial port on the PixRacer as a mavlink with the desired speed and on Mission planner you connect to the FDTDI-USB port at the same speed.


(cookmangr) #18

Chris what type do you put on range type?
In wiki it says 4 but there is no 4 on mission planner values

http://ardupilot.org/copter/docs/common-rangefinder-maxbotixi2c.htmll


(ppoirier) #19

Hello,

wiki might be outdated, look here:
http://ardupilot.org/copter/docs/parameters.html#rngfnd-type-rangefinder-type


(chris rey) #20

@cookmangr, I opened an issue some days ago for this error, the right value is 2 https://github.com/ArduPilot/ardupilot_wiki/issues/942