Skip to content

Commit bb1bd11

Browse files
committed
SOLOGOODF722 - target
1 parent 9e4bb24 commit bb1bd11

3 files changed

Lines changed: 211 additions & 0 deletions

File tree

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
target_stm32f722xe(SOLOGOODF722)
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
/*
2+
* This file is part of INAV.
3+
*
4+
* INAV is free software: you can redistribute it and/or modify
5+
* it under the terms of the GNU General Public License as published by
6+
* the Free Software Foundation, either version 3 of the License, or
7+
* (at your option) any later version.
8+
*
9+
* INAV is distributed in the hope that it will be useful,
10+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12+
* GNU General Public License for more details.
13+
*
14+
* You should have received a copy of the GNU General Public License
15+
* along with INAV. If not, see <http://www.gnu.org/licenses/>.
16+
*/
17+
18+
#include <stdint.h>
19+
20+
#include "platform.h"
21+
#include "drivers/io.h"
22+
23+
#include "drivers/dma.h"
24+
#include "drivers/timer.h"
25+
#include "drivers/timer_def.h"
26+
27+
timerHardware_t timerHardware[] = {
28+
DEF_TIM(TIM8, CH3, PC8, TIM_USE_OUTPUT_AUTO, 0, 0), // S1
29+
DEF_TIM(TIM8, CH4, PC9, TIM_USE_OUTPUT_AUTO, 0, 0), // S2
30+
DEF_TIM(TIM1, CH1, PA8, TIM_USE_OUTPUT_AUTO, 0, 1), // S3
31+
DEF_TIM(TIM1, CH2, PA9, TIM_USE_OUTPUT_AUTO, 0, 1), // S4
32+
DEF_TIM(TIM3, CH3, PB0, TIM_USE_OUTPUT_AUTO, 0, 0), // S5
33+
DEF_TIM(TIM3, CH4, PB1, TIM_USE_OUTPUT_AUTO, 0, 0), // S6
34+
DEF_TIM(TIM1, CH3, PA10, TIM_USE_OUTPUT_AUTO, 0, 1), // S7
35+
DEF_TIM(TIM3, CH1, PB4, TIM_USE_OUTPUT_AUTO, 0, 0), // S8
36+
37+
DEF_TIM(TIM2, CH2, PB3, TIM_USE_LED, 0, 0), // 2812LED
38+
};
39+
40+
const int timerHardwareCount = sizeof(timerHardware) / sizeof(timerHardware[0]);
Lines changed: 170 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,170 @@
1+
/*
2+
* This file is part of INAV Project.
3+
*
4+
* INAV is free software: you can redistribute it and/or modify
5+
* it under the terms of the GNU General Public License as published by
6+
* the Free Software Foundation, either version 3 of the License, or
7+
* (at your option) any later version.
8+
*
9+
* INAV is distributed in the hope that it will be useful,
10+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12+
* GNU General Public License for more details.
13+
*
14+
* You should have received a copy of the GNU General Public License
15+
* along with INAV. If not, see <http://www.gnu.org/licenses/>.
16+
*/
17+
18+
#pragma once
19+
20+
#define TARGET_BOARD_IDENTIFIER "SGF7"
21+
22+
#define USBD_PRODUCT_STRING "SOLOGOODF722"
23+
24+
#define LED0 PC15
25+
26+
#define BEEPER PC13
27+
#define BEEPER_INVERTED
28+
29+
// *************** Gyro & ACC **********************
30+
#define USE_SPI
31+
#define USE_SPI_DEVICE_1
32+
33+
#define SPI1_NSS_PIN PA4
34+
#define SPI1_SCK_PIN PA5
35+
#define SPI1_MISO_PIN PA6
36+
#define SPI1_MOSI_PIN PA7
37+
38+
39+
#define USE_IMU_MPU6000
40+
#define IMU_MPU6000_ALIGN CW180_DEG
41+
#define MPU6000_CS_PIN SPI1_NSS_PIN
42+
#define MPU6000_SPI_BUS BUS_SPI1
43+
44+
#define USE_IMU_BMI270
45+
#define IMU_BMI270_ALIGN CW180_DEG
46+
#define BMI270_CS_PIN SPI1_NSS_PIN
47+
#define BMI270_SPI_BUS BUS_SPI1
48+
49+
#define USE_IMU_ICM42605
50+
#define IMU_ICM42605_ALIGN CW180_DEG
51+
#define ICM42605_CS_PIN SPI1_NSS_PIN
52+
#define ICM42605_SPI_BUS BUS_SPI1
53+
54+
// *************** I2C/Baro/Mag *********************
55+
#define USE_I2C
56+
#define USE_I2C_DEVICE_1
57+
#define I2C1_SCL PB8
58+
#define I2C1_SDA PB9
59+
60+
#define DEFAULT_I2C_BUS BUS_I2C1
61+
62+
#define USE_BARO
63+
#define BARO_I2C_BUS DEFAULT_I2C_BUS
64+
#define USE_BARO_DPS310
65+
66+
#define USE_MAG
67+
#define MAG_I2C_BUS DEFAULT_I2C_BUS
68+
#define USE_MAG_ALL
69+
70+
#define TEMPERATURE_I2C_BUS DEFAULT_I2C_BUS
71+
72+
#define PITOT_I2C_BUS DEFAULT_I2C_BUS
73+
74+
#define USE_RANGEFINDER
75+
#define RANGEFINDER_I2C_BUS DEFAULT_I2C_BUS
76+
77+
// *************** FLASH **************************
78+
#define USE_SPI_DEVICE_3
79+
#define SPI3_NSS_PIN PA15
80+
#define SPI3_SCK_PIN PC10
81+
#define SPI3_MISO_PIN PC11
82+
#define SPI3_MOSI_PIN PB5
83+
84+
#define M25P16_CS_PIN SPI3_NSS_PIN
85+
#define M25P16_SPI_BUS BUS_SPI3
86+
#define USE_FLASHFS
87+
#define USE_FLASH_M25P16
88+
#define ENABLE_BLACKBOX_LOGGING_ON_SPIFLASH_BY_DEFAULT
89+
90+
91+
// *************** OSD *****************************
92+
#define USE_SPI_DEVICE_2
93+
#define SPI2_NSS_PIN PB12
94+
#define SPI2_SCK_PIN PB13
95+
#define SPI2_MISO_PIN PB14
96+
#define SPI2_MOSI_PIN PB15
97+
98+
#define USE_MAX7456
99+
#define MAX7456_SPI_BUS BUS_SPI2
100+
#define MAX7456_CS_PIN SPI2_NSS_PIN
101+
102+
// *************** UART *****************************
103+
#define USE_VCP
104+
105+
#define USE_UART1
106+
#define UART1_RX_PIN PB7
107+
#define UART1_TX_PIN PB6
108+
109+
#define USE_UART2
110+
#define UART2_RX_PIN PA3
111+
#define UART2_TX_PIN PA2
112+
113+
#define USE_UART3
114+
#define UART3_RX_PIN PB11
115+
#define UART3_TX_PIN PB10
116+
117+
#define USE_UART4
118+
#define UART4_RX_PIN PA1
119+
#define UART4_TX_PIN PA0
120+
121+
#define USE_UART5
122+
#define UART5_RX_PIN PD2
123+
#define UART5_TX_PIN PC12
124+
125+
#define USE_UART6
126+
#define UART6_RX_PIN PC7
127+
#define UART6_TX_PIN PC6
128+
129+
#define SERIAL_PORT_COUNT 7
130+
131+
#define DEFAULT_RX_TYPE RX_TYPE_SERIAL
132+
#define SERIALRX_PROVIDER SERIALRX_CRSF
133+
#define SERIALRX_UART SERIAL_PORT_USART2
134+
135+
// *************** ADC *****************************
136+
#define USE_ADC
137+
#define ADC_INSTANCE ADC1
138+
#define ADC1_DMA_STREAM DMA2_Stream0
139+
#define ADC_CHANNEL_1_PIN PC1
140+
#define ADC_CHANNEL_2_PIN PC3
141+
142+
#define VBAT_ADC_CHANNEL ADC_CHN_1
143+
#define CURRENT_METER_ADC_CHANNEL ADC_CHN_2
144+
145+
146+
#define DEFAULT_FEATURES (FEATURE_TX_PROF_SEL | FEATURE_CURRENT_METER | FEATURE_TELEMETRY | FEATURE_VBAT | FEATURE_OSD | FEATURE_BLACKBOX)
147+
// *************** PINIO ************************
148+
#define USE_PINIO
149+
#define USE_PINIOBOX
150+
#define PINIO1_PIN PC2
151+
#define PINIO2_PIN PC0
152+
153+
// *************** LEDSTRIP ************************
154+
#define USE_LED_STRIP
155+
#define WS2811_PIN PB3
156+
157+
// Others
158+
159+
#define USE_SERIAL_4WAY_BLHELI_INTERFACE
160+
#define CURRENT_METER_SCALE 250
161+
162+
#define TARGET_IO_PORTA 0xffff
163+
#define TARGET_IO_PORTB 0xffff
164+
#define TARGET_IO_PORTC 0xffff
165+
#define TARGET_IO_PORTD (BIT(2))
166+
167+
#define MAX_PWM_OUTPUT_PORTS 8
168+
169+
#define USE_DSHOT
170+
#define USE_ESC_SENSOR

0 commit comments

Comments
 (0)