feat: H7 support (#5738)
Co-authored-by: Richard Li <richard.li@ces.hk> Co-authored-by: philmoz <phil.a.mitchell@gmail.com> Co-authored-by: raphaelcoeffic <1050031+raphaelcoeffic@users.noreply.github.com>
This commit is contained in:
co-authored by
Richard Li
philmoz
raphaelcoeffic
parent
5a15ffb017
commit
3d25c2a0f8
@@ -66,7 +66,7 @@ set(FLYSKY_GIMBAL ON)
|
||||
|
||||
add_definitions(
|
||||
-DSTM32F429_439xx -DSTM32F429xx
|
||||
-DSDRAM -DCCMRAM -DCOLORLCD -DLIBOPENUI
|
||||
-DSDRAM -DCOLORLCD -DLIBOPENUI
|
||||
-DHARDWARE_TOUCH -DHARDWARE_KEYS
|
||||
-DSOFTWARE_KEYBOARD -DUSE_HATS_AS_KEYS)
|
||||
|
||||
|
||||
@@ -83,7 +83,7 @@ void ledStripOff()
|
||||
ws2812_update(&_led_timer);
|
||||
}
|
||||
|
||||
void boardBLInit()
|
||||
void boardBLEarlyInit()
|
||||
{
|
||||
// USB charger status pins
|
||||
gpio_init(UCHARGER_GPIO, GPIO_IN, GPIO_PIN_SPEED_LOW);
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
#include "translations.h"
|
||||
|
||||
#include "targets/common/arm/stm32/bootloader/boot.h"
|
||||
#include "targets/common/arm/stm32/bootloader/bin_files.h"
|
||||
#include "bootloader/firmware_files.h"
|
||||
|
||||
#include <lvgl/lvgl.h>
|
||||
|
||||
@@ -186,7 +186,7 @@ void bootloaderDrawScreen(BootloaderState st, int opt, const char* str)
|
||||
} else if (opt == FC_OK) {
|
||||
VersionTag tag;
|
||||
memset(&tag, 0, sizeof(tag));
|
||||
extractFirmwareVersion(&tag);
|
||||
getFileFirmwareVersion(&tag);
|
||||
if (strcmp(tag.flavour, FLAVOUR)) {
|
||||
lcd->drawText(20, MESSAGE_TOP, LV_SYMBOL_CLOSE " " TR_BL_INVALID_FIRMWARE,
|
||||
BL_FOREGROUND);
|
||||
|
||||
@@ -0,0 +1,21 @@
|
||||
/*
|
||||
* Copyright (C) EdgeTX
|
||||
*
|
||||
* License GPLv2: http://www.gnu.org/licenses/gpl-2.0.html
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License version 2 as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "hal/switch_driver.h"
|
||||
#include "stm32_switch_driver.h"
|
||||
|
||||
SwitchHwPos bsp_get_switch_position(const stm32_switch_t *sw, SwitchCategory cat, uint8_t idx) {return SWITCH_HW_MID;}
|
||||
@@ -420,12 +420,10 @@
|
||||
|
||||
// SPI NOR Flash
|
||||
#define FLASH_SPI SPI6
|
||||
#define FLASH_SPI_CS_GPIO GPIOG
|
||||
#define FLASH_SPI_CS_GPIO_PIN LL_GPIO_PIN_6 // PG.06
|
||||
#define FLASH_SPI_GPIO GPIOG
|
||||
#define FLASH_SPI_SCK_GPIO_PIN LL_GPIO_PIN_13 // PG.13
|
||||
#define FLASH_SPI_MISO_GPIO_PIN LL_GPIO_PIN_12 // PG.12
|
||||
#define FLASH_SPI_MOSI_GPIO_PIN LL_GPIO_PIN_14 // PG.14
|
||||
#define FLASH_SPI_CS_GPIO GPIO_PIN(GPIOG, 6) // PG.06
|
||||
#define FLASH_SPI_SCK_GPIO GPIO_PIN(GPIOG, 13) // PG.13
|
||||
#define FLASH_SPI_MISO_GPIO GPIO_PIN(GPIOG, 12) // PG.12
|
||||
#define FLASH_SPI_MOSI_GPIO GPIO_PIN(GPIOG, 14) // PG.14
|
||||
#define FLASH_SPI_DMA DMA2
|
||||
#define FLASH_SPI_DMA_CHANNEL LL_DMA_CHANNEL_1
|
||||
#define FLASH_SPI_DMA_TX_STREAM LL_DMA_STREAM_5
|
||||
|
||||
Reference in New Issue
Block a user