|
Paparazzi UAS
v5.12_stable-4-g9b43e9b
Paparazzi is a free software Unmanned Aircraft System.
|
Actuator driver for the bebop. More...
Include dependency graph for actuators.h:
This graph shows which files directly or indirectly include this file:Go to the source code of this file.
Data Structures | |
| struct | ActuatorsBebop |
Macros | |
| #define | ACTUATORS_BEBOP_ADDR 0x10 |
| #define | ACTUATORS_BEBOP_SET_REF_SPEED 0x02 |
| Set reference speed. More... | |
| #define | ACTUATORS_BEBOP_GET_OBS_DATA 0x20 |
| Get observation data. More... | |
| #define | ACTUATORS_BEBOP_START_PROP 0x40 |
| Start the propellers. More... | |
| #define | ACTUATORS_BEBOP_TOGGLE_GPIO 0x4D |
| Toggle GPIO (reset, red led, green led) More... | |
| #define | ACTUATORS_BEBOP_STOP_PROP 0x60 |
| Stop the propellers. More... | |
| #define | ACTUATORS_BEBOP_CLEAR_ERROR 0x80 |
| Clear all current erros. More... | |
| #define | ACTUATORS_BEBOP_PLAY_SOUND 0x82 |
| Play a sound (0=stop, 1=short beep, 2=boot beep, 3=Be-Bop-Ah-Lula, negative=repeat) More... | |
| #define | ACTUATORS_BEBOP_GET_INFO 0xA0 |
| Get version information. More... | |
| #define | ActuatorsBebopSet(_i, _v) { actuators_bebop.rpm_ref[_i] = _v; } |
| #define | ActuatorsBebopCommit() actuators_bebop_commit(); |
| #define | ActuatorsBebopInit() actuators_bebop_init(); |
Functions | |
| void | actuators_bebop_commit (void) |
| void | actuators_bebop_init (void) |
Variables | |
| struct ActuatorsBebop | actuators_bebop |
Actuator driver for the bebop.
Definition in file actuators.h.
| struct ActuatorsBebop |
Definition at line 48 of file actuators.h.
Collaboration diagram for ActuatorsBebop:| Data Fields | ||
|---|---|---|
| struct i2c_transaction | i2c_trans | I2C transaction for communicating with the bebop BLDC driver. |
| uint8_t | led | Current led status. |
| uint16_t | rpm_obs[4] | Observed RPM. |
| uint16_t | rpm_ref[4] | Reference RPM. |
| #define ACTUATORS_BEBOP_ADDR 0x10 |
Definition at line 35 of file actuators.h.
Referenced by actuators_bebop_init().
| #define ACTUATORS_BEBOP_CLEAR_ERROR 0x80 |
Clear all current erros.
Definition at line 43 of file actuators.h.
Referenced by actuators_bebop_commit().
| #define ACTUATORS_BEBOP_GET_INFO 0xA0 |
Get version information.
Definition at line 45 of file actuators.h.
| #define ACTUATORS_BEBOP_GET_OBS_DATA 0x20 |
Get observation data.
Definition at line 39 of file actuators.h.
Referenced by actuators_bebop_commit().
| #define ACTUATORS_BEBOP_PLAY_SOUND 0x82 |
Play a sound (0=stop, 1=short beep, 2=boot beep, 3=Be-Bop-Ah-Lula, negative=repeat)
Definition at line 44 of file actuators.h.
| #define ACTUATORS_BEBOP_SET_REF_SPEED 0x02 |
Set reference speed.
Definition at line 38 of file actuators.h.
Referenced by actuators_bebop_commit().
| #define ACTUATORS_BEBOP_START_PROP 0x40 |
Start the propellers.
Definition at line 40 of file actuators.h.
Referenced by actuators_bebop_commit().
| #define ACTUATORS_BEBOP_STOP_PROP 0x60 |
Stop the propellers.
Definition at line 42 of file actuators.h.
Referenced by actuators_bebop_commit().
| #define ACTUATORS_BEBOP_TOGGLE_GPIO 0x4D |
Toggle GPIO (reset, red led, green led)
Definition at line 41 of file actuators.h.
Referenced by actuators_bebop_commit().
| #define ActuatorsBebopCommit | ( | ) | actuators_bebop_commit(); |
Definition at line 56 of file actuators.h.
| #define ActuatorsBebopInit | ( | ) | actuators_bebop_init(); |
Definition at line 57 of file actuators.h.
| #define ActuatorsBebopSet | ( | _i, | |
| _v | |||
| ) | { actuators_bebop.rpm_ref[_i] = _v; } |
Definition at line 55 of file actuators.h.
| void actuators_bebop_commit | ( | void | ) |
Definition at line 73 of file actuators.c.
References actuators_bebop, actuators_bebop_checksum(), ACTUATORS_BEBOP_CLEAR_ERROR, ACTUATORS_BEBOP_GET_OBS_DATA, ACTUATORS_BEBOP_SET_REF_SPEED, ACTUATORS_BEBOP_START_PROP, ACTUATORS_BEBOP_STOP_PROP, ACTUATORS_BEBOP_TOGGLE_GPIO, autopilot_get_motors_on(), autopilot_set_motors_on(), i2c_transaction::buf, electrical, FALSE, ActuatorsBebop::i2c_trans, i2c_transceive(), i2c_transmit(), ActuatorsBebop::led, led_hw_values, ActuatorsBebop::rpm_obs, ActuatorsBebop::rpm_ref, RPM_SENSOR_ID, i2c_transaction::slave_addr, and Electrical::vsupply.
Here is the call graph for this function:| void actuators_bebop_init | ( | void | ) |
Definition at line 61 of file actuators.c.
References actuators_bebop, ACTUATORS_BEBOP_ADDR, DefaultPeriodic, ActuatorsBebop::i2c_trans, I2CTransDone, ActuatorsBebop::led, register_periodic_telemetry(), send_bebop_actuators(), i2c_transaction::slave_addr, and i2c_transaction::status.
Here is the call graph for this function:| struct ActuatorsBebop actuators_bebop |
Definition at line 58 of file actuators.c.
Referenced by actuators_bebop_commit(), actuators_bebop_init(), and send_bebop_actuators().