Functions | Variables
xbot_checker3 Namespace Reference

Functions

def check (s)
 
def getCameraId ()
 
def recv (serial)
 

Variables

 acc_x = struct.unpack('<h', payload[8:12].decode('hex'))[0]
 
 acc_y = struct.unpack('<h', payload[12:16].decode('hex'))[0]
 
 acc_z = struct.unpack('<h', payload[16:20].decode('hex'))[0]
 
bool arm_pluged = False
 
string cmd = 'udevadm info -a -n '
 
 data = str(binascii.b2a_hex(s))
 
bool debug = False
 
 dev_name = str(port_list[i]).split(' ')[0]
 
 error_status = struct.unpack('B', payload[100:102].decode('hex'))[0]
 
 f = open("udev/73-xbot.rules",'r')
 
 gyro_x = struct.unpack('<h', payload[20:24].decode('hex'))[0]
 
 gyro_y = struct.unpack('<h', payload[24:28].decode('hex'))[0]
 
 gyro_z = struct.unpack('<h', payload[28:32].decode('hex'))[0]
 
 label = payload[0:2]
 
string label_arm = 'USB2.0-Serial'
 
string label_PCB1 = 'aa5530'
 
string label_PCB2 = 'aa5538'
 
string label_rplidar = 'CP2102'
 
 left_encoder = int(payload[2:6],16)
 
 mag_x = struct.unpack('<h', payload[32:36].decode('hex'))[0]
 
 mag_y = struct.unpack('<h', payload[36:40].decode('hex'))[0]
 
 mag_z = struct.unpack('<h', payload[40:44].decode('hex'))[0]
 
 output
 
 payload = ss_PCB1[6:-2]
 
 PCB1_dev_name = dev_name
 
bool PCB1_pluged = False
 
 PCB1_serial = output.split('"')[1]
 
 PCB2_dev_name = dev_name
 
bool PCB2_pluged = False
 
 PCB2_serial = output.split('"')[1]
 
 pitch = struct.unpack('<f', payload[52:60].decode('hex'))[0]
 
 pitch_platform = struct.unpack('B', payload[4:6].decode('hex'))[0]
 
 port_list = list(serial.tools.list_ports.comports())
 
 port_num = len(port_list)
 
 q1 = struct.unpack('<f', payload[68:76].decode('hex'))[0]
 
 q2 = struct.unpack('<f', payload[76:84].decode('hex'))[0]
 
 q3 = struct.unpack('<f', payload[84:92].decode('hex'))[0]
 
 q4 = struct.unpack('<f', payload[92:100].decode('hex'))[0]
 
 roll = struct.unpack('<f', payload[60:68].decode('hex'))[0]
 
bool rplidar_pluged = False
 
 s = recv(serial1)
 
 serial1 = serial.Serial(dev_name, 115200, timeout=0.5)
 
string ss = ''
 
string ss_PCB1 = ''
 
string ss_PCB2 = ''
 
 status
 
 time_stamp = struct.unpack('<H', payload[102:106].decode('hex'))[0]
 
 volume = struct.unpack('B', payload[6:8].decode('hex'))[0]
 
 yaw = -struct.unpack('<f', payload[44:52].decode('hex'))[0]
 
 yaw_platform = struct.unpack('B', payload[2:4].decode('hex'))[0]
 

Function Documentation

def xbot_checker3.check (   s)

Definition at line 203 of file xbot_checker3.py.

def xbot_checker3.getCameraId ( )

Definition at line 30 of file xbot_checker3.py.

def xbot_checker3.recv (   serial)

Definition at line 146 of file xbot_checker3.py.

Variable Documentation

xbot_checker3.acc_x = struct.unpack('<h', payload[8:12].decode('hex'))[0]

Definition at line 265 of file xbot_checker3.py.

xbot_checker3.acc_y = struct.unpack('<h', payload[12:16].decode('hex'))[0]

Definition at line 266 of file xbot_checker3.py.

xbot_checker3.acc_z = struct.unpack('<h', payload[16:20].decode('hex'))[0]

Definition at line 267 of file xbot_checker3.py.

bool xbot_checker3.arm_pluged = False

Definition at line 85 of file xbot_checker3.py.

string xbot_checker3.cmd = 'udevadm info -a -n '

Definition at line 232 of file xbot_checker3.py.

xbot_checker3.data = str(binascii.b2a_hex(s))

Definition at line 181 of file xbot_checker3.py.

bool xbot_checker3.debug = False

Definition at line 28 of file xbot_checker3.py.

xbot_checker3.dev_name = str(port_list[i]).split(' ')[0]

Definition at line 166 of file xbot_checker3.py.

xbot_checker3.error_status = struct.unpack('B', payload[100:102].decode('hex'))[0]

Definition at line 281 of file xbot_checker3.py.

xbot_checker3.f = open("udev/73-xbot.rules",'r')

Definition at line 236 of file xbot_checker3.py.

xbot_checker3.gyro_x = struct.unpack('<h', payload[20:24].decode('hex'))[0]

Definition at line 268 of file xbot_checker3.py.

