12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455 |
- #ifndef HVCALLBACK_H_
- #define HVCALLBACK_H_
- #include <uavcan/uavcan.hpp>
- #include <AP_HAL/CAN.h>
- #include <AP_HAL/Semaphores.h>
- #include <AP_Param/AP_Param.h>
- #include <uavcan/helpers/heap_based_pool_allocator.hpp>
- #include "AP_UAVCAN_Servers.h"
- struct HVmes
- {
- int16_t voltage;
- int32_t speed;
- int16_t currentlimit;
- uint32_t fault;
- int16_t Imax;
- int16_t speedref;
- int16_t torqueIQ;
- int16_t temperature;
- int16_t motortemperature;
-
- };
- extern uint8_t hv_motor_cmd_temp ;
- extern uint8_t hv_motor_cmd;
- extern int16_t hv_motor_speed_32 ;
- struct HVmotor
- {
-
- int16_t speed;
- int16_t current;
- int16_t voltage;
- int16_t temperature;
- int16_t motortemperature;
- uint16_t fault;
-
- };
-
- void HVcycle(uint8_t _code,uint8_t _buffer[6],HVmes &Thruster);
- void Haoye(uint8_t _buffer[7],HVmotor &HVmotor);
- #endif
|