将#define PAGE_MAX 转移到func.h成功

This commit is contained in:
james 2024-08-10 01:16:56 +08:00
parent 43e6e6127f
commit 3f8313799e
5 changed files with 3 additions and 3 deletions

View File

@ -61,6 +61,7 @@
![alt text](my_picture/温度.png) ![alt text](my_picture/温度.png)
### 显示时间 ### 显示时间
![显示时间.jpg](my_picture/显示时间.jpg)
[参考(https://blog.csdn.net/toopoo/article/details/113665077)](https://blog.csdn.net/toopoo/article/details/113665077) [参考(https://blog.csdn.net/toopoo/article/details/113665077)](https://blog.csdn.net/toopoo/article/details/113665077)
``` c ``` c
void greattime() void greattime()

BIN
my_picture/显示时间.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 66 KiB

View File

@ -2,7 +2,7 @@
#include <rtthread.h> #include <rtthread.h>
#include <stdio.h> #include <stdio.h>
#include <malloc.h> #include <malloc.h>
#define PAGE_MAX 2
// 当前方向 // 当前方向
void mytime(); void mytime();
void greattime(); void greattime();

View File

@ -3,6 +3,7 @@
#include <board.h> #include <board.h>
#include "infrared.h" #include "infrared.h"
#include <drv_gpio.h> #include <drv_gpio.h>
#include "my_func.h"
#define DBG_TAG "main" #define DBG_TAG "main"
#define DBG_LVL DBG_LOG #define DBG_LVL DBG_LOG
@ -13,7 +14,6 @@
/* 配置 LED 灯引脚 */ /* 配置 LED 灯引脚 */
#define PIN_LED_B GET_PIN(F, 11) // PF11 : LED_B --> LED #define PIN_LED_B GET_PIN(F, 11) // PF11 : LED_B --> LED
#define PIN_LED_R GET_PIN(F, 12) // PF12 : LED_R --> LED #define PIN_LED_R GET_PIN(F, 12) // PF12 : LED_R --> LED
#define PAGE_MAX 2
extern rt_atomic_t now_direction; extern rt_atomic_t now_direction;
extern rt_atomic_t snake_pressed; extern rt_atomic_t snake_pressed;

View File

@ -35,7 +35,6 @@ rt_atomic_t page_chosen = 1;
rt_atomic_t page_first = 1; rt_atomic_t page_first = 1;
rt_atomic_t page_stop = 0; rt_atomic_t page_stop = 0;
#define PAGE_MAX 2
#define GPIO_LED_B GET_PIN(F, 11) #define GPIO_LED_B GET_PIN(F, 11)
#define GPIO_LED_R GET_PIN(F, 12) #define GPIO_LED_R GET_PIN(F, 12)