Simplify state machine defs and remove unneeded ones.

git-svn-id: svn+ssh://oldsvn/home/mlalondesvn/svn/cral@83 3ee9b42a-b53c-0410-a25e-f0b6218d5d5b
master
follower 17 years ago
parent fb104053ee
commit 621951f38a

@ -265,25 +265,20 @@ void loop() {
int dataLength = 0;
#define STATE_G 0
#define STATE_E 1
#define STATE_T 2
#define STATE_SPACE 3
#define STATE_SLASH 4
#define STATE_GET 0
#define STATE_READ 5
#define STATE_END -2
#define STATE_ERR -1
int state = STATE_G;
int state = STATE_GET;
int ledState = 1;
unsigned char theByte;
while (getSn_SR(testSocket) == SOCK_ESTABLISHED) {
while (getSn_RX_RSR(testSocket) > 0) {
if (state == STATE_G) {
if (state == STATE_GET) {
if (readMatch("GET /")) {
state = STATE_READ;
} else {

Loading…
Cancel
Save