STM32的96位唯一身份标识各位代表什么含义?

[复制链接]
6817|1
 楼主| S448 发表于 2012-7-29 02:19 | 显示全部楼层 |阅读模式
怀疑买到了把相同封装但型号重新丝印的STM32芯片,不知从读得的STM32的96位唯一身份标识是否可以判断实际到底是哪个型号的芯片。
读到的其中一片芯片的ID是:E8210020D90100087D3700087F370008。
 楼主| S448 发表于 2012-7-29 02:37 | 显示全部楼层
本帖最后由 S448 于 2012-7-29 02:45 编辑

现在用的是STM32F103RCT6,USART3的接收中断死活进不去,用示波器监测波形,数据也到了USART3的接收管脚PB11,但就是进不去接收中断,发送数据可以正常发出来,非常奇怪。

以前用过STM32F103VBT6和STM32F103C8T6,也都用过这两个芯片的USART3,一点问题没有,又仔细检查了代码,没有发现问题,所以觉的不是程序配置的问题。

  1. //管脚初始化函数
  2. void RS485_GPIO_Init(void)
  3. {
  4. GPIO_InitTypeDef  GPIO_InitStructure;

  5. RCC_APB2PeriphClockCmd(RCC_APB2Periph_GPIOB, ENABLE);
  6. GPIO_InitStructure.GPIO_Pin   = GPIO_Pin_11;    //RX(PB11)
  7. GPIO_InitStructure.GPIO_Mode  = GPIO_Mode_IN_FLOATING;
  8. GPIO_Init(GPIOB, &GPIO_InitStructure);

  9. GPIO_InitStructure.GPIO_Pin   = GPIO_Pin_10;    //Tx(PB10)
  10. GPIO_InitStructure.GPIO_Speed = GPIO_Speed_50MHz;
  11. GPIO_InitStructure.GPIO_Mode  = GPIO_Mode_AF_PP;
  12. GPIO_Init(GPIOB, &GPIO_InitStructure);
  13.             
  14. GPIO_InitStructure.GPIO_Pin   = GPIO_Pin_2;       //DE(PB2)
  15. GPIO_InitStructure.GPIO_Mode  = GPIO_Mode_Out_PP;
  16. GPIO_InitStructure.GPIO_Speed = GPIO_Speed_50MHz;
  17. GPIO_Init(GPIOB, &GPIO_InitStructure);
  18. }

  19. //通讯接口初始化函数
  20. void RS485_Init(void)
  21. {
  22.         USART_InitTypeDef USART_InitStructure;                        

  23.         USART_InitStructure.USART_BaudRate= 9600;                                                         
  24.         USART_InitStructure.USART_WordLength          = USART_WordLength_8b;
  25.         USART_InitStructure.USART_Parity = USART_Parity_No ;
  26.         USART_InitStructure.USART_StopBits            = USART_StopBits_1;        
  27.         USART_InitStructure.USART_HardwareFlowControl =   USART_HardwareFlowControl_None;
  28.         USART_InitStructure.USART_Mode                = USART_Mode_Rx | USART_Mode_Tx;
  29.         USART_Init(USART3, &USART_InitStructure);

  30.         USART_ITConfig(USART3, USART_IT_RXNE, ENABLE);                 //打开接收中断
  31.         USART_Cmd(USART3, ENABLE);
  32.         RS485_Rx_CS;      //切换到接收状态
  33.                                                                   
  34. }
  35. void USART3_IRQHandler(void)
  36. {
  37.        u8 temp=0;
  38.        if(USART_GetITStatus(USART3, USART_IT_RXNE) != RESET)
  39.        {
  40.                  temp=USART_ReceiveData(USART3);
  41.                  //其他接收处理。。。。
  42.        }
  43. }
  44. //还一个USART3的中断优先级配置
  45. NVIC_InitTypeDef NVIC_InitStructure;
  46. NVIC_SetVectorTable(NVIC_VectTab_FLASH, 0x0);      
  47. NVIC_PriorityGroupConfig(NVIC_PriorityGroup_0);

  48. NVIC_InitStructure.NVIC_IRQChannel = USART3_IRQChannel;   
  49. NVIC_InitStructure.NVIC_IRQChannelPreemptionPriority = 0;
  50. NVIC_InitStructure.NVIC_IRQChannelSubPriority = 1;
  51. NVIC_InitStructure.NVIC_IRQChannelCmd = ENABLE;
  52. NVIC_Init(&NVIC_InitStructure);


上述代码我实在没看出有什么问题,因为在其他型号的STM32F103上我都用过的
实在没招了,现在怀疑买的STM32F103RCT6芯片可能是封装为64脚的其他小FLASH或RAM的STM32F103或STM32F101改了丝印来的。
您需要登录后才可以回帖 登录 | 注册

本版积分规则

35

主题

519

帖子

2

粉丝
快速回复 在线客服 返回列表 返回顶部