[英]What does RESERVERD0 in Registers like USART1 in stm32f103 mean in stm32f10x.h header file? And how do I define a custom struct for the same?
所以最近我开始对一个 stm32f103 设备进行裸机编程,我在 Keil uVision5 中引用了一个内置文件“stm32f10x.h”,我遇到了 USART 结构的TypeDef ,它就像,
typedef struct
{
__IO uint16_t SR;
uint16_t RESERVED0;
__IO uint16_t DR;
uint16_t RESERVED1;
__IO uint16_t BRR;
uint16_t RESERVED2;
__IO uint16_t CR1;
uint16_t RESERVED3;
__IO uint16_t CR2;
uint16_t RESERVED4;
__IO uint16_t CR3;
uint16_t RESERVED5;
__IO uint16_t GTPR;
uint16_t RESERVED6;
} USART_TypeDef;
而且我找不到这些RESERVEDx寄存器的任何声明或引用。 如果我想为此寄存器定义一个自定义结构,我该怎么做? 提前致谢:)
它们不是RESERVEDx
寄存器,只是不应触及的 32 位寄存器的高位字。 简单地忽略它们,不要触摸它们,不要去想它们。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.