The Bachelor's thesis - Design and implementation of a portable device for creating RFID tag lists
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

88 lines
1.6 KiB

// Only modify this file to include
// - function definitions (prototypes)
// - include files
// - extern variable definitions
// In the appropriate section
#ifndef Bakalarka_H_
#define Bakalarka_H_
#include "Arduino.h"
//add your includes for the project Bakalarka here
#include "PCD8544/PCD8544.h"
#include <Fat16.h>
//end of add your includes here
#ifdef __cplusplus
extern "C" {
#endif
void loop();
void setup();
#ifdef __cplusplus
} // extern "C"
#endif
//add your function definitions for the project Bakalarka here
// pins on ATmega328
#define RFID_IRQ 2
#define BTN 3
#define RFID_RST 4
#define DS_SCK 5
#define DS_IO 6
#define DS_RST 7
#define LCD_SS 8
#define SD_SS 9
#define RFID_SS 10
#define ENC_A A0
#define ENC_B A1
#define LCD_DC A2
#define LCD_RST A3
#define SPKR A4
#define VBAT_ADC_EN A5
#define VBAT_ADC A6
#define STAT A7
// config
#define DEBOUNCE 200
// function macros
//#define error(s) error_P(PSTR(s)) // store error strings in flash to save RAM
#define MAX_SUBMENUS 4
typedef struct menu {
const char title[PCD8544_COLS];
void (*command)();
uint8_t numSubmenus;
struct menu *submenu[MAX_SUBMENUS];
} Menu;
// prototypes
void debounceInterrupt(void);
void RFIDInterrupt(void);
void error_P(const char* str);
void frontPage(void);
void list(void);
void navigateMenu(Menu *menu);
void displayMenu(Menu *menu);
void addStorage(void);
void printDirName(const dir_t& dir);
//void SayHello(void);
//void process_command(void);
void ls(void);
void touch(void);
void rm(void);
void unrecognized(void);
//Do not add code below this line
#endif /* Bakalarka_H_ */