Tinybit MicroPython API
www.yahboom.com
10、Ultrasonic module return distance tinybit.ultrasonic()
Function: returns the current distance detected by the ultrasonic module(cm).
11、Left tracking sensor tinybit.traking_sensor_L()
Return value: if black lines are detected returns true, if white lines are detected
return false.
12、Right tracking sensor tinybit.traking_sensor_R()
Return value: if black lines are detected returns true, if white lines are detected
return false.
13、Voice sensor tinybit.getVoicedata()
Function: Get the value of the sound sensor
14、IR control tinybit.init_IR(a)
Function: Initialize infrared remote receiver
Parameter:
a is pin of the infrared receiver
!Note: For building:bit, we need to select pin8
Eg: tinybit.init_IR(pin8)
15、Return button value of IR controller tinybit.get_IR(IR_pin)
Parameter:
a is pin of the infrared receiver
!Note: For building:bit, we need to select pin8
Eg: tinybit.get_IR(pin8)
16、Input this code to import Yahboom Tiny:bit Micropython library:import ghandle




