From a82a2e2b191b60f69ca905c75d257ec49142d706 Mon Sep 17 00:00:00 2001 From: Jimmy Date: Fri, 11 Dec 2020 15:57:10 +1300 Subject: [PATCH] Add bin folder. Tidy up main.cpp --- .gitignore | 2 +- test/main.cpp | 84 +++++++++++++++++++++------------------------------ 2 files changed, 36 insertions(+), 50 deletions(-) diff --git a/.gitignore b/.gitignore index 662f6d5..7ab120d 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,2 @@ .vscode/ -bin/ +bin/* diff --git a/test/main.cpp b/test/main.cpp index f9c09a2..4f281d3 100644 --- a/test/main.cpp +++ b/test/main.cpp @@ -12,62 +12,48 @@ const int NRSTPD = 5; uchar serNum[5]; uchar writeDate[16] ={'T', 'e', 'n', 'g', ' ', 'B', 'o', 0, 0, 0, 0, 0, 0, 0, 0,0}; -uchar sectorKeyA[16][16] = {{0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF}, - {0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF}, - {0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF}, - }; - uchar sectorNewKeyA[16][16] = {{0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF}, - {0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xff,0x07,0x80,0x69, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF}, - {0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xff,0x07,0x80,0x69, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF}, - }; - +uchar sectorKeyA[16] = {0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF}; int main() { usart::init(1000000); printf("Hello"); - MFRC522_Init(); + PORTC |= (1<