![]() |
Paparazzi UAS v7.0_unstable
Paparazzi is a free software Unmanned Aircraft System.
|
#include "modules/esc32/esc32.h"
#include "mcu_periph/uart.h"
#include "mcu_periph/sys_time.h"
#include "modules/datalink/downlink.h"
#include <stdio.h>
#include <string.h>
#include "modules/datalink/telemetry.h"
Go to the source code of this file.
Data Structures | |
struct | esc32_ck |
struct | esc32_private |
Macros | |
#define | ESC32_BUF_IN_LEN 64 |
#define | ESC32_BUF_OUT_LEN 32 |
#define | ESC32_PARAMS_LEN 10 |
#define | ESC32_TELEMETRY_RATE 100.0 |
#define | UINIT 0 |
#define | GOT_SYNC 1 |
#define | SEARCH_COMMAND 2 |
#define | GET_CMD_ROWS 3 |
#define | GET_CMD_COLS 4 |
#define | GET_COMMAND 5 |
#define | CHECK_CK_A 6 |
#define | CHECK_CK_B 7 |
Variables | |
struct esc32 | esc32 |
static struct esc32_private | esc32_priv |
Definition in file esc32.c.
struct esc32_private |
Data Fields | ||
---|---|---|
uint8_t | buf_in[ESC32_BUF_IN_LEN] | |
uint8_t | buf_out[ESC32_BUF_OUT_LEN] | |
struct esc32_ck | ck_in | |
struct esc32_ck | ck_out | |
uint16_t | cmd_seq_id | |
struct uart_periph * | dev | |
uint8_t | in_cols | |
uint8_t | in_idx | |
uint8_t | in_rows | |
uint8_t | initialized | |
bool | msg_available | |
uint8_t | out_idx | |
struct esc32_parameter | params[ESC32_PARAMS_LEN] | |
uint8_t | params_idx | |
uint8_t | state |
Definition at line 78 of file esc32.c.
References esc32_ck::ck_a, and esc32_ck::ck_b.
Referenced by esc32_put_char(), and parse_esc32().
Definition at line 352 of file esc32.c.
References esc32_private::dev, esc32_parse_msg(), esc32_priv, esc32_private::msg_available, parse_esc32(), uart_char_available(), and uart_getch().
|
static |
Definition at line 296 of file esc32.c.
References esc32_parameter::amps, foo, esc32_parameter::rpm, esc32_parameter::volts_bat, and esc32_parameter::volts_motor.
Referenced by esc32_parse_msg().
|
static |
Definition at line 242 of file esc32.c.
References esc32_private::cmd_seq_id, DefaultPeriodic, esc32_private::dev, esc32_msg_send(), esc32_priv, foo, and register_periodic_telemetry().
Definition at line 83 of file esc32.c.
References esc32_ck::ck_a, and esc32_ck::ck_b.
Referenced by esc32_send_command(), and parse_esc32().
|
static |
Definition at line 224 of file esc32.c.
References esc32_parameter::amps, dev, esc32::energy, foo, esc32::params, esc32::power, esc32_parameter::rpm, esc32_parameter::volts_bat, and esc32_parameter::volts_motor.
Referenced by esc32_init().
|
static |
Definition at line 315 of file esc32.c.
References esc32_parameter::amps, esc32_filter_data(), esc32_get_float(), ESC32_PARAMS_LEN, ESC32_TELEMETRY_RATE, foo, esc32_parameter::rpm, esc32_parameter::volts_bat, and esc32_parameter::volts_motor.
Referenced by esc32_event().
Definition at line 262 of file esc32.c.
References BINARY_COMMAND_ARM, BINARY_COMMAND_DUTY, BINARY_COMMAND_START, BINARY_COMMAND_STOP, BINARY_COMMAND_TELEM_RATE, BINARY_COMMAND_TELEM_VALUE, BINARY_VALUE_AMPS, BINARY_VALUE_RPM, BINARY_VALUE_VOLTS_BAT, BINARY_VALUE_VOLTS_MOTOR, esc32_private::dev, esc32_priv, esc32_send_command(), ESC32_TELEMETRY_RATE, foo, esc32_private::initialized, and uart_put_byte().
|
static |
Definition at line 98 of file esc32.c.
References ESC32_BUF_OUT_LEN, esc32_compute_ck(), and foo.
Referenced by esc32_put_float(), esc32_put_short(), and esc32_send_command().
|
static |
Definition at line 113 of file esc32.c.
References esc32_put_char(), f, and foo.
Referenced by esc32_send_command().
|
static |
Definition at line 105 of file esc32.c.
References esc32_put_char(), and foo.
Referenced by esc32_send_command().
|
static |
Definition at line 71 of file esc32.c.
References foo, and uart_put_byte().
Referenced by esc32_send_command().
|
static |
Definition at line 121 of file esc32.c.
References ESC32_BUF_OUT_LEN, esc32_init_ck(), esc32_put_char(), esc32_put_float(), esc32_put_short(), esc32_send(), and foo.
Referenced by esc32_periodic().
|
static |
Definition at line 153 of file esc32.c.
References CHECK_CK_A, CHECK_CK_B, ESC32_BUF_IN_LEN, esc32_compute_ck(), esc32_init_ck(), foo, GET_CMD_COLS, GET_CMD_ROWS, GET_COMMAND, GOT_SYNC, SEARCH_COMMAND, and UINIT.
Referenced by esc32_event().
|
static |
Definition at line 68 of file esc32.c.
Referenced by esc32_event(), esc32_init(), and esc32_periodic().