mirror of
https://github.com/PX4/PX4-Autopilot.git
synced 2026-05-21 13:02:25 +08:00
Complete ASC config
This commit is contained in:
committed by
Lorenz Meier
parent
90b5fcc1ec
commit
e6dcc0a2ed
@@ -49,7 +49,6 @@
|
||||
#endif
|
||||
|
||||
#include "stm32_rcc.h"
|
||||
#include "stm32_sdio.h"
|
||||
#include "stm32.h"
|
||||
|
||||
/************************************************************************************
|
||||
@@ -222,6 +221,9 @@
|
||||
#define GPIO_USART6_TX GPIO_USART6_TX_1
|
||||
#define GPIO_USART6_RX GPIO_USART6_RX_1
|
||||
|
||||
#define GPIO_UART7_TX GPIO_UART7_TX_1
|
||||
#define GPIO_UART7_RX GPIO_UART7_RX_1
|
||||
|
||||
/* USART DMA configuration for USART 1 and 6 */
|
||||
|
||||
#define DMAMAP_USART1_RX DMAMAP_USART1_RX_2
|
||||
@@ -260,15 +262,15 @@
|
||||
* reset the bus to clear stuck slaves. They match the pin configuration,
|
||||
* but are normally-high GPIOs.
|
||||
*/
|
||||
#define GPIO_I2C1_SDA GPIO_I2C1_SDA_2
|
||||
#define GPIO_I2C1_SCL GPIO_I2C1_SCL_2
|
||||
#define GPIO_I2C1_SDA_GPIO (GPIO_OUTPUT|GPIO_OPENDRAIN|GPIO_SPEED_50MHz|GPIO_OUTPUT_SET|GPIO_PORTB|GPIO_PIN9)
|
||||
#define GPIO_I2C1_SCL_GPIO (GPIO_OUTPUT|GPIO_OPENDRAIN|GPIO_SPEED_50MHz|GPIO_OUTPUT_SET|GPIO_PORTB|GPIO_PIN8)
|
||||
// #define GPIO_I2C1_SDA GPIO_I2C1_SDA_2
|
||||
// #define GPIO_I2C1_SCL GPIO_I2C1_SCL_2
|
||||
// #define GPIO_I2C1_SDA_GPIO (GPIO_OUTPUT|GPIO_OPENDRAIN|GPIO_SPEED_50MHz|GPIO_OUTPUT_SET|GPIO_PORTB|GPIO_PIN9)
|
||||
// #define GPIO_I2C1_SCL_GPIO (GPIO_OUTPUT|GPIO_OPENDRAIN|GPIO_SPEED_50MHz|GPIO_OUTPUT_SET|GPIO_PORTB|GPIO_PIN8)
|
||||
|
||||
#define GPIO_I2C2_SDA GPIO_I2C2_SDA_1
|
||||
#define GPIO_I2C2_SCL GPIO_I2C2_SCL_1
|
||||
#define GPIO_I2C2_SDA_GPIO (GPIO_OUTPUT|GPIO_OPENDRAIN|GPIO_SPEED_50MHz|GPIO_OUTPUT_SET|GPIO_PORTB|GPIO_PIN11)
|
||||
#define GPIO_I2C2_SCL_GPIO (GPIO_OUTPUT|GPIO_OPENDRAIN|GPIO_SPEED_50MHz|GPIO_OUTPUT_SET|GPIO_PORTB|GPIO_PIN10)
|
||||
// #define GPIO_I2C2_SDA GPIO_I2C2_SDA_1
|
||||
// #define GPIO_I2C2_SCL GPIO_I2C2_SCL_1
|
||||
// #define GPIO_I2C2_SDA_GPIO (GPIO_OUTPUT|GPIO_OPENDRAIN|GPIO_SPEED_50MHz|GPIO_OUTPUT_SET|GPIO_PORTB|GPIO_PIN11)
|
||||
// #define GPIO_I2C2_SCL_GPIO (GPIO_OUTPUT|GPIO_OPENDRAIN|GPIO_SPEED_50MHz|GPIO_OUTPUT_SET|GPIO_PORTB|GPIO_PIN10)
|
||||
|
||||
#define GPIO_I2C3_SDA GPIO_I2C3_SDA_1
|
||||
#define GPIO_I2C3_SCL GPIO_I2C3_SCL_1
|
||||
@@ -280,20 +282,19 @@
|
||||
*
|
||||
* Peripheral Port Signal Name CONN
|
||||
* SPI2_NSS PB12 SD_SPI2_NSS SD-2 CS
|
||||
* SPI2_SCK PB13 SD_SPI2_SCK SD-5 CLK
|
||||
* SPI2_MISO PB14 SD_SPI2_MISO SD-7 D0
|
||||
* SPI2_MOSI PB15 SD_SPI2_MOSI SD-3 DI
|
||||
* TBD
|
||||
*
|
||||
*/
|
||||
|
||||
#define GPIO_SPI2_NSS (GPIO_SPI2_NSS_1 | GPIO_SPEED_50MHz)
|
||||
#define GPIO_SPI2_SCK (GPIO_SPI2_SCK_2 | GPIO_SPEED_50MHz)
|
||||
#define GPIO_SPI2_MISO (GPIO_SPI2_MISO_1 | GPIO_SPEED_50MHz)
|
||||
#define GPIO_SPI2_MOSI (GPIO_SPI2_MOSI_1 | GPIO_SPEED_50MHz)
|
||||
#define GPIO_SPI3_NSS (GPIO_SPI3_NSS_1 | GPIO_SPEED_50MHz)
|
||||
#define GPIO_SPI3_SCK (GPIO_SPI3_SCK_2 | GPIO_SPEED_50MHz)
|
||||
#define GPIO_SPI3_MISO (GPIO_SPI3_MISO_1 | GPIO_SPEED_50MHz)
|
||||
#define GPIO_SPI3_MOSI (GPIO_SPI3_MOSI_1 | GPIO_SPEED_50MHz)
|
||||
|
||||
/* SPI DMA configuration for SPI2 (microSD) */
|
||||
#define DMACHAN_SPI2_RX DMAMAP_SPI2_RX
|
||||
#define DMACHAN_SPI2_TX DMAMAP_SPI2_TX
|
||||
#define GPIO_SPI4_NSS (GPIO_SPI4_NSS_1 | GPIO_SPEED_50MHz)
|
||||
#define GPIO_SPI4_SCK (GPIO_SPI4_SCK_2 | GPIO_SPEED_50MHz)
|
||||
#define GPIO_SPI4_MISO (GPIO_SPI4_MISO_1 | GPIO_SPEED_50MHz)
|
||||
#define GPIO_SPI4_MOSI (GPIO_SPI4_MOSI_1 | GPIO_SPEED_50MHz)
|
||||
|
||||
/* The following Pin Mapping is just for completeness */
|
||||
/*
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user