rcute_cozmars.ir_sensor¶
-
class
rcute_cozmars.ir_sensor.IRSensors(robot)¶ Infrared Sensors at the bottom
-
when_state_changed= None¶ Callback function, called when the value of any infrared sensor at the bottom changes, the default is None
The callback function accepts one parameter, which is a tuple composed of the values of two infrared sensors
-
state¶ A two-element tuple composed of the infrared sensor values, each element is 0 or 1
1 means reflection is received, 0 means no reflection is received
-