dRonin  adbada4
dRonin firmware
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
pios_board.c
Go to the documentation of this file.
1 
15 /*
16  * This program is free software; you can redistribute it and/or modify
17  * it under the terms of the GNU General Public License as published by
18  * the Free Software Foundation; either version 3 of the License, or
19  * (at your option) any later version.
20  *
21  * This program is distributed in the hope that it will be useful, but
22  * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
23  * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
24  * for more details.
25  *
26  * You should have received a copy of the GNU General Public License along
27  * with this program; if not, see <http://www.gnu.org/licenses/>
28  *
29  * Additional note on redistribution: The copyright and license notices above
30  * must be maintained in each individual source file that is a derivative work
31  * of this source file; otherwise redistribution is prohibited.
32  */
33 
34 /* Pull in the board-specific static HW definitions.
35  * Including .c files is a bit ugly but this allows all of
36  * the HW definitions to be const and static to limit their
37  * scope.
38  *
39  * NOTE: THIS IS THE ONLY PLACE THAT SHOULD EVER INCLUDE THIS FILE
40  */
41 
42 #include "board_hw_defs.c"
43 
44 #include <pios.h>
45 #include <pios_hal.h>
46 #include <openpilot.h>
47 #include <misc_math.h>
48 #include <uavobjectsinit.h>
49 #include "pios_flash_jedec_priv.h"
50 
51 #include "hwbrainre1.h"
52 #include "flightbatterysettings.h"
53 #include "flightstatus.h"
54 #include "modulesettings.h"
55 #include "manualcontrolsettings.h"
56 #include "onscreendisplaysettings.h"
57 #include "rgbledsettings.h"
58 
59 #include "pios_ir_transponder.h"
60 
65 
67 
72 static void settingsUpdatedCb(const UAVObjEvent *ev,
73  void *ctx, void *obj, int len)
74 {
75  (void) ev; (void) ctx; (void) len;
76 
77  HwBrainRE1Data * hwre1data = (HwBrainRE1Data *)obj;
78 
79  /* Configure the IR emitter for lap timing */
80  uint8_t ir_data[6];
81 
82  switch (hwre1data->IRProtocol) {
83  case HWBRAINRE1_IRPROTOCOL_DISABLED:
85  break;
86  case HWBRAINRE1_IRPROTOCOL_ILAP:
87  pios_ir_generate_ilap_packet(hwre1data->IRIDILap, ir_data, 6);
88  PIOS_RE1FPGA_SetIRData(ir_data, 6);
90  break;
91  case HWBRAINRE1_IRPROTOCOL_TRACKMATE:
92  pios_ir_generate_trackmate_packet(hwre1data->IRIDTrackmate, ir_data, 4);
93  PIOS_RE1FPGA_SetIRData(ir_data, 4);
95  break;
96  }
97 
98  /* Configure the buzzer type */
99  if (hwre1data->BuzzerType == HWBRAINRE1_BUZZERTYPE_4KHZ_BUZZER) {
101  }
102  else if (hwre1data->BuzzerType == HWBRAINRE1_BUZZERTYPE_DC_BUZZER) {
104  }
105 
106  /* Set video sync detector threshold */
107  PIOS_RE1FPGA_SetSyncThreshold(hwre1data->VideoSyncDetectorThreshold);
108 }
109 
110 #include <pios_board_info.h>
111 
117 void PIOS_Board_Init(void) {
118 #if defined(PIOS_INCLUDE_ANNUNC)
120 #endif /* PIOS_INCLUDE_ANNUNC */
121 
122 #if defined(PIOS_INCLUDE_SPI)
123  pios_spi_t pios_spi_gyro_id;
124 
125  if (PIOS_SPI_Init(&pios_spi_gyro_id, &pios_spi_gyro_cfg)) {
127  }
128  if (PIOS_SPI_Init(&pios_spi_flash_id, &pios_spi_flash_cfg)) {
130  }
131 #endif
132 
133 #if defined(PIOS_INCLUDE_RE1_FPGA)
134  if (PIOS_RE1FPGA_Init(pios_spi_flash_id, 1, &pios_re1fpga_cfg, false) != 0) {
135  PIOS_HAL_CriticalError(PIOS_LED_ALARM, PIOS_HAL_PANIC_CAN); // XXX need to add custom code
136  }
137 #endif /* defined(PIOS_INCLUDE_RE1_FPGA) */
138 
139 #if defined(PIOS_INCLUDE_FLASH)
140  /* Inititialize all flash drivers */
141  if (PIOS_Flash_Internal_Init(&pios_internal_flash_id, &flash_internal_cfg) != 0)
143  if (PIOS_Flash_Jedec_Init(&pios_external_flash_id, pios_spi_flash_id, 0, &flash_s25fl127_cfg) != 0)
145 
146  /* Register the partition table */
148 
149  /* Mount all filesystems */
152 
153 #if defined(ERASE_FLASH)
155 #endif
156 
157 #endif /* PIOS_INCLUDE_FLASH */
158 
159  HwBrainRE1Initialize();
160 
161  /* Connect callback to update FPGA settings when UAVO changes */
162  HwBrainRE1ConnectCallback(settingsUpdatedCb);
163 
164  /* Set the HW revision, this also invokes the callback */
165  uint8_t hw_rev = PIOS_RE1FPGA_GetHWRevision();
166  HwBrainRE1HWRevisionSet(&hw_rev);
167 
168  /* Get the flash ID (random number) */
169  uint8_t flashid[16] = {0};
170  PIOS_Flash_Jedec_ReadOTPData(pios_external_flash_id, 0, flashid, 16);
171  HwBrainRE1FlashIDSet(flashid);
172 
173  ModuleSettingsInitialize();
174 
175 #if defined(PIOS_INCLUDE_RTC)
176  /* Initialize the real-time clock and its associated tick */
177  PIOS_RTC_Init(&pios_rtc_main_cfg);
178 #endif
179 
180 #ifndef ERASE_FLASH
181  /* Initialize watchdog as early as possible to catch faults during init
182  * but do it only if there is no debugger connected
183  */
184  if ((CoreDebug->DHCSR & CoreDebug_DHCSR_C_DEBUGEN_Msk) == 0) {
185  PIOS_WDG_Init();
186  }
187 #endif
188 
190 
191  /* Set up pulse timers */
192  //inputs
194  //outputs
198 
199  /* IAP System Setup */
200  PIOS_IAP_Init();
201  uint16_t boot_count = PIOS_IAP_ReadBootCount();
202  if (boot_count < 3) {
203  PIOS_IAP_WriteBootCount(++boot_count);
204  AlarmsClear(SYSTEMALARMS_ALARM_BOOTFAULT);
205  } else {
206  /* Too many failed boot attempts, force hw config to defaults */
207  HwBrainRE1SetDefaults(HwBrainRE1Handle(), 0);
208  ModuleSettingsSetDefaults(ModuleSettingsHandle(),0);
209  AlarmsSet(SYSTEMALARMS_ALARM_BOOTFAULT, SYSTEMALARMS_ALARM_CRITICAL);
210  }
211 
212 #if defined(PIOS_INCLUDE_USB)
213  /* Initialize board specific USB data */
215 
216  /* Flags to determine if various USB interfaces are advertised */
217  bool usb_hid_present = false;
218  bool usb_cdc_present = false;
219 
220 #if defined(PIOS_INCLUDE_USB_CDC)
222  PIOS_Assert(0);
223  }
224  usb_hid_present = true;
225  usb_cdc_present = true;
226 #else
228  PIOS_Assert(0);
229  }
230  usb_hid_present = true;
231 #endif
232 
233  uintptr_t pios_usb_id;
234  PIOS_USB_Init(&pios_usb_id, &pios_usb_main_cfg);
235 
236 #if defined(PIOS_INCLUDE_USB_CDC)
237 
238  uint8_t hw_usb_vcpport;
239  /* Configure the USB VCP port */
240  HwBrainRE1USB_VCPPortGet(&hw_usb_vcpport);
241 
242  if (!usb_cdc_present) {
243  /* Force VCP port function to disabled if we haven't advertised VCP in our USB descriptor */
244  hw_usb_vcpport = HWBRAINRE1_USB_VCPPORT_DISABLED;
245  }
246 
247  PIOS_HAL_ConfigureCDC(hw_usb_vcpport, pios_usb_id, &pios_usb_cdc_cfg);
248 #endif /* PIOS_INCLUDE_USB_CDC */
249 
250 #if defined(PIOS_INCLUDE_USB_HID)
251  /* Configure the usb HID port */
252  uint8_t hw_usb_hidport;
253  HwBrainRE1USB_HIDPortGet(&hw_usb_hidport);
254 
255  if (!usb_hid_present) {
256  /* Force HID port function to disabled if we haven't advertised HID in our USB descriptor */
257  hw_usb_hidport = HWBRAINRE1_USB_HIDPORT_DISABLED;
258  }
259 
260  PIOS_HAL_ConfigureHID(hw_usb_hidport, pios_usb_id, &pios_usb_hid_cfg);
261 #endif /* PIOS_INCLUDE_USB_HID */
262 
263  if (usb_hid_present || usb_cdc_present) {
265  }
266 #endif /* PIOS_INCLUDE_USB */
267 
268  /* Configure the RxPort*/
269 
270  /* Configure IO ports */
271  HwBrainRE1DSMxModeOptions hw_DSMxMode;
272  HwBrainRE1DSMxModeGet(&hw_DSMxMode);
273 
274  uint8_t hw_rxport;
275  HwBrainRE1RxPortGet(&hw_rxport);
276 
277  PIOS_HAL_ConfigurePort(hw_rxport, // port type protocol
278  &pios_usart3_cfg, // usart_port_cfg
279  &pios_usart_com_driver, // com_driver
280  NULL, // i2c_id
281  NULL, // i2c_cfg
282  &pios_ppm_cfg, // ppm_cfg
283  NULL, // pwm_cfg
284  PIOS_LED_ALARM, // led_id
285  &pios_rxport_dsm_cfg, // dsm_cfg
286  hw_DSMxMode, // dsm_mode
287  NULL);
288 
289  if (hw_rxport == HWSHARED_PORTTYPES_SBUS) {
291  }
292 
293  /* SerialPort1 */
294  uint8_t hw_sp;
295  HwBrainRE1SerialPortGet(&hw_sp);
296 
297  PIOS_HAL_ConfigurePort(hw_sp, // port type protocol
298  &pios_usart1_cfg, // usart_port_cfg
299  &pios_usart_com_driver, // com_driver
300  NULL, // i2c_id
301  NULL, // i2c_cfg
302  NULL, // ppm_cfg
303  NULL, // pwm_cfg
304  PIOS_LED_ALARM, // led_id
305  NULL, // dsm_cfg
306  0, // dsm_mode
307  NULL); // sbus_rcvr_cfg
308 
309  /* Multi-function port (pwm, serial, etc) */
310  uint8_t hw_mp_mode;
311  HwBrainRE1MultiPortModeGet(&hw_mp_mode);
312  uint8_t hw_mp_serial;
313  HwBrainRE1MultiPortSerialGet(&hw_mp_serial);
314 
315  /* Configure PWM Outputs */
316 #if defined(PIOS_INCLUDE_SERVO) && defined(PIOS_INCLUDE_TIM)
317 
318 #if defined(PIOS_INCLUDE_DMASHOT)
319  PIOS_DMAShot_Init(&dmashot_config);
320 #endif // defined(PIOS_INCLUDE_DMASHOT)
321 
322  switch (hw_mp_mode) {
323  case HWBRAINRE1_MULTIPORTMODE_NORMAL:
324  if (hw_mp_serial == HWBRAINRE1_MULTIPORTSERIAL_PWM) {
325  // all 8 PWM outputs are used
327  }
328  else {
329  // only 6 PWM outputs are used
330  PIOS_Servo_Init(&pios_servo_6_cfg);
331  }
332  break;
333  case HWBRAINRE1_MULTIPORTMODE_DUALSERIAL4PWM:
334  // only 4 PWM outputs
335  PIOS_Servo_Init(&pios_servo_4_cfg);
336  break;
337  }
338 #endif /* defined(PIOS_INCLUDE_SERVO) && defined(PIOS_INCLUDE_TIM) */
339 
340  /* MultiPort Serial 1 */
341  switch (hw_mp_serial) {
342  case HWBRAINRE1_MULTIPORTSERIAL_PWM:
343  // for us, this means PWM output, not input
344  break;
345  default:
346  PIOS_HAL_ConfigurePort(hw_mp_serial, // port type protocol
347  &pios_usart6_cfg, // usart_port_cfg
348  &pios_usart_com_driver, // com_driver
349  NULL, // i2c_id
350  NULL, // i2c_cfg
351  NULL, // ppm_cfg
352  NULL, // pwm_cfg
353  PIOS_LED_ALARM, // led_id
354  NULL, // dsm_cfg
355  0, // dsm_mode
356  NULL); // sbus_rcvr_cfg
357  break;
358  }
359 
360  // Enable / disable RE1 specific hardware inverters
361  switch (hw_mp_serial) {
362  case HWBRAINRE1_MULTIPORTSERIAL_FRSKYSENSORHUB:
363  PIOS_RE1FPGA_MPTxPinMode(false, true);
364  break;
365  case HWBRAINRE1_MULTIPORTSERIAL_FRSKYSPORTTELEMETRY:
366  PIOS_RE1FPGA_MPTxPinMode(true, true);
367  PIOS_RE1FPGA_MPTxPinPullUpDown(true, false);
368  break;
369  }
370 
371  /* MultiPort Serial 2 */
372  if (hw_mp_mode == HWBRAINRE1_MULTIPORTMODE_DUALSERIAL4PWM) {
373  HwBrainRE1MultiPortSerial2Get(&hw_mp_serial);
374 
375  PIOS_HAL_ConfigurePort(hw_mp_serial, // port type protocol
376  &pios_usart4_cfg, // usart_port_cfg
377  &pios_usart_com_driver, // com_driver
378  NULL, // i2c_id
379  NULL, // i2c_cfg
380  NULL, // ppm_cfg
381  NULL, // pwm_cfg
382  PIOS_LED_ALARM, // led_id
383  NULL, // dsm_cfg
384  0, // dsm_mode
385  NULL); // sbus_rcvr_cfg
386  }
387 
388  PIOS_WDG_Clear();
389  PIOS_DELAY_WaitmS(50);
390 
392 
393  // RGB LEDs (uses RE1 FPGA)
394  uint8_t num_leds;
395  RGBLEDSettingsInitialize();
396  RGBLEDSettingsNumLedsGet(&num_leds);
397  if (num_leds > 0) {
398  PIOS_WS2811_init(&pios_ws2811, NULL, num_leds);
399  }
400 
401 #if defined(PIOS_INCLUDE_ADC)
402  uintptr_t internal_adc_id;
403  PIOS_INTERNAL_ADC_Init(&internal_adc_id, &pios_adc_cfg);
405 #endif /* defined(PIOS_INCLUDE_ADC) */
406 
407 #if defined(PIOS_INCLUDE_SPI)
408 #if defined(PIOS_INCLUDE_BMI160)
409  uint8_t bmi160_foc;
410  HwBrainRE1BMI160FOCGet(&bmi160_foc);
411 
412  bool do_foc = (bmi160_foc == HWBRAINRE1_BMI160FOC_DO_FOC);
413 
414  if(PIOS_BMI160_Init(pios_spi_gyro_id, 0, &pios_bmi160_cfg, do_foc) != 0){
416  }
417 
418  /* Disable FOC. We only do this once. */
419  if (do_foc) {
420  bmi160_foc = HWBRAINRE1_BMI160FOC_DISABLED;
421  HwBrainRE1BMI160FOCSet(&bmi160_foc);
422  UAVObjSave(HwBrainRE1Handle(), 0);
423  }
424 #endif /* PIOS_INCLUDE_BMI160 */
425 #endif /* PIOS_INCLUDE_SPI */
426 
427  uint8_t hw_ext_mag;
428  uint8_t hw_orientation;
429 
430  HwBrainRE1I2CExtMagGet(&hw_ext_mag);
431  HwBrainRE1ExtMagOrientationGet(&hw_orientation);
432 
433  PIOS_HAL_ConfigureExternalMag(hw_ext_mag, hw_orientation,
434  &pios_i2c_external_id, &pios_i2c_external_cfg);
435 
436  uint8_t hw_ext_baro;
437 
438  HwBrainRE1I2CExtBaroGet(&hw_ext_baro);
439 
440  PIOS_HAL_ConfigureExternalBaro(hw_ext_baro,
441  &pios_i2c_external_id, &pios_i2c_external_cfg);
442 
443  /* Set voltage/current calibration values, if the current settings are UAVO defaults.*/
444  FlightBatterySettingsInitialize();
445  FlightBatterySettingsData batterysettings;
446  FlightBatterySettingsGet(&batterysettings);
447  if(batterysettings.SensorCalibrationFactor[FLIGHTBATTERYSETTINGS_SENSORCALIBRATIONFACTOR_CURRENT] == 36.6f) {
448  batterysettings.SensorCalibrationFactor[FLIGHTBATTERYSETTINGS_SENSORCALIBRATIONFACTOR_CURRENT] = 25.0f;
449  }
450 
451  if(batterysettings.SensorCalibrationFactor[FLIGHTBATTERYSETTINGS_SENSORCALIBRATIONFACTOR_VOLTAGE] == 63.69f) {
452  batterysettings.SensorCalibrationFactor[FLIGHTBATTERYSETTINGS_SENSORCALIBRATIONFACTOR_VOLTAGE] = 152.0f;
453  }
454  FlightBatterySettingsSet(&batterysettings);
455 }
456 
int32_t PIOS_RE1FPGA_Init(pios_spi_t spi_id, uint32_t slave_num, const struct pios_re1fpga_cfg *cfg, bool load_config)
int32_t PIOS_Flash_Internal_Init(uintptr_t *flash_id, const struct pios_flash_internal_cfg *cfg)
int32_t PIOS_USB_DESC_HID_CDC_Init(void)
Generate packets for various infrared lap timin protocols.
void PIOS_HAL_ConfigureCDC(HwSharedUSB_VCPPortOptions port_type, uintptr_t usb_id, const struct pios_usb_cdc_cfg *cdc_cfg)
int32_t PIOS_BMI160_Init(pios_spi_t spi_id, uint32_t slave_num, const struct pios_bmi160_cfg *cfg, bool do_foc)
int32_t PIOS_RE1FPGA_SetBuzzerType(enum pios_re1fpga_buzzer_types type)
Main PiOS header to include all the compiled in PiOS options.
int32_t PIOS_INTERNAL_ADC_Init(uintptr_t *internal_adc_id, const struct pios_internal_adc_cfg *cfg)
int PIOS_HAL_ConfigureExternalBaro(HwSharedExtBaroOptions baro, pios_i2c_t *i2c_id, const struct pios_i2c_adapter_cfg *i2c_cfg)
Definition: pios_hal.c:1242
void pios_ir_generate_trackmate_packet(uint16_t trackmate_id, uint8_t *data, uint8_t data_len)
#define NELEMENTS(x)
Definition: pios.h:192
static void settingsUpdatedCb(const UAVObjEvent *ev, void *ctx, void *obj, int len)
Definition: pios_board.c:72
int32_t PIOS_Flash_Jedec_Init(uintptr_t *flash_id, pios_spi_t spi_id, uint32_t slave_num, const struct pios_flash_jedec_cfg *cfg)
#define PIOS_DEBUG_Assert(test)
Definition: pios_debug.h:51
const struct pios_servo_cfg pios_servo_8_cfg
Brushed Sparky skips last two output ports.
int PIOS_HAL_ConfigureExternalMag(HwSharedMagOptions mag, HwSharedMagOrientationOptions orientation, pios_i2c_t *i2c_id, const struct pios_i2c_adapter_cfg *i2c_cfg)
Definition: pios_hal.c:1298
int32_t UAVObjSave(UAVObjHandle obj_handle, uint16_t instId)
int32_t AlarmsSet(SystemAlarmsAlarmElem alarm, SystemAlarmsAlarmOptions severity)
Definition: alarms.c:97
uintptr_t pios_uavo_settings_fs_id
Definition: pios_board.c:50
uint16_t PIOS_IAP_ReadBootCount(void)
Definition: pios_iap.c:93
int32_t PIOS_FLASHFS_Logfs_Init(uintptr_t *fs_id, const struct flashfs_logfs_cfg *cfg, enum pios_flash_partition_labels partition_label)
Initialize the flash object setting FS.
static const struct pios_tim_clock_cfg tim_8_cfg
int PIOS_WS2811_init(ws2811_dev_t *dev_out, const struct pios_ws2811_cfg *cfg, int max_leds)
Allocate and initialise WS2811 device.
Definition: pios_ws2811.c:64
#define PIOS_LED_ALARM
Definition: pios_board.h:86
int32_t PIOS_Flash_Jedec_ReadOTPData(uintptr_t chip_id, uint32_t chip_offset, uint8_t *data, uint16_t len)
void PIOS_WDG_Clear(void)
Clear the watchdog timer.
Definition: pios_wdg.c:147
int32_t PIOS_RE1FPGA_MPTxPinMode(bool bidrectional, bool invert)
const struct pios_com_driver pios_usart_com_driver
Driver for talking to most JEDEC flash chips.
static const struct pios_tim_clock_cfg tim_5_cfg
void PIOS_IAP_Init(void)
PIOS_IAP_Init - performs required initializations for iap module.
Definition: pios_iap.c:44
const struct pios_adc_driver pios_internal_adc_driver
int32_t PIOS_RE1FPGA_SetSyncThreshold(uint8_t threshold)
int32_t PIOS_TIM_InitClock(const struct pios_tim_clock_cfg *cfg)
Definition: pios_tim.c:62
uintptr_t pios_internal_adc_id
Definition: pios_board.c:51
ws2811_dev_t pios_ws2811
Definition: pios_board.c:66
int32_t PIOS_SPI_Init(pios_spi_t *spi_dev, const struct pios_spi_cfg *cfg)
void PIOS_Board_Init()
Definition: pios_board.c:44
int32_t PIOS_ANNUNC_Init(const struct pios_annunc_cfg *cfg)
uint8_t PIOS_RE1FPGA_GetHWRevision()
static const struct pios_tim_clock_cfg tim_1_cfg
void pios_ir_generate_ilap_packet(uint32_t ilap_id, uint8_t *data, uint8_t data_len)
int32_t PIOS_SENSORS_Init()
Initialize the PIOS_SENSORS interface.
Definition: pios_sensors.c:51
void PIOS_RTC_Init(const struct pios_rtc_cfg *cfg)
int32_t PIOS_USB_DESC_HID_ONLY_Init(void)
void PIOS_HAL_ConfigureHID(HwSharedUSB_HIDPortOptions port_type, uintptr_t usb_id, const struct pios_usb_hid_cfg *hid_cfg)
int32_t PIOS_Servo_Init(const struct pios_servo_cfg *cfg)
Definition: pios_servo.c:109
int32_t PIOS_RE1FPGA_SetIRProtocol(enum pios_re1fpga_ir_protocols ir_protocol)
uintptr_t pios_com_openlog_logging_id
Definition: pios_board.c:49
int32_t PIOS_RE1FPGA_MPTxPinPullUpDown(bool enable, bool pullup)
uintptr_t pios_com_logging_id
Definition: pios_board.c:50
static const struct pios_tim_clock_cfg tim_12_cfg
void PIOS_USBHOOK_Activate(void)
Definition: pios_usbhook.c:80
void PIOS_FLASH_register_partition_table(const struct pios_flash_partition partition_table[], uint8_t num_partitions)
Includes PiOS and core architecture components.
int32_t AlarmsClear(SystemAlarmsAlarmElem alarm)
Definition: alarms.c:171
int32_t PIOS_USB_Init(uintptr_t *usb_id, const struct pios_usb_cfg *cfg)
uint16_t PIOS_WDG_Init()
Initialize the watchdog timer for a specified timeout.
Definition: pios_wdg.c:63
int32_t PIOS_ADC_Init(uintptr_t *adc_id, const struct pios_adc_driver *driver, uintptr_t lower_id)
const struct pios_flash_partition pios_flash_partition_table[]
Definition: unittest_init.c:50
void PIOS_IAP_WriteBootCount(uint16_t)
Definition: pios_iap.c:98
int32_t PIOS_RE1FPGA_SerialRxInvert(bool invert)
void PIOS_HAL_CriticalError(uint32_t led_id, enum pios_hal_panic code)
Flash a blink code.
Definition: pios_hal.c:291
int32_t PIOS_FLASHFS_Format(uintptr_t fs_id)
Erases all filesystem arenas and activate the first arena.
void PIOS_DMAShot_Init(const struct pios_dmashot_cfg *config)
Initializes the DMAShot driver by loading the configuration.
Definition: pios_dmashot.c:96
int32_t PIOS_RE1FPGA_SetIRData(const uint8_t *ir_data, uint8_t n_bytes)
#define PIOS_Assert(test)
Definition: pios_debug.h:52
int32_t PIOS_DELAY_WaitmS(uint32_t mS)
Definition: pios_delay.c:140
int32_t PIOS_USB_BOARD_DATA_Init(void)
void PIOS_RESET_Clear(void)
PIOS_RESET_Clear Does nothing on POSIX systems.
Definition: pios_reset.c:38