2025-05-29 13:03:41 +08:00

41 lines
550 B
C

#include "stm32f10x.h" // Device header
#include "Delay.h"
#include "OLED.h"
#include "Serial.h"
uint8_t RxData;
int main(void)
{
OLED_Init();
OLED_ShowString(1, 1, "RxData:");
Serial_Init();
while (1)
{
//
// printf("111111");
// Delay_ms(500);
//
if(Serial_GetRxFlag()==1)
{
uint8_t a=Serial_GetRxData();
Serial_SendByte(a);
//Delay_ms(10);
}
// if (Serial_GetRxFlag() == 1)
// {
// RxData = Serial_GetRxData();
// Serial_SendByte(RxData);
// OLED_ShowHexNum(1, 8, RxData, 2);
// }
}
}