xbot_checker3.gyro_y = struct.unpack('<h', payload[24:28].decode('hex'))[0]

Definition at line 269 of file xbot_checker3.py.

xbot_checker3.gyro_z = struct.unpack('<h', payload[28:32].decode('hex'))[0]

Definition at line 270 of file xbot_checker3.py.

xbot_checker3.label = payload[0:2]

Definition at line 223 of file xbot_checker3.py.

string xbot_checker3.label_arm = 'USB2.0-Serial'

Definition at line 130 of file xbot_checker3.py.

string xbot_checker3.label_PCB1 = 'aa5530'

Definition at line 88 of file xbot_checker3.py.

string xbot_checker3.label_PCB2 = 'aa5538'

Definition at line 92 of file xbot_checker3.py.

string xbot_checker3.label_rplidar = 'CP2102'

Definition at line 115 of file xbot_checker3.py.

xbot_checker3.left_encoder = int(payload[2:6],16)

Definition at line 227 of file xbot_checker3.py.

xbot_checker3.mag_x = struct.unpack('<h', payload[32:36].decode('hex'))[0]

Definition at line 271 of file xbot_checker3.py.

xbot_checker3.mag_y = struct.unpack('<h', payload[36:40].decode('hex'))[0]

Definition at line 272 of file xbot_checker3.py.

xbot_checker3.mag_z = struct.unpack('<h', payload[40:44].decode('hex'))[0]

Definition at line 273 of file xbot_checker3.py.

xbot_checker3.output

Definition at line 233 of file xbot_checker3.py.

xbot_checker3.payload = ss_PCB1[6:-2]

Definition at line 222 of file xbot_checker3.py.

xbot_checker3.PCB1_dev_name = dev_name

Definition at line 197 of file xbot_checker3.py.

bool xbot_checker3.PCB1_pluged = False

Definition at line 87 of file xbot_checker3.py.

xbot_checker3.PCB1_serial = output.split('"')[1]

Definition at line 234 of file xbot_checker3.py.

xbot_checker3.PCB2_dev_name = dev_name

Definition at line 191 of file xbot_checker3.py.

bool xbot_checker3.PCB2_pluged = False

Definition at line 91 of file xbot_checker3.py.

xbot_checker3.PCB2_serial = output.split('"')[1]

Definition at line 289 of file xbot_checker3.py.

xbot_checker3.pitch = struct.unpack('<f', payload[52:60].decode('hex'))[0]

Definition at line 275 of file xbot_checker3.py.

xbot_checker3.pitch_platform = struct.unpack('B', payload[4:6].decode('hex'))[0]

Definition at line 263 of file xbot_checker3.py.

xbot_checker3.port_list = list(serial.tools.list_ports.comports())

Definition at line 97 of file xbot_checker3.py.

int xbot_checker3.port_num = len(port_list)

Definition at line 98 of file xbot_checker3.py.

xbot_checker3.q1 = struct.unpack('<f', payload[68:76].decode('hex'))[0]

Definition at line 277 of file xbot_checker3.py.

xbot_checker3.q2 = struct.unpack('<f', payload[76:84].decode('hex'))[0]

Definition at line 278 of file xbot_checker3.py.

xbot_checker3.q3 = struct.unpack('<f', payload[84:92].decode('hex'))[0]

Definition at line 279 of file xbot_checker3.py.

xbot_checker3.q4 = struct.unpack('<f', payload[92:100].decode('hex'))[0]

Definition at line 280 of file xbot_checker3.py.

xbot_checker3.roll = struct.unpack('<f', payload[60:68].decode('hex'))[0]

Definition at line 276 of file xbot_checker3.py.

bool xbot_checker3.rplidar_pluged = False

Definition at line 84 of file xbot_checker3.py.

string xbot_checker3.s = recv(serial1)

Definition at line 178 of file xbot_checker3.py.

xbot_checker3.serial1 = serial.Serial(dev_name, 115200, timeout=0.5)

Definition at line 168 of file xbot_checker3.py.

xbot_checker3.ss = ''

Definition at line 165 of file xbot_checker3.py.

string xbot_checker3.ss_PCB1 = ''

Definition at line 89 of file xbot_checker3.py.

string xbot_checker3.ss_PCB2 = ''

Definition at line 93 of file xbot_checker3.py.

xbot_checker3.status

Definition at line 233 of file xbot_checker3.py.

xbot_checker3.time_stamp = struct.unpack('<H', payload[102:106].decode('hex'))[0]

Definition at line 282 of file xbot_checker3.py.

xbot_checker3.volume = struct.unpack('B', payload[6:8].decode('hex'))[0]

Definition at line 264 of file xbot_checker3.py.

xbot_checker3.yaw = -struct.unpack('<f', payload[44:52].decode('hex'))[0]

Definition at line 274 of file xbot_checker3.py.

xbot_checker3.yaw_platform = struct.unpack('B', payload[2:4].decode('hex'))[0]

Definition at line 262 of file xbot_checker3.py.



xbot_tools
Author(s):
autogenerated on Sat Oct 10 2020 03:28:22