I think I am having a brain dead moment.
I am trying to access 8 Ethernet Clients in a loop using a Uno and a W5500 ethernet shield.
I have set everything up (obvious stuff omitted) eg:
I can access each client using client1.read(), client2.read() etc but I want to access them all using a 'for' loop. eg:
for (i = 0; i < 6; i++) // 6 clients to access
for (a = 0; a < 10; a++) // 10 bytes to read
array[(i * 10) + a] = client'i'.read(); // 60 byte array, 10 per client
I know there is no such thing as "client'i'" but I am just using it as a guide.
How do I change the client number to match the 'i'??? Can I do it using socket numbers???
(yes I know there are errors in the above example but I am only trying to get my meaning across)