diff options
| author | 似水流年 <[email protected]> | 2021-09-21 16:24:18 +0800 |
|---|---|---|
| committer | 似水流年 <[email protected]> | 2021-09-21 16:24:18 +0800 |
| commit | ad197870d2d149952fcddc46f4b12a7ad23a740d (patch) | |
| tree | ee599c52b10d1a8c6c0bc7fee85ccd522d6c51a5 | |
| parent | b81dc4a933470c431e2e9f0bac48304e6fb841f6 (diff) | |
main.c增加空行,将debug输出移动到board.h
| -rw-r--r-- | bsp/Vango_V85xx/applications/main.c | 2 | ||||
| -rw-r--r-- | bsp/Vango_V85xx/drivers/board.h | 8 | ||||
| -rw-r--r-- | bsp/Vango_V85xx/drivers/drv_spi.c | 9 |
3 files changed, 9 insertions, 10 deletions
diff --git a/bsp/Vango_V85xx/applications/main.c b/bsp/Vango_V85xx/applications/main.c index 26035bde9d..c0926c341c 100644 --- a/bsp/Vango_V85xx/applications/main.c +++ b/bsp/Vango_V85xx/applications/main.c @@ -50,4 +50,4 @@ void assert_errhandler(uint8_t* file, uint32_t line) { } } -#endif
\ No newline at end of file +#endif diff --git a/bsp/Vango_V85xx/drivers/board.h b/bsp/Vango_V85xx/drivers/board.h index 215ad0b194..e8e312d110 100644 --- a/bsp/Vango_V85xx/drivers/board.h +++ b/bsp/Vango_V85xx/drivers/board.h @@ -32,7 +32,13 @@ extern int __bss_end; #define HEAP_BEGIN ((void *)&__bss_end) #endif - #define HEAP_END V85XX_SRAM_END +/* #define DEBUG */ +#ifdef DEBUG +#define DEBUG_PRINTF(...) rt_kprintf(__VA_ARGS__) +#else +#define DEBUG_PRINTF(...) +#endif + #endif diff --git a/bsp/Vango_V85xx/drivers/drv_spi.c b/bsp/Vango_V85xx/drivers/drv_spi.c index 724e3cc400..ce0e5bd87d 100644 --- a/bsp/Vango_V85xx/drivers/drv_spi.c +++ b/bsp/Vango_V85xx/drivers/drv_spi.c @@ -22,13 +22,6 @@ #error "Please define at least one SPIx" #endif -/* #define DEBUG */ -#ifdef DEBUG -#define DEBUG_PRINTF(...) rt_kprintf(__VA_ARGS__) -#else -#define DEBUG_PRINTF(...) -#endif - /* private rt-thread spi ops function */ static rt_err_t configure(struct rt_spi_device* device, struct rt_spi_configuration* configuration); static rt_uint32_t xfer(struct rt_spi_device* device, struct rt_spi_message* message); @@ -199,7 +192,7 @@ int v85xx_hw_spi_init(void) result = rt_spi_bus_register(&spi_bus0, "spi1", &v85xx_spi_ops); - #endif +#endif #ifdef RT_USING_SPI2 static struct rt_spi_bus spi_bus1; |
