-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathSeeder.ino
36 lines (29 loc) · 907 Bytes
/
Seeder.ino
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
#include "gpio.h"
#include "btc.h"
#include "workflow.h"
#include "GlobalVARS.h"
sWallet myWallet;
sButton btnMove(PIN_MOVE);
sButton btnSelect(PIN_SELECT);
void setup() {
Serial.begin(SERIAL_BAUD); // Init Serial port
EEPROMsetup(); // Init EEPROMdata
Init_TFT(); // Init TFT wallet
initWallet(); // Init wallet data
myWallet.State = STATE_INITMENU;
}
void loop() {
while(true){
/***** Check button state ******/
btnMove.check();
btnSelect.check();
/***** Print menu options ***********/
switch(myWallet.State){
case STATE_INITMENU: doInitMenu(); break;
case STATE_WORDS: doMenuWords(); break;
case STATE_SEED: doShowSeed(); break;
case STATE_COINSEED: doCoinSeed(); break;
}
delay(10);
}
}