byq77/vl53l0x-mbed

No matching constructor?

Opened this issue · 1 comments

Hi, I'm trying to use this library on Mbed, but can't get it set up.
I'm trying this:

I2C i2c(D14,D15);
Timer timer;
VL53L0X sensor(&i2c, &timer);

But get no matching constructor error.
Any suggestions?
Many thanks

Hi! I had the same doubt . You only need to use the name of the instance:

I2C i2c(D14, D15); Timer timer; VL53L0X sensor(i2c, timer);

Like a array, you can pass the address of the array like that:

int array[5]; function(array); function2(&array[0]);

But in your case its just a objetc, so only give the name.