twilkers:
I am so confused.I have this working in another sketch, now porting to the real end application. I call the function
print_samples() on line 307 but it is never entered and no error from compiler.I moved the definition all around
a. between setup() and loop()
b. at the end of loop()never actually gets called.
cut down storage a lot.
Sketch uses 20,576 bytes (8%) of program storage space. Maximum is 253,952 bytes.
Global variables use 1,869 bytes (22%) of dynamic memory, leaving 6,323 bytes for local variables. Maximum is 8,192 bytes.still never actually gets called.
what is keeping the function from getting executed?
thanks,
tim
Tim,
Remove the local declaration of client() on line 258, You already have a global declaration on line 98.
When you execute the code on line 258
// listen for incoming clients
EthernetClient client = server.available();
if (client) {
Serial.println("new client");
You are creating a NEW object client() Then the call to print_samples() uses the Global client() that has never been initialized, it goes crazy.
Change it to this:
// listen for incoming clients
client = server.available();
if (client) {
Serial.println("new client");
I deleted the EthernetClient on line 258, and changed the IP address to match my network. Attached is a screen shot
Chuck.
