Skip to content

Commit

Permalink
Use terminalError when there's a DHCP failure.
Browse files Browse the repository at this point in the history
I've chosen to flash the error LED twice when there's a DHCP error.
This number is total arbitrary and can definitely be changed; although I
do plan to document these error conditions so we won't want it changing
again and again.
  • Loading branch information
chrisroos committed Jul 23, 2012
1 parent 56f2109 commit dd778d6
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions printer.ino
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,7 @@ inline void initNetwork() {
// start the Ethernet connection:
if (Ethernet.begin(mac) == 0) {
debug("DHCP Fail!");
// no point in carrying on, so do nothing forevermore:
while(true);
terminalError(2);
}
delay(1000);
// print your local IP address:
Expand Down

0 comments on commit dd778d6

Please sign in to comment.