38 #include "board_hw_defs.c"
50 for (
int i = 0;
i < num_channels;
i++) {
51 GPIO_InitTypeDef init = {
52 .GPIO_Pin = channels[
i].
pin.
init.GPIO_Pin,
53 .GPIO_Speed = GPIO_Speed_2MHz,
54 .GPIO_Mode = GPIO_Mode_OUT,
55 .GPIO_OType = GPIO_OType_PP,
56 .GPIO_PuPd = GPIO_PuPd_DOWN
64 GPIO_Init(channels[
i].
pin.
gpio, &init);
71 #if defined(PIOS_INCLUDE_ANNUNC)
75 #if defined(PIOS_INCLUDE_FLASH)
83 #if defined(PIOS_INCLUDE_USB)
90 uintptr_t pios_usb_id;
93 #if defined(PIOS_INCLUDE_USB_HID) && defined(PIOS_INCLUDE_COM_MSG)
94 uintptr_t pios_usb_hid_id;
int32_t PIOS_Flash_Internal_Init(uintptr_t *flash_id, const struct pios_flash_internal_cfg *cfg)
Main PiOS header to include all the compiled in PiOS options.
int32_t PIOS_USB_HID_Init(uintptr_t *usbhid_id, const struct pios_usb_hid_cfg *cfg, uintptr_t lower_id)
const struct pios_tim_channel * channels
int32_t PIOS_DELAY_Init(void)
const struct pios_com_driver pios_usb_hid_com_driver
int32_t PIOS_ANNUNC_Init(const struct pios_annunc_cfg *cfg)
int32_t PIOS_USB_DESC_HID_ONLY_Init(void)
const struct pios_servo_cfg pios_servo_cfg
Sparky2 has all 10 outputs.
uintptr_t pios_com_telem_usb_id
int32_t PIOS_COM_MSG_Init(uintptr_t *com_id, const struct pios_com_driver *driver, uintptr_t lower_id)
void PIOS_FLASH_register_partition_table(const struct pios_flash_partition partition_table[], uint8_t num_partitions)
int32_t PIOS_USB_Init(uintptr_t *usb_id, const struct pios_usb_cfg *cfg)
const struct pios_flash_partition pios_flash_partition_table[]
#define PIOS_Assert(test)
int32_t PIOS_USB_BOARD_DATA_Init(void)
static const struct pios_servo_cfg * servo_cfg