Benewake TFmini LIDAR works on Ardupilot

no there is a new TF Mini that supports I2C.
The old one is still serial

1 Like

Thanks Ricky. So for existing projects the converter is still the way forward if we want i2c? To be honest I’ve come to terms with using a dozen CP2102 usb-serial adaptors as these can power the TFMini too so not that bothered…
Do you know anything about whether the new TFMini Plus will support i2c out of the box?

2 Likes

Yes I am no expert but I know there is an I2C version. I have attached the tech notes on it.
I believe there will be two versions going forward. I2c and UART.
I am seriously thinking of moving to an I2C version so I am not taking up all my uart ports.

Enjoy the read.,
02_TFmini-I²C-Datasheet V1.1 EN.pdf (401.6 KB)

1 Like

I did see that datasheet before; it’s a bit strange as it’s not listed anywhere on Benewake’s page so I was half-wondering if it actually simply refers to this product, which is just the normal version with an external serial-i2c adapter: https://www.sparkfun.com/products/14786
This seems a bit different to a few other discussions; one from Benewake talking about a task to add firmware support for the i2c, and to this image, which shows a TFMini (V1.5.3, no other markings) but talks about i2c addresses - I’m a little confused; can’t find where this image originates either…

At this point I would defer to Patrick.
I got an email a week ago about the I2C version. But Patrick is the pro on the subject.

1 Like

I am guessing that technically both units could use the same hardware platform (see below), but this might not be possible for different reasons like support or warranty, @Siya might be able to answer.

They are sold as 2 different units @ sparkfun

2 Likes

See this is why Patrick is my hero
Plus he is Canadian…Thats an extra point for him lol

2 Likes

Yeah, feel like the Sparkfun offering confuses the matter. This device, part of that product, is a separate serial-to-i2c converter, produced by Benewaake, which would work just fine with any TFMini:


That’s not the same as the circuit in the other image, which appears to show an actual TFMini module that natively supports I2C (which is also what the thread about firmware elsewhere implies).#

My question, basically, is: Is there a separate TFMini module that supports i2c without the “boost” board? If so, where can one get it and other related questions.

1 Like

This is not a Serial to I2c converter, it is a power conditionner + a I2C bus driver… look on previous posts above , I made the same wrong assumption :wink:

2 Likes

Aha. Thanks so much, that makes a lot more sense!

1 Like

Hi, everyone. TFmini I2C version and TFmini UART serial version are two different versions, we could say they are different TFmini. : )

2 Likes

Thanks for the clarification Siya. That being the case, a few questions:
If there, or will there be, an i2c version of the TFMini Plus?
Is SparkFun currently the only place stocking the i2c TFMini?

@Shao Yes, TFmini Plus will have I2C version too, it will be ready after some time. Now Sparkfun have the I2C TFmini, other distributor will have it after some time.

New LiDAR TFmini Plus is developed based on TFmini, higher accuracy, higher frequency 1000Hz, IP65 weatherproof case, and can be found on IR-LOCK store:

1 Like

I have tried this setup exactly as well as rngfnd_type, 20. Is 20 supported on 3.6.6 stable? In either case I only get Bad LiDAR health. I have tried ticking pix mode as well as sending the string of characters using the TFMini Tool. Any Insight?

For those here eager to test, I just submitted the PR to support TFMini Plus on I2C:

3 Likes

Hi @lucasdemarchi, great work!
I have no Plus to test, but I tried to get work the TFMini i2c (no plus) version, but for some reason with no luck.
The Plus version seems having different protocol, unfortunately.

What is the reason here to do two transfer() calls instead of single call?

void AP_RangeFinder_Benewake_TFMiniPlus::timer()
{ …
ret = _dev->transfer(CMD_READ_MEASUREMENT, sizeof(CMD_READ_MEASUREMENT), nullptr, 0);
if (!ret || !_dev->transfer(nullptr, 0, (uint8_t *)&u, sizeof(u))) {
return;
}

Good evening lucasdemarchi.

This is very interesting. Is this for collision avoidance (multiple TFMini plus) or altitude control?

Cheers.

Henri

Yes, with I2C you can use multiple devices for avoidance and altitude range

@Sergey_Zakhodylo TFmini has another protocol and the sensor that supports uart doesn’t support I2C. You need a TFmini Plus for it to work.

2 transfer calls because the sensor is not an usual I2C sensor with a regmap. Maybe it works with transfer only, but it’s not what is documented

@henrik04 can be used for either or both.