git.ucc.asn.au
/
uccvend-snackrom.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
stupid bug
[uccvend-snackrom.git]
/
ROM2
/
main.c
diff --git
a/ROM2/main.c
b/ROM2/main.c
index
0026edc
..
81919f0
100644
(file)
--- a/
ROM2/main.c
+++ b/
ROM2/main.c
@@
-2,6
+2,7
@@
#include "keypad.h"
#include "chime.h"
#include "server.h"
#include "keypad.h"
#include "chime.h"
#include "server.h"
+#include "coinmech.h"
#include "vend.h"
u16 uid;
#include "vend.h"
u16 uid;
@@
-98,18
+99,19
@@
void selection_menu() {
switch (last_key) {
case KEY_RESET:
scroll_msg("PRESS COIN REFUND");
switch (last_key) {
case KEY_RESET:
scroll_msg("PRESS COIN REFUND");
- goto reset;
+ while (coin_value);
+ break;
case KEY_0:
switch (server_credit_account(uid, pin, coin_value)) {
case CREDIT_OK:
coin_eat();
case KEY_0:
switch (server_credit_account(uid, pin, coin_value)) {
case CREDIT_OK:
coin_eat();
- set_msg(" SUCCESS! ");
+ set_msg(" SUCCESS! "
, WRAP_NONE
);
delay(1000);
break;
case CREDIT_FAIL:
delay(1000);
break;
case CREDIT_FAIL:
- coin_refund();
-
set_msg(" FAILED! "
);
-
delay(1000
);
+ set_msg(" FAILED! " "PRESS COIN" " REFUND ",
+
WRAP_ALTERNATE
);
+
while (coin_value
);
break;
}
break;
break;
}
break;
@@
-130,7
+132,7
@@
void selection_menu() {
break;
default:
selection = selection * 10 + (last_key%10);
break;
default:
selection = selection * 10 + (last_key%10);
- make_request(
uid, pin,
selection);
+ make_request(selection);
selection = 0;
}
}
selection = 0;
}
}
UCC
git Repository :: git.ucc.asn.au