mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-24 07:33:34 +08:00
Drivers: fix formatting
This commit is contained in:
@@ -61,7 +61,7 @@ public:
|
||||
CH_VOLTAGE_LEFT = 0,
|
||||
CH_VOLTAGE_RIGHT
|
||||
};
|
||||
|
||||
|
||||
/** motors */
|
||||
enum e_motor {
|
||||
MOTOR_1 = 0,
|
||||
@@ -70,15 +70,15 @@ public:
|
||||
|
||||
/**
|
||||
* constructor
|
||||
* @param deviceName the name of the
|
||||
* @param deviceName the name of the
|
||||
* serial port e.g. "/dev/ttyS2"
|
||||
* @param address the adddress of the motor
|
||||
* (selectable on roboclaw)
|
||||
* @param pulsesPerRev # of encoder
|
||||
* pulses per revolution of wheel
|
||||
*/
|
||||
RoboClaw(const char *deviceName, uint16_t address,
|
||||
uint16_t pulsesPerRev);
|
||||
RoboClaw(const char *deviceName, uint16_t address,
|
||||
uint16_t pulsesPerRev);
|
||||
|
||||
/**
|
||||
* deconstructor
|
||||
@@ -153,7 +153,7 @@ private:
|
||||
|
||||
// advanced motor control
|
||||
CMD_READ_SPEED_HIRES_1 = 30,
|
||||
CMD_READ_SPEED_HIRES_2 = 31,
|
||||
CMD_READ_SPEED_HIRES_2 = 31,
|
||||
CMD_SIGNED_DUTYCYCLE_1 = 32,
|
||||
CMD_SIGNED_DUTYCYCLE_2 = 33,
|
||||
};
|
||||
@@ -181,12 +181,12 @@ private:
|
||||
int16_t _motor2Overflow;
|
||||
|
||||
// private methods
|
||||
uint16_t _sumBytes(uint8_t * buf, size_t n);
|
||||
int _sendCommand(e_command cmd, uint8_t * data, size_t n_data, uint16_t & prev_sum);
|
||||
uint16_t _sumBytes(uint8_t *buf, size_t n);
|
||||
int _sendCommand(e_command cmd, uint8_t *data, size_t n_data, uint16_t &prev_sum);
|
||||
};
|
||||
|
||||
// unit testing
|
||||
int roboclawTest(const char *deviceName, uint8_t address,
|
||||
uint16_t pulsesPerRev);
|
||||
uint16_t pulsesPerRev);
|
||||
|
||||
// vi:noet:smarttab:autoindent:ts=4:sw=4:tw=78
|
||||
|
||||
Reference in New Issue
Block a user