|
dRonin
adbada4
dRonin firmware
|
Files | |
| file | common.h |
| Common definitions across the bootloaders. | |
| file | main.c |
| Start PiOS and bootloader functions. | |
| file | op_dfu.c |
| This file contains the DFU commands handling code. | |
| file | op_dfu.h |
| This file contains the DFU commands handling code. | |
Data Structures | |
| struct | Device |
Macros | |
| #define | USB 0 |
| #define | SPI 1 |
| #define | DownloadDelay 100000 |
| #define | MAX_DEL_RETRYS 3 |
| #define | MAX_WRI_RETRYS 3 |
| #define | BSL_HOLD_STATE ((PIOS_USB_DETECT_GPIO_PORT->IDR & PIOS_USB_DETECT_GPIO_PIN) ? 0 : 1) |
| #define | COMMAND 0 |
| #define | COUNT 1 |
| #define | DATA 5 |
Typedefs | |
| typedef void(* | pFunction )(void) |
Enumerations | |
| enum | DownloadAction { start, keepgoing } |
| enum | DFUStates { DFUidle, uploading, wrong_packet_received, too_many_packets, too_few_packets, Last_operation_Success, downloading, BLidle, Last_operation_failed, uploadingStarting, outsideDevCapabilities, CRC_Fail, failed_jump } |
| enum | DFUCommands { Reserved, Req_Capabilities, Rep_Capabilities, EnterDFU, JumpFW, Reset, Abort_Operation, Upload, Op_END, Download_Req, Download, Status_Request, Status_Rep } |
| enum | DeviceType { High_Density, Medium_Density } |
| enum | DFUTransfer { FW, Descript } |
| enum | DFUPort { Usb, Serial } |
| enum | DFUProgType { Self_flash, Remote_flash_via_spi } |
Functions | |
| void | PIOS_Board_Init (void) |
| void | FLASH_Download () |
| uint32_t | LedPWM (uint32_t pwm_period, uint32_t pwm_sweep_steps, uint32_t count) |
| uint8_t | processRX () |
| void | jump_to_app () |
| int | main () |
| void | sendData (uint8_t *buf, uint16_t size) |
| uint32_t | CalcFirmCRC (void) |
| void | DataDownload (DownloadAction action) |
| void | processComand (uint8_t *xReceive_Buffer) |
| void | OPDfuIni (uint8_t discover) |
| uint32_t | baseOfAdressType (DFUTransfer type) |
| uint8_t | isBiggerThanAvailable (DFUTransfer type, uint32_t size) |
| bool | flash_read (uint8_t *buffer, uint32_t adr, DFUProgType type) |
| uint32_t | baseOfAdressType (uint8_t type) |
| uint8_t | isBiggerThanAvailable (uint8_t type, uint32_t size) |
| #define BSL_HOLD_STATE ((PIOS_USB_DETECT_GPIO_PORT->IDR & PIOS_USB_DETECT_GPIO_PIN) ? 0 : 1) |
| enum DeviceType |
| enum DFUCommands |
| enum DFUProgType |
| enum DFUStates |
| enum DFUTransfer |
| enum DownloadAction |
| uint32_t baseOfAdressType | ( | uint8_t | type | ) |
| uint32_t baseOfAdressType | ( | DFUTransfer | type | ) |
| void DataDownload | ( | DownloadAction | action | ) |
| void FLASH_Download | ( | ) |
| bool flash_read | ( | uint8_t * | buffer, |
| uint32_t | adr, | ||
| DFUProgType | type | ||
| ) |
| uint8_t isBiggerThanAvailable | ( | uint8_t | type, |
| uint32_t | size | ||
| ) |
| uint8_t isBiggerThanAvailable | ( | DFUTransfer | type, |
| uint32_t | size | ||
| ) |
| uint32_t LedPWM | ( | uint32_t | pwm_period, |
| uint32_t | pwm_sweep_steps, | ||
| uint32_t | count | ||
| ) |
| int main | ( | void | ) |
dRonin Main function:
Initialize PiOS
Create the "System" task (SystemModInitializein Modules/System/systemmod.c)
Start the RTOS Scheduler
CortexM3 CPU vectors
CortexM3 CPU vectors
| void PIOS_Board_Init | ( | ) |
PIOS_Board_Init() initializes all the core subsystems on this specific hardware called from System/openpilot.c
Initialise PWM Output for black/white level setting PIOS_Board_Init() initializes all the core subsystems on this specific hardware called from System/openpilot.c
PIOS_Board_Init() initializes all the core subsystems on this specific hardware
PIOS_Board_Init() initializes all the core systems on this specific hardware called from System/openpilot.c
Definition at line 44 of file pios_board.c.
| DFUProgType currentProgrammingDestination |
| DFUTransfer downType = 0 |