GY-53 VL53L0X Laser ToF Flight Time Range Sensor Module Serial PWM Output

From Wiki
Jump to: navigation, search

Introduction

VL53L0X 0.png VL53L0X 1.png
GY-53 is a low cost digital infrared distance measurement sensor module. It’s working voltage is 3~5V, and it has many advantages: low power consumption, small volume, easy to mount. The operating principle is that the light of infrared LED irradiates the object under test before the reflected light being received by MCU. What MCU does is to output distance value by calculating time difference. This module has two modes to read value: one is serial port UART (TTL electrical level) + PWM (Line 1); the other is Chip IIC Mode. The baud rate of serial ports can be 9600bps or 115200bps. The configurable module has two kinds of output modes, continuous output and inquiry output; also, it has power fail safeguard.

Features

  • Measure Range: 0~2m;
  • Frequency: 22ms (maximum);
  • Working Voltage: 3~5V;
  • Working Electric Current: 25mA;
  • Storage Temperature: -20° ~ 85°;
  • Size: 25mm x 15.6mm;
  • Sensor Chip: VL53LOX.

Introduction of Pins

Introduction of Pins
VCC Power Supply+ (3v-5v)
GND Ground
TX Serial Port USART_TX
RX Serial Port USART_RX
PWM Distance is converted into the PWM form
PS Serial Port/IIC Mode Conversion
XSHUT Chip Pin
GPIO1 Chip Pin
SDA Chip SDA
SCL Chip SCL
GND Ground
VCC Power Supply+ (3v-5v)

Principle

GY-53 is a low cost digital infrared distance measurement sensor module. It`s working voltage is 3~5V, and it has many advantages: low power consumption, small volume, easy to mount. The operating principle is that the light of infrared LED irradiates the object under test before the reflected light being received by MCU. What MCU does is to output distance value by calculating time difference. This module has two modes to read value: one is serial port UART (TTL electrical level) + PWM (Line 1); the other is Chip IIC Mode. The baud rate of serial ports can be 9600bps or 115200bps. The configurable module has two kinds of output modes, continuous output and inquiry output; also, it has power fail safeguard.

Experimental Procedures for Arduino

Step 1: Connect the circuit:
VL53L0X 2.png
Step 2:Compile and upload the code.

int pin =5;
unsigned long duration;
void setup() {
   Serial.begin(9600);  
   pinMode(pin, INPUT);
   delay(500); 
}

void loop() {

          uint16_t distance=0;
          duration = pulseIn(pin, HIGH);
          distance=duration/10;
          
           Serial.print("distance: ");
           Serial.print( distance);
           Serial.print(" mm,time: ");
           Serial.print( duration); 
           Serial.println("us");
           delay(100);   
}

VL53L0X 3.png