summaryrefslogtreecommitdiff
path: root/bsp/stm32/stm32f469-st-disco
diff options
context:
space:
mode:
authorBernard Xiong <[email protected]>2021-05-28 16:20:08 +0800
committerGitHub <[email protected]>2021-05-28 16:20:08 +0800
commit92beddf3bccf6346e26aa097f82464456fb8e6bd (patch)
tree197e4a108118dda016ea02274172f0c40e7ee8ed /bsp/stm32/stm32f469-st-disco
parentb18a99b44240ec3152011e159cc24a5af8dff0ce (diff)
parent03f4d40e30f3c94e1db0b3a65b3610dee695694a (diff)
Merge pull request #4737 from mysterywolf/3,1,xformatv3.1.5
[lts 3.1.x] format codes
Diffstat (limited to 'bsp/stm32/stm32f469-st-disco')
-rw-r--r--bsp/stm32/stm32f469-st-disco/applications/lcd_init.c2
-rw-r--r--bsp/stm32/stm32f469-st-disco/applications/main.c2
-rw-r--r--bsp/stm32/stm32f469-st-disco/board/board.c10
-rw-r--r--bsp/stm32/stm32f469-st-disco/board/board.h2
-rw-r--r--bsp/stm32/stm32f469-st-disco/board/ports/drv_otm8009a.c20
-rw-r--r--bsp/stm32/stm32f469-st-disco/board/ports/drv_qspi_flash.c6
-rw-r--r--bsp/stm32/stm32f469-st-disco/board/ports/drv_sdcard.c12
-rw-r--r--bsp/stm32/stm32f469-st-disco/board/ports/fal_cfg.h6
-rw-r--r--bsp/stm32/stm32f469-st-disco/board/ports/lcd_port.h14
-rw-r--r--bsp/stm32/stm32f469-st-disco/board/ports/qspi_mnt.c2
-rw-r--r--bsp/stm32/stm32f469-st-disco/board/ports/sdram_port.h2
-rw-r--r--bsp/stm32/stm32f469-st-disco/board/ports/touch/drv_touch.c6
-rw-r--r--bsp/stm32/stm32f469-st-disco/board/ports/touch/drv_touch.h4
-rw-r--r--bsp/stm32/stm32f469-st-disco/board/ports/touch/drv_touch_ft.c10
14 files changed, 49 insertions, 49 deletions
diff --git a/bsp/stm32/stm32f469-st-disco/applications/lcd_init.c b/bsp/stm32/stm32f469-st-disco/applications/lcd_init.c
index 277a754ae6..2660e6ef7c 100644
--- a/bsp/stm32/stm32f469-st-disco/applications/lcd_init.c
+++ b/bsp/stm32/stm32f469-st-disco/applications/lcd_init.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2006-2018, RT-Thread Development Team
+ * Copyright (c) 2006-2021, RT-Thread Development Team
*
* SPDX-License-Identifier: Apache-2.0
*
diff --git a/bsp/stm32/stm32f469-st-disco/applications/main.c b/bsp/stm32/stm32f469-st-disco/applications/main.c
index 8feca19928..759572d376 100644
--- a/bsp/stm32/stm32f469-st-disco/applications/main.c
+++ b/bsp/stm32/stm32f469-st-disco/applications/main.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2006-2018, RT-Thread Development Team
+ * Copyright (c) 2006-2021, RT-Thread Development Team
*
* SPDX-License-Identifier: Apache-2.0
*
diff --git a/bsp/stm32/stm32f469-st-disco/board/board.c b/bsp/stm32/stm32f469-st-disco/board/board.c
index 8c4c361dcc..fefb07fafd 100644
--- a/bsp/stm32/stm32f469-st-disco/board/board.c
+++ b/bsp/stm32/stm32f469-st-disco/board/board.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2006-2018, RT-Thread Development Team
+ * Copyright (c) 2006-2021, RT-Thread Development Team
*
* SPDX-License-Identifier: Apache-2.0
*
@@ -17,11 +17,11 @@ void SystemClock_Config(void)
RCC_ClkInitTypeDef RCC_ClkInitStruct = {0};
RCC_PeriphCLKInitTypeDef PeriphClkInitStruct = {0};
- /** Configure the main internal regulator output voltage
+ /** Configure the main internal regulator output voltage
*/
__HAL_RCC_PWR_CLK_ENABLE();
__HAL_PWR_VOLTAGESCALING_CONFIG(PWR_REGULATOR_VOLTAGE_SCALE1);
- /** Initializes the CPU, AHB and APB busses clocks
+ /** Initializes the CPU, AHB and APB busses clocks
*/
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSE;
RCC_OscInitStruct.HSEState = RCC_HSE_ON;
@@ -36,13 +36,13 @@ void SystemClock_Config(void)
{
Error_Handler();
}
- /** Activate the Over-Drive mode
+ /** Activate the Over-Drive mode
*/
if (HAL_PWREx_EnableOverDrive() != HAL_OK)
{
Error_Handler();
}
- /** Initializes the CPU, AHB and APB busses clocks
+ /** Initializes the CPU, AHB and APB busses clocks
*/
RCC_ClkInitStruct.ClockType = RCC_CLOCKTYPE_HCLK|RCC_CLOCKTYPE_SYSCLK
|RCC_CLOCKTYPE_PCLK1|RCC_CLOCKTYPE_PCLK2;
diff --git a/bsp/stm32/stm32f469-st-disco/board/board.h b/bsp/stm32/stm32f469-st-disco/board/board.h
index 0880c1f384..607aa3877d 100644
--- a/bsp/stm32/stm32f469-st-disco/board/board.h
+++ b/bsp/stm32/stm32f469-st-disco/board/board.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2006-2018, RT-Thread Development Team
+ * Copyright (c) 2006-2021, RT-Thread Development Team
*
* SPDX-License-Identifier: Apache-2.0
*
diff --git a/bsp/stm32/stm32f469-st-disco/board/ports/drv_otm8009a.c b/bsp/stm32/stm32f469-st-disco/board/ports/drv_otm8009a.c
index 84202f84c8..8fde3a56ae 100644
--- a/bsp/stm32/stm32f469-st-disco/board/ports/drv_otm8009a.c
+++ b/bsp/stm32/stm32f469-st-disco/board/ports/drv_otm8009a.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2006-2018, RT-Thread Development Team
+ * Copyright (c) 2006-2021, RT-Thread Development Team
*
* SPDX-License-Identifier: Apache-2.0
*
@@ -7,7 +7,7 @@
* Date Author Notes
* 2019-05-23 WillianChan first version
*/
-
+
#include <board.h>
#ifdef BSP_USING_LCD_OTM8009A
extern DSI_HandleTypeDef hdsi;
@@ -93,9 +93,9 @@ const rt_uint8_t RDS49[] = {0xF5, 0x06};
const rt_uint8_t RDS50[] = {0x00, 0xB1};
const rt_uint8_t RDS51[] = {0xC6, 0x06};
-void otm8009a_reset(void)
+void otm8009a_reset(void)
{
- rt_pin_mode (GET_PIN(H, 7), PIN_MODE_OUTPUT);
+ rt_pin_mode (GET_PIN(H, 7), PIN_MODE_OUTPUT);
rt_pin_write(GET_PIN(H, 7), PIN_LOW);
rt_thread_delay(rt_tick_from_millisecond(20));
rt_pin_write(GET_PIN(H, 7), PIN_HIGH);
@@ -116,7 +116,7 @@ static void otm8009a_write_cmd(uint8_t *p, uint32_t num)
static void otm8009a_delay(uint32_t d)
{
- rt_thread_delay(rt_tick_from_millisecond(d));
+ rt_thread_delay(rt_tick_from_millisecond(d));
}
static void otm8009a_config(rt_uint32_t pixel_format)
@@ -127,11 +127,11 @@ static void otm8009a_config(rt_uint32_t pixel_format)
otm8009a_write_cmd((rt_uint8_t *)RDL02, 2);
otm8009a_write_cmd((rt_uint8_t *)RDS02, 0);
otm8009a_write_cmd((rt_uint8_t *)RDS03, 0);
- otm8009a_delay(10);
+ otm8009a_delay(10);
otm8009a_write_cmd((rt_uint8_t *)RDS04, 0);
otm8009a_write_cmd((rt_uint8_t *)RDS05, 0);
- otm8009a_delay(10);
+ otm8009a_delay(10);
otm8009a_write_cmd((rt_uint8_t *)RDS06, 0);
otm8009a_write_cmd((rt_uint8_t *)RDS07, 0);
@@ -215,8 +215,8 @@ static void otm8009a_config(rt_uint32_t pixel_format)
otm8009a_write_cmd((rt_uint8_t *)RDS01, 0);
otm8009a_write_cmd((rt_uint8_t *)RDL04, 16);
otm8009a_write_cmd((rt_uint8_t *)RDS36, 0);
- otm8009a_delay(120);
-
+ otm8009a_delay(120);
+
switch (pixel_format)
{
case RTGRAPHIC_PIXEL_FORMAT_RGB565:
@@ -248,7 +248,7 @@ void stm32_mipi_lcd_init(void)
void stm32_mipi_lcd_config(rt_uint32_t pixel_format)
{
- otm8009a_config(pixel_format);
+ otm8009a_config(pixel_format);
}
void stm32_mipi_display_on(void)
diff --git a/bsp/stm32/stm32f469-st-disco/board/ports/drv_qspi_flash.c b/bsp/stm32/stm32f469-st-disco/board/ports/drv_qspi_flash.c
index f5fe27d6e1..ff1b11e34c 100644
--- a/bsp/stm32/stm32f469-st-disco/board/ports/drv_qspi_flash.c
+++ b/bsp/stm32/stm32f469-st-disco/board/ports/drv_qspi_flash.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2006-2018, RT-Thread Development Team
+ * Copyright (c) 2006-2021, RT-Thread Development Team
*
* SPDX-License-Identifier: Apache-2.0
*
@@ -8,7 +8,7 @@
* 2018-11-27 zylx first version
* 2019-04-11 ZYH port from stm32f7serial
*/
-
+
#include <board.h>
#include <drv_qspi.h>
#include <rtdevice.h>
@@ -64,7 +64,7 @@ void n25qxxa_enter_qspi_mode(struct rt_qspi_device *device)
static int rt_hw_qspi_flash_with_sfud_init(void)
{
stm32_qspi_bus_attach_device("qspi1", "qspi10", RT_NULL, 4, n25qxxa_enter_qspi_mode, RT_NULL);
-
+
/* init n25qxx */
if (RT_NULL == rt_sfud_flash_probe(FAL_USING_NOR_FLASH_DEV_NAME, "qspi10"))
{
diff --git a/bsp/stm32/stm32f469-st-disco/board/ports/drv_sdcard.c b/bsp/stm32/stm32f469-st-disco/board/ports/drv_sdcard.c
index cfe6f59e1e..9fd2d11fd4 100644
--- a/bsp/stm32/stm32f469-st-disco/board/ports/drv_sdcard.c
+++ b/bsp/stm32/stm32f469-st-disco/board/ports/drv_sdcard.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2006-2018, RT-Thread Development Team
+ * Copyright (c) 2006-2021, RT-Thread Development Team
*
* SPDX-License-Identifier: Apache-2.0
*
@@ -29,7 +29,7 @@
static void _sdcard_mount(void)
{
rt_device_t device;
-
+
device = rt_device_find("sd0");
if (device == NULL)
{
@@ -56,7 +56,7 @@ static void _sdcard_unmount(void)
rt_thread_mdelay(200);
dfs_unmount("/");
LOG_I("Unmount \"/\"");
-
+
mmcsd_wait_cd_changed(0);
stm32_mmcsd_change();
mmcsd_wait_cd_changed(RT_WAITING_FOREVER);
@@ -65,7 +65,7 @@ static void _sdcard_unmount(void)
static void sd_mount(void *parameter)
{
rt_uint8_t re_sd_check_pin = 1;
-
+
while (1)
{
rt_thread_mdelay(200);
@@ -73,7 +73,7 @@ static void sd_mount(void *parameter)
{
_sdcard_mount();
}
-
+
if (!re_sd_check_pin && (re_sd_check_pin = rt_pin_read(SD_CHECK_PIN)) != 0)
{
_sdcard_unmount();
@@ -84,7 +84,7 @@ static void sd_mount(void *parameter)
int stm32_sdcard_mount(void)
{
rt_thread_t tid;
-
+
rt_pin_mode(SD_CHECK_PIN, PIN_MODE_INPUT_PULLUP);
tid = rt_thread_create("sd_mount", sd_mount, RT_NULL,
diff --git a/bsp/stm32/stm32f469-st-disco/board/ports/fal_cfg.h b/bsp/stm32/stm32f469-st-disco/board/ports/fal_cfg.h
index 46ecb322c4..ac75718bc7 100644
--- a/bsp/stm32/stm32f469-st-disco/board/ports/fal_cfg.h
+++ b/bsp/stm32/stm32f469-st-disco/board/ports/fal_cfg.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2006-2018, RT-Thread Development Team
+ * Copyright (c) 2006-2021, RT-Thread Development Team
*
* SPDX-License-Identifier: Apache-2.0
*
@@ -57,7 +57,7 @@ extern struct fal_flash_dev nor_flash0;
&nor_flash0, \
}
-#define ONCHIP_FLASH_PART_TABLE
+#define ONCHIP_FLASH_PART_TABLE
#define QSPI_FLASH_PART_TABLE \
{FAL_PART_MAGIC_WROD, "qspiflash", FAL_USING_NOR_FLASH_DEV_NAME, 0 , (16 * 1024 * 1024), 0},
@@ -76,7 +76,7 @@ extern struct fal_flash_dev nor_flash0;
{FAL_PART_MAGIC_WROD, "param", "onchip_flash_64k", 0 , FLASH_SIZE_GRANULARITY_64K , 0}, \
{FAL_PART_MAGIC_WROD, "app", "onchip_flash_128k", 0 , FLASH_SIZE_GRANULARITY_128K, 0},
-#define QSPI_FLASH_PART_TABLE
+#define QSPI_FLASH_PART_TABLE
#else
diff --git a/bsp/stm32/stm32f469-st-disco/board/ports/lcd_port.h b/bsp/stm32/stm32f469-st-disco/board/ports/lcd_port.h
index d5ee2b13b4..b23a970538 100644
--- a/bsp/stm32/stm32f469-st-disco/board/ports/lcd_port.h
+++ b/bsp/stm32/stm32f469-st-disco/board/ports/lcd_port.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2006-2018, RT-Thread Development Team
+ * Copyright (c) 2006-2021, RT-Thread Development Team
*
* SPDX-License-Identifier: Apache-2.0
*
@@ -7,19 +7,19 @@
* Date Author Notes
* 2018-07-28 liu2guang the first version for STM32F469NI-Discovery.
*/
-
-#ifndef __DRV_LCD_H_
-#define __DRV_LCD_H_
-#include <rtthread.h>
+#ifndef __DRV_LCD_H_
+#define __DRV_LCD_H_
+
+#include <rtthread.h>
#include <rtdevice.h>
-#include <board.h>
+#include <board.h>
#define LCD_WIDTH (800U)
#define LCD_HEIGHT (480U)
#define LCD_HSYNC (1U)
-#define LCD_HBP (15U)
+#define LCD_HBP (15U)
#define LCD_HFP (16U)
#define LCD_VSYNC (2U)
#define LCD_VBP (34U)
diff --git a/bsp/stm32/stm32f469-st-disco/board/ports/qspi_mnt.c b/bsp/stm32/stm32f469-st-disco/board/ports/qspi_mnt.c
index f90b468463..5b311a391a 100644
--- a/bsp/stm32/stm32f469-st-disco/board/ports/qspi_mnt.c
+++ b/bsp/stm32/stm32f469-st-disco/board/ports/qspi_mnt.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2006-2018, RT-Thread Development Team
+ * Copyright (c) 2006-2021, RT-Thread Development Team
*
* SPDX-License-Identifier: Apache-2.0
*
diff --git a/bsp/stm32/stm32f469-st-disco/board/ports/sdram_port.h b/bsp/stm32/stm32f469-st-disco/board/ports/sdram_port.h
index 14d44f7115..7b33d36362 100644
--- a/bsp/stm32/stm32f469-st-disco/board/ports/sdram_port.h
+++ b/bsp/stm32/stm32f469-st-disco/board/ports/sdram_port.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2006-2018, RT-Thread Development Team
+ * Copyright (c) 2006-2021, RT-Thread Development Team
*
* SPDX-License-Identifier: Apache-2.0
*
diff --git a/bsp/stm32/stm32f469-st-disco/board/ports/touch/drv_touch.c b/bsp/stm32/stm32f469-st-disco/board/ports/touch/drv_touch.c
index 1ff29544ff..53437f34ef 100644
--- a/bsp/stm32/stm32f469-st-disco/board/ports/touch/drv_touch.c
+++ b/bsp/stm32/stm32f469-st-disco/board/ports/touch/drv_touch.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2006-2018, RT-Thread Development Team
+ * Copyright (c) 2006-2021, RT-Thread Development Team
*
* SPDX-License-Identifier: Apache-2.0
*
@@ -7,7 +7,7 @@
* Date Author Notes
* 2018-02-08 Zhangyihong the first version
*/
-
+
#include "drv_touch.h"
#include <string.h>
#ifdef BSP_USING_TOUCH
@@ -105,7 +105,7 @@ static void touch_thread_entry(void *parameter)
{
continue;
}
-
+
while(touch->ops->read_point(&msg) == RT_EOK)
{
switch (msg.event)
diff --git a/bsp/stm32/stm32f469-st-disco/board/ports/touch/drv_touch.h b/bsp/stm32/stm32f469-st-disco/board/ports/touch/drv_touch.h
index a8fea21d54..21bea39f83 100644
--- a/bsp/stm32/stm32f469-st-disco/board/ports/touch/drv_touch.h
+++ b/bsp/stm32/stm32f469-st-disco/board/ports/touch/drv_touch.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2006-2018, RT-Thread Development Team
+ * Copyright (c) 2006-2021, RT-Thread Development Team
*
* SPDX-License-Identifier: Apache-2.0
*
@@ -7,7 +7,7 @@
* Date Author Notes
* 2018-02-08 Zhangyihong the first version
*/
-
+
#ifndef __DRV_TOUCH_H__
#define __DRV_TOUCH_H__
diff --git a/bsp/stm32/stm32f469-st-disco/board/ports/touch/drv_touch_ft.c b/bsp/stm32/stm32f469-st-disco/board/ports/touch/drv_touch_ft.c
index a7e9275441..e85e793573 100644
--- a/bsp/stm32/stm32f469-st-disco/board/ports/touch/drv_touch_ft.c
+++ b/bsp/stm32/stm32f469-st-disco/board/ports/touch/drv_touch_ft.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2006-2018, RT-Thread Development Team
+ * Copyright (c) 2006-2021, RT-Thread Development Team
*
* SPDX-License-Identifier: Apache-2.0
*
@@ -109,7 +109,7 @@ static rt_err_t ft_read_point(touch_msg_t msg)
{
return RT_ERROR;
}
-
+
if (point_num == 0)
{
if (s_tp_down)
@@ -121,7 +121,7 @@ static rt_err_t ft_read_point(touch_msg_t msg)
msg->event = TOUCH_EVENT_NONE;
return RT_ERROR;
}
-
+
ret = ft_read(ft_i2c_bus, 0x03, point, 6);
if (ret < 0)
{
@@ -130,7 +130,7 @@ static rt_err_t ft_read_point(touch_msg_t msg)
msg->y = (point[0]&0x0F) << 8 | point[1];
msg->x = (point[2]&0x0F) << 8 | point[3];
-
+
if (s_tp_down)
{
msg->event = TOUCH_EVENT_MOVE;
@@ -138,7 +138,7 @@ static rt_err_t ft_read_point(touch_msg_t msg)
}
msg->event = TOUCH_EVENT_DOWN;
s_tp_down = 1;
-
+
return RT_EOK;
}