[SOLVED] distance sensor VL6180

Please do not post requests
acronis
Posts: 144
Joined: Thu Mar 02, 2017 12:32 pm

[SOLVED] distance sensor VL6180

Post by acronis » Tue Jun 27, 2017 7:05 am

Hello. Tell me which library is better to use and how to physically connect STM32F103 distance sensor VL6180 https://ru.aliexpress.com/item/1PCS-VL6 ... 0.0.t4kPJc
Last edited by acronis on Thu Jul 13, 2017 5:29 am, edited 1 time in total.

User avatar
zoomx
Posts: 541
Joined: Mon Apr 27, 2015 2:28 pm
Location: Mt.Etna, Italy

Re: distance sensor VL6180

Post by zoomx » Tue Jun 27, 2017 7:17 am

mmmm I bought a VL53L0X and used the first library I found, maybe these sensors use the same protocol.

acronis
Posts: 144
Joined: Thu Mar 02, 2017 12:32 pm

Re: distance sensor VL6180

Post by acronis » Tue Jun 27, 2017 8:20 am

How to connect the PIN SCL and SDA VL6180 Breakout to the STM32F103?
They are tolerant only to 2.8 V

https://cdn.sparkfun.com/datasheets/Sen ... ut_v10.pdf

https://learn.sparkfun.com/tutorials/vl ... okup-guide

User avatar
zoomx
Posts: 541
Joined: Mon Apr 27, 2015 2:28 pm
Location: Mt.Etna, Italy

Re: distance sensor VL6180

Post by zoomx » Tue Jun 27, 2017 10:51 am

If you have only the sensor you have to build a circuit similar to the sparkfun one.
For example this one
Image
Wiring Diagram for VL6180 Breakout and 3.3v Pro-Mini
that you can find in the second link of your first post.

Since the promini is the 3.3V version, values are the same for the STM32 board

acronis
Posts: 144
Joined: Thu Mar 02, 2017 12:32 pm

Re: distance sensor VL6180

Post by acronis » Tue Jun 27, 2017 2:08 pm

NOTE: To use this diagram make sure the two pull-up resistors on the Pro-Mini are NOT populated.

such a connection possible if not soldered the resistors on the PRO MINI.
And how it on STM32 ?

stevestrong
Posts: 1829
Joined: Mon Oct 19, 2015 12:06 am
Location: Munich, Germany

Re: distance sensor VL6180

Post by stevestrong » Tue Jun 27, 2017 2:24 pm

Which STM32 board do you use?
In general, on STM32 boards there are no resistors mounted on non-reserved IO pins.

acronis
Posts: 144
Joined: Thu Mar 02, 2017 12:32 pm

Re: distance sensor VL6180

Post by acronis » Tue Jun 27, 2017 2:36 pm

https://ru.aliexpress.com/item/2-STM32F ... 0.0.D46SwF

I'm doing a direct connection of pins SCL and SDA ? but what about the maximum voltage 2,8 V ?

stevestrong
Posts: 1829
Joined: Mon Oct 19, 2015 12:06 am
Location: Munich, Germany

Re: distance sensor VL6180

Post by stevestrong » Tue Jun 27, 2017 3:13 pm

acronis wrote:
Tue Jun 27, 2017 2:36 pm
I'm doing a direct connection of pins SCL and SDA ?
Yes.
BreakoutAnnotated[1].png
BreakoutAnnotated[1].png (189.96 KiB) Viewed 455 times
acronis wrote:
Tue Jun 27, 2017 2:36 pm
but what about the maximum voltage 2,8 V ?
You have to provide yourself, as @zoomx mentioned above (using LM317)

User avatar
RogerClark
Posts: 7481
Joined: Mon Apr 27, 2015 10:36 am
Location: Melbourne, Australia
Contact:

Re: distance sensor VL6180

Post by RogerClark » Tue Jun 27, 2017 9:41 pm

How much current does it take?

Perhaps you can drop 3.3v to 2.7 with 2 diodes in series

acronis
Posts: 144
Joined: Thu Mar 02, 2017 12:32 pm

Re: distance sensor VL6180

Post by acronis » Thu Jul 13, 2017 5:28 am

https://github.com/adafruit/Adafruit_VL6180X

This library works fine on STM32.
Last edited by acronis on Thu Jul 13, 2017 8:39 am, edited 1 time in total.

Post Reply