Go to the documentation of this file.00001 __author__ = 'tom1231'
00002 import struct
00003 from BAL.Header.RiCHeader import RiCHeader
00004 from BAL.Handlers.incomingHandler import IMU_REQ
00005
00006 MSG_LEN = 7
00007
00008
00009 class IMURequest(RiCHeader):
00010 def __init__(self, status):
00011 RiCHeader.__init__(self)
00012
00013 self._id = IMU_REQ
00014 self._length = MSG_LEN
00015 self._des = 0x1001
00016 self._checkSum = 0
00017
00018 self.status = status
00019
00020 self._checkSum = self.calCheckSum(self.dataTosend())
00021
00022 def dataTosend(self):
00023 return RiCHeader.dataTosend(self) + struct.pack('<B', self.status)