Go Down

Topic: Ethernet library -- Smaller and more functional (Read 10786 times) previous topic - next topic

A.Selby

I'm bummed ... I was hoping that this new ethernet library would solve my problem ... It didn't after five connections the Arduino the arduino actively refuses the next connection.

I have the information about my program:

http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1234006420

(Most of it is on the second page)

The long and short of it is ... I have a .net app on my computer that sends IR timing pairs to the arduino then it flashes a IR led ... if I wait a min or so between commands it works ... but I want to turn a ipaq in to a remote ... any ideas would be very helpful ... it anyone has any ideas why it would work four or five times then stop working for a min ???

mellis

The Ethernet library only supports 4 connections at once.  So if the connections are being disconnected right away, you might be using them all up.

A.Selby

is there any way to close those connections when I'm done with them ... I'm sure thats what happening ... Or do I have to wait for it to timeout/close them its self

mellis


A.Selby

yeah, I am using client.stop() and I still get the same issue ... its like it doesn't do anything ?

GordonEndersby


Are there any known problems with the ide version 13 and ethernet2?
Before I start posting up code I just wanted to see if anyone else has used ide ver13 or if its just my fiddling that has broken it.

Im getting multiple definitions from the arduion core print.cpp and the ethernet2 print.cpp stuff.

Thanks

Gordon

A.Selby

I had the same problem with the print.cpp ... I just removed the old print from the core folder ... and everything seems to be working great ...

GordonEndersby


Hasnt that got a knock on effect for other libraries?
Or does the Ethernet2 print.cpp take over and serial.print and others use that?

Gordon

A.Selby

everything seems to be working so far ... serial.print and all

JP.M

For what it's worth, I've had a sketch running with the Ethernet2 library for 18 hours. The sketch does a TCP connect/read/close cycle and the Duemillanove on which it is running is still going strong after 254,000 connects.

As an aside, the Ethernet library of arduino-0015 still borks after four connect/close pairs.

etracer

#25
Apr 22, 2009, 10:08 pm Last Edit: Apr 22, 2009, 10:11 pm by etracer Reason: 1
Quote
As an aside, the Ethernet library of arduino-0015 still borks after four connect/close pairs.


See here for a revised version that corrects the connection problems (and fixes a number of other bugs).

And note that the Client.cpp in the Ethernet2 library is basically identical to the one included in the "standard" library (meaning it has the same bugs).

JP.M

That seems to work. Thank you.

BTW, with Ethernet2 I get 6064 bytes (of a 30720 byte maximum). The "new" Ethernet is a bit larger than that: same sketch comes in at 7486 bytes.


follower

Quote
BTW, with Ethernet2 I get 6064 bytes (of a 30720 byte maximum). The "new" Ethernet is a bit larger than that: same sketch comes in at 7486 bytes.

AFAIK (and I could be wrong) the "new" Ethernet hasn't yet incorporated the changes from Ethernet2 that made it smaller.

--Phil.

Go Up