mirror of
https://gitee.com/Lyon1998/pikapython.git
synced 2025-01-29 17:22:56 +08:00
add portable for stm32 stdlib
This commit is contained in:
parent
beb3f3ea69
commit
1b0384c5b2
@ -3,11 +3,29 @@
|
||||
#include "PikaObj.h"
|
||||
#include <stdint.h>
|
||||
|
||||
/* support std lib for stm32 */
|
||||
#define delay_ms HAL_Delay
|
||||
typedef uint16_t u16;
|
||||
typedef uint8_t u8;
|
||||
typedef uint32_t u32;
|
||||
|
||||
#define GPIO_Pin_0 GPIO_PIN_0
|
||||
#define GPIO_Pin_1 GPIO_PIN_1
|
||||
#define GPIO_Pin_2 GPIO_PIN_2
|
||||
#define GPIO_Pin_3 GPIO_PIN_3
|
||||
#define GPIO_Pin_4 GPIO_PIN_4
|
||||
#define GPIO_Pin_5 GPIO_PIN_5
|
||||
#define GPIO_Pin_6 GPIO_PIN_6
|
||||
#define GPIO_Pin_7 GPIO_PIN_7
|
||||
#define GPIO_Pin_8 GPIO_PIN_8
|
||||
#define GPIO_Pin_9 GPIO_PIN_9
|
||||
#define GPIO_Pin_10 GPIO_PIN_10
|
||||
#define GPIO_Pin_11 GPIO_PIN_11
|
||||
#define GPIO_Pin_12 GPIO_PIN_12
|
||||
#define GPIO_Pin_13 GPIO_PIN_13
|
||||
#define GPIO_Pin_14 GPIO_PIN_14
|
||||
#define GPIO_Pin_15 GPIO_PIN_15
|
||||
|
||||
#ifdef STM32G070xx
|
||||
#include "stm32g0xx_hal.h"
|
||||
#define UART1_EXIST
|
||||
|
Loading…
x
Reference in New Issue
Block a user