Add comments to initialisation code. Remove debug prints. Remove some (probably) unnecessary comments.

git-svn-id: svn+ssh://oldsvn/home/mlalondesvn/svn/cral@66 3ee9b42a-b53c-0410-a25e-f0b6218d5d5b
master
follower 17 years ago
parent 215a3deaf2
commit 2a5e2e31c6

@ -95,25 +95,31 @@ void initModule() {
*/ */
// I thought this wasn't needed but seems like it is. /*
Serial.println("Triggering reset..."); Initialise the W5100 chip
(Originally I thought it was possible for the chip
to function without a hardware reset but it
seems not to be the case.)
*/
pinMode(PIN_RESET, OUTPUT); pinMode(PIN_RESET, OUTPUT);
digitalWrite(PIN_RESET, HIGH); // no reset // We rely on the time between function calls to
//delay(10); // Pretty arbitrary length -- do we need it? // be long enough for the chip to recognise the
// reset.
digitalWrite(PIN_RESET, HIGH);
digitalWrite(PIN_RESET, LOW); // reset digitalWrite(PIN_RESET, LOW); // reset
//delay(10); digitalWrite(PIN_RESET, HIGH);
digitalWrite(PIN_RESET, HIGH); // no reset
//delay(10);
Serial.println("Reset triggered...");
// driver chip init (Might be redundant with the above reset.) // Chip initialisation by driver
Serial.println("Call iinchip_init..."); // Might be redundant following the above reset,
// as this performs a software reset.
iinchip_init(); iinchip_init();
// driver sysinit // Initialise driver
Serial.println("Call sysinit..."); // (This is required to configure some variables used
// internally by the driver--even if the default chip
// configuration is used.)
sysinit(0x55, 0x55); sysinit(0x55, 0x55);
} }

Loading…
Cancel
Save