예제 #1
0
 /**
  * RawImu constructor.
  * @param $entry
  */
 public function __construct($entry)
 {
     parent::__construct($entry);
     $this->xacc = $this->int16_t(8, 9);
     $this->yacc = $this->int16_t(10, 11);
     $this->zacc = $this->int16_t(12, 13);
     $this->xgyro = $this->int16_t(14, 15);
     $this->ygyro = $this->int16_t(16, 17);
     $this->zgyro = $this->int16_t(18, 19);
     $this->xmag = $this->int16_t(20, 21);
     $this->ymag = $this->int16_t(22, 23);
     $this->zmag = $this->int16_t(24, 25);
 }
예제 #2
0
 /**
  * GpsRawInt constructor.
  * @param $entry
  */
 public function __construct($entry)
 {
     parent::__construct($entry);
     $this->lat = $this->int32_t(8, 11) / 10000000;
     $this->lon = $this->int32_t(12, 15) / 10000000;
     $this->alt = $this->int32_t(16, 19) / 1000;
     $this->eph = $this->uint16_t(20, 21) / 100;
     $this->evp = $this->uint16_t(22, 23) / 100;
     $this->vel = $this->uint16_t(24, 25) / 100;
     $this->cog = $this->uint16_t(26, 27) / 100;
     $this->fix_type = $this->uint8_t(28);
     $this->satellites_visible = $this->uint8_t(29);
 }
예제 #3
0
 /**
  * ServoOutputRaw constructor.
  * @param $entry
  */
 public function __construct($entry)
 {
     parent::__construct($entry);
     $this->servo1_raw = $this->uint16_t(4, 5);
     $this->servo2_raw = $this->uint16_t(6, 7);
     $this->servo3_raw = $this->uint16_t(8, 9);
     $this->servo4_raw = $this->uint16_t(10, 11);
     $this->servo5_raw = $this->uint16_t(12, 13);
     $this->servo6_raw = $this->uint16_t(14, 15);
     $this->servo7_raw = $this->uint16_t(16, 17);
     $this->servo8_raw = $this->uint16_t(18, 19);
     $this->port = $this->uint8_t(20);
 }