RC522-stm32程序,親測可用
單片機源程序如下:
- #include "stm32f10x.h"
- #include "OLED_I2C.h"
- #include "delay.h"
- #include "usart.h"
- #include "rc522.h"
- #include "rc522_config.h"
- #include <stdbool.h>
- /*
- CS--PA3 SCK-PA5 MOSI-PA7 MISO-PA6 RST-PA2
- */
- int main(void)
- {
- DelayInit();
- USART1_Config();
- RC522_Init ();
- printf ( "WF-RC522 Test\n" );
- PcdReset ();
-
- /*設(shè)置工作方式*/
- M500PcdConfigISOType ( 'A' );
- while(1)
- {
- IC_test();
- DelayMs(1000);
- }
- }
復(fù)制代碼
代碼工程51hei附件下載:
STM32F103-RC522.7z
(195.15 KB, 下載次數(shù): 72)
2021-8-21 16:33 上傳
點擊文件名下載附件
下載積分: 黑幣 -5
|