ardupilot/libraries/AP_HAL_ChibiOS/hwdef/Airvolute-DCS2/hwdef.dat

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

175 lines
4.0 KiB
Plaintext
Raw Normal View History

# hw definition file for processing by chibios_hwdef.py
#following exapmle:
#https://github.com/ArduPilot/ardupilot/blob/master/libraries/AP_HAL_ChibiOS/hwdef/mRoControlZeroH7/hwdef.dat#L105
# for H743 bootloader
# MCU class and specific type
MCU STM32H7xx STM32H743xx
# crystal frequency
OSCILLATOR_HZ 16000000
# board ID for firmware load
APJ_BOARD_ID 5200
# the nucleo seems to have trouble with flashing the last sector?
FLASH_SIZE_KB 2048
# This is the STM32 timer that ChibiOS will use for the low level
# driver. This must be a 32 bit timer. We currently only support
# timers 2, 3, 4, 5 and 21. See hal_st_lld.c in ChibiOS for details.
# ChibiOS system timer
STM32_ST_USE_TIMER 5
#optimize for space
env OPTIMIZE -Os
FLASH_RESERVE_START_KB 128
define HAL_STORAGE_SIZE 32768
# use last 2 pages for flash storage
# H743 has 16 pages of 128k each
STORAGE_FLASH_PAGE 14
# (---FUTURE REVISION---): PA0 AS VDD_SENSE_PIN
PA0 VDD_5V_SENS ADC1 SCALE(2)
# order of I2C buses
I2C_ORDER I2C1
# I2C1 (SE_CONNECTOR)
PB8 I2C1_SCL I2C1 PULLUP
PB7 I2C1_SDA I2C1 PULLUP
# USB setup
USB_STRING_MANUFACTURER "Airvolute"
# This is the pin that senses USB being connected. It is an input pin
# setup as OPENDRAIN.
PA9 VBUS INPUT OPENDRAIN
# order of UARTs (and USB)
SERIAL_ORDER OTG1 USART1 USART2 USART3
PA11 OTG_FS_DM OTG1
PA12 OTG_FS_DP OTG1
PA13 JTMS-SWDIO SWD
PA14 JTCK-SWCLK SWD
# (---FUTURE REVISION---): PWM output for buzzer
PB15 TIM12_CH2 TIM12 GPIO(80) ALARM
# (---FUTURE REVISION---): RC Input set for Interrupt not DMA
PA6 TIM3_CH1 TIM3 RCININT PULLDOWN LOW
# UART SETUP
# USART1 (SE_CONNECTOR)
PB14 USART1_TX USART1
PA10 USART1_RX USART1
# USART2 (SE_CONNECTOR)
PD5 USART2_TX USART2
PD6 USART2_RX USART2
# USART3 (RC INPUT)
PD9 USART3_RX USART3
#LED RED
PB1 LED1 OUTPUT HIGH
#LED GREEN
PA3 FMU_LED_AMBER OUTPUT LOW GPIO(0)
# microSD card
PC8 SDMMC1_D0 SDMMC1
PC9 SDMMC1_D1 SDMMC1
PC10 SDMMC1_D2 SDMMC1
PC11 SDMMC1_D3 SDMMC1
PC12 SDMMC1_CK SDMMC1
PD2 SDMMC1_CMD SDMMC1
# CS pins for SPI sensors. The labels for all CS pins need to
# match the SPI device table later in this file.
PD12 BMI088_ACC_CS CS
PE13 BMI088_GYRO_CS CS
PD13 BMP390_CS CS
PD15 EXT_0_CS CS
PD14 EXT_1_CS CS
PD11 EXT_2_CS CS
PD10 EXT_3_CS CS
# CAN Busses
PD0 CAN1_RX CAN1
PB9 CAN1_TX CAN1
# CAN1 Silent Pin LOW Enable
PC7 GPIO_CAN1_SILENT OUTPUT PUSHPULL SPEED_LOW LOW GPIO(70)
PB5 CAN2_RX CAN2
PB6 CAN2_TX CAN2
# CAN2 Silent Pin LOW Enable
PC6 GPIO_CAN2_SILENT OUTPUT PUSHPULL SPEED_LOW LOW GPIO(71)
# Ethernet
PC1 ETH_MDC ETH1
PA2 ETH_MDIO ETH1
PC4 ETH_RMII_RXD0 ETH1
PC5 ETH_RMII_RXD1 ETH1
PB12 ETH_RMII_TXD0 ETH1
PB13 ETH_RMII_TXD1 ETH1
PB11 ETH_RMII_TX_EN ETH1
PA7 ETH_RMII_CRS_DV ETH1
PA1 ETH_RMII_REF_CLK ETH1
define BOARD_PHY_RMII
define BOARD_PHY_ADDRESS 0x0000
define STM32_MAC_PHY_LINK_TYPE MAC_LINK_100_FULLDUPLEX
define HAL_PERIPH_ENABLE_NETWORKING
#PWM outputs
PB3 TIM2_CH2 TIM2 PWM(1) GPIO(50) BIDIR
PB10 TIM2_CH3 TIM2 PWM(2) GPIO(51)
PE11 TIM1_CH2 TIM1 PWM(3) GPIO(52) BIDIR
PE14 TIM1_CH4 TIM1 PWM(4) GPIO(53)
# BMI088_DRDY
PE12 BMI088_DRDY INPUT
# (---FUTURE REVISION---) EXT IMU DRDY
PD1 EXT_IMU_DRDY INPUT
# SPI1 (ONBOARD SENSORS)
PA5 SPI1_SCK SPI1
PB4 SPI1_MISO SPI1
PD7 SPI1_MOSI SPI1
# SPI4 (EXTERNAL SENSORS)
PE2 SPI4_SCK SPI4
PE5 SPI4_MISO SPI4
PE6 SPI4_MOSI SPI4
# SPI devices
SPIDEV bmi088_g SPI1 DEVID1 BMI088_GYRO_CS MODE3 10*MHZ 10*MHZ
SPIDEV bmi088_a SPI1 DEVID2 BMI088_ACC_CS MODE3 10*MHZ 10*MHZ
SPIDEV bmp390 SPI1 DEVID3 BMP390_CS MODE3 5*MHZ 5*MHZ
SPIDEV icm42688_ext SPI4 DEVID4 EXT_0_CS MODE3 5*MHZ 5*MHZ
SPIDEV lis3mdl SPI4 DEVID5 EXT_1_CS MODE3 5*MHZ 5*MHZ
# Enable FAT filesystem support (needs a microSD defined via SDMMC).
define HAL_OS_FATFS_IO 1
# IMUs
IMU BMI088 SPI:bmi088_a SPI:bmi088_g ROTATION_NONE
IMU Invensense SPI:icm42688_ext ROTATION_NONE
# 1 baro
define HAL_BARO_ALLOW_INIT_NO_BARO 1
BARO BMP388 SPI:bmp390
define ALLOW_ARM_NO_COMPASS
define HAL_PROBE_EXTERNAL_I2C_COMPASSES