IQ.Pilot Prebuilt Release @ 27f668a
This commit is contained in:
14
iqpilot/common/mock/generators.py
Normal file
14
iqpilot/common/mock/generators.py
Normal file
@@ -0,0 +1,14 @@
|
||||
from iqpilot.cereal import messaging
|
||||
|
||||
|
||||
def generate_deviceMotion():
|
||||
msg = messaging.new_message('deviceMotion')
|
||||
meas = {'x': 0.0, 'y': 0.0, 'z': 0.0, 'xStd': 0.0, 'yStd': 0.0, 'zStd': 0.0, 'valid': True}
|
||||
msg.deviceMotion.orientationNED = meas
|
||||
msg.deviceMotion.velocityDevice = meas
|
||||
msg.deviceMotion.angularVelocityDevice = meas
|
||||
msg.deviceMotion.accelerationDevice = meas
|
||||
msg.deviceMotion.inputsOK = True
|
||||
msg.deviceMotion.posenetOK = True
|
||||
msg.deviceMotion.sensorsOK = True
|
||||
return msg
|
||||
Reference in New Issue
Block a user