27#include "uavcan/uavcan.h"
29#include "uavcan.equipment.ahrs.MagneticFieldStrength.h"
30#include "uavcan.equipment.ahrs.MagneticFieldStrength2.h"
52 msg.magnetic_field_ga[0] * 8192,
53 msg.magnetic_field_ga[1] * 8192,
54 msg.magnetic_field_ga[2] * 8192,
59#if MAG_UAVCAN_SYNC_SEND
78 msg.magnetic_field_ga[0] * 8192,
79 msg.magnetic_field_ga[1] * 8192,
80 msg.magnetic_field_ga[2] * 8192,
86#if MAG_UAVCAN_SYNC_SEND
Main include for ABI (AirBorneInterface).
#define MAG_UAVCAN_SENDER_ID
uint32_t get_sys_time_usec(void)
Get the time in microseconds since startup.
Main uavcan event structure for registering/calling callbacks.
Common code for AP and FBW telemetry.
#define int32_rmat_of_eulers
Rotation matrix from Euler angles.
uint8_t msg[10]
Buffer used for general comunication over SPI (out buffer)
void imu_set_defaults_mag(uint8_t abi_id, const struct Int32RMat *imu_to_sensor, const struct Int32Vect3 *neutral, const struct FloatVect3 *scale_f)
Set the defaults for a mag sensor WARNING: Should be called before sensor is publishing messages to e...
Inertial Measurement Unit interface.
void mag_uavcan_init(void)
static uavcan_event mag_uavcan_ev
static struct FloatVect3 default_uavcan_mag_scale
static void mag_uavcan_cb(struct uavcan_iface_t *iface, CanardRxTransfer *transfer)
static uavcan_event mag_uavcan_ev2
static void mag_uavcan_cb2(struct uavcan_iface_t *iface, CanardRxTransfer *transfer)
uavcan interface structure
void uavcan_bind(uint16_t data_type_id, uint64_t data_type_signature, uavcan_event *ev, uavcan_callback cb)
Bind to a receiving message from uavcan.
unsigned int uint32_t
Typedef defining 32 bit unsigned int type.
unsigned char uint8_t
Typedef defining 8 bit unsigned char type.
int transfer(const Mat *from, const image_t *to)