Rio de Janeiro, Brazil
Offline
Jr. Member
Karma: 0
Posts: 85
Software developer, free software activist
|
 |
« Reply #60 on: July 24, 2011, 11:39:51 pm » |
Guys, excuse me for this so long delay answering you - I did a lot of trips to free software conferences, had some healthy problems and (unfortunately) Arduino Forum stopped sending emails to my inbox when someone post here. Let's go - my next comments will have the answers for you!
|
|
|
|
|
Logged
|
|
|
|
|
Rio de Janeiro, Brazil
Offline
Jr. Member
Karma: 0
Posts: 85
Software developer, free software activist
|
 |
« Reply #61 on: July 24, 2011, 11:40:36 pm » |
Finally I got my project started and assembled. I have communication ok, I can program the MCU.... ethernet circuit is alive, at least it is powered, but I'm not sure if it's really talking with the prosessor. When I open browser and try to connect any IP inside the subnet, this blinks the green light like somebodys knocking, but I can't get response from it.
I have checked this dirty PCB so many times in last two days, that I'm just blind if there's shortcuts or missing links. Schematic has been turned upside down while tracing the problem, components are correct values. Voltages are in tolerances.
WebServerDebug don't give anything.
Hmm, what is the purpose of these dip swithes? I didn't put them for two reason; I don't have suitable and I don't know if it is nessessary in basic testing.
About codes, I only changed the IP-address to much my network, everything else is intact.
It just don't play the game with me, any tips left? Thanks!!!
Cheers, Kari
Are you using a shield/module based on ENC28J60 Ethernet controller? If yes, please try to run WebServerSimple example (do not run Debug example) and do a request with a light Web client (like wget or curl) -- actually the library stores all the request and, as it is using a lot of memory, if your browser send a lot of information on request it can stop the sketch because of full memory. In future I'll optimize it, but this library will *aways* use more memory than Wiznet W5100 since with ENC28J60 we need to control everything since Ethernet layer.
|
|
|
|
|
Logged
|
|
|
|
|
Rio de Janeiro, Brazil
Offline
Jr. Member
Karma: 0
Posts: 85
Software developer, free software activist
|
 |
« Reply #62 on: July 24, 2011, 11:41:02 pm » |
So, UDP are fully implemented ? We are able to send & receive packets correctly ? For TCP, it work too ? You just don't have implemented file server for the access by browser (& GET requests, etc ...) ?
Good luck, it's a good job that will surely help the community
No, UDP is not implemented yet and I'm working on client-side TCP now (server-side works with some limitations). My roadmap is to finish TCP (even limited), implement UDP and then start to remove limitations and do optimizations. I have see nice, cheap (10$) & small boards with the chip:  Very nice! Where did you find it? I found one bigger for $10 at Sure Electronics: - http://www.sureelectronics.net/goods.php?id=1180And more two (one with the same size, other bigger), but for $17 at MDFLY: - http://www.mdfly.com/index.php?main_page=product_info&cPath=9_41&products_id=484- http://www.mdfly.com/index.php?main_page=product_info&cPath=9_41&products_id=109
|
|
|
|
|
Logged
|
|
|
|
|
Rio de Janeiro, Brazil
Offline
Jr. Member
Karma: 0
Posts: 85
Software developer, free software activist
|
 |
« Reply #63 on: July 24, 2011, 11:42:37 pm » |
Wow, there are *a lot* of companies that assembles ENC28J60 modules. I really need to buy more modules to test compatibility! If do you know people at these companies and you think they can give me one board (free) for testing, please contact me via direct message! Actually, my library also have this limitation. I need to implement the calculation of TCP packet number so we can send more than one packet per connection. Now I can't do it because I'm working on TCP client-side (3-way handshake), but it is in the roadmap. 2. With your library if I only write this one line #include <SD.h> and make no other additions to the sketch the webserver example stops working (the board replies to pings but if i open the address in a browser it just keeps waiting). I assume the problem is a buffer overrun.
It looks like a memory issue (when you include SD library, it uses more RAM and ATMega can't store all the request info). Please try to do a light request, using wget or curl. Regarding this I have a few questions I will be thankful if you can help. Is it possible fill the buffer with chars and send the contents of the buffer to the client without closing the connection? To explain further : Read single chars from the file on sd card > fill the buffer with these chars > send the packet when the buffer is full > continue reading from file and begin filling buffer again > repeat till the whole file is sent.
If we can implement this, we can have fully functional web servers working off the arduino+enc28j60. Hoping you can help me with this. Bravo for the good work again !!
For now we can't do it. But, as I said, it is a known limitation and is planned to be removed soon. :-) Thanks for using and helping the project!
|
|
|
|
|
Logged
|
|
|
|
|
Rio de Janeiro, Brazil
Offline
Jr. Member
Karma: 0
Posts: 85
Software developer, free software activist
|
 |
« Reply #64 on: July 24, 2011, 11:45:51 pm » |
Can you ping the board? If yes, probably your browser is sending too much information in headers, so use a light HTTP client (like wget and curl) - I'll try to remove this limitation. The code from http://blog.thiseldo.co.uk/?p=344 works?
|
|
|
|
|
Logged
|
|
|
|
|
Rio de Janeiro, Brazil
Offline
Jr. Member
Karma: 0
Posts: 85
Software developer, free software activist
|
 |
« Reply #65 on: July 24, 2011, 11:49:18 pm » |
I tried WebServerSimple and it worked. I can ping my board and access it from a browser. But only for a while. After that I get the connection lost. No more ping or browser access.
Do you have any idea. I've been struggling for 3 days and nothing.
Hello Inacio, did you do any modifications in WebServerSimple example? Please try to use a lighty HTTP client such as wget and curl, do a lot of subsequent requests (without concurrency) and tell me if the sketch stopped to work (if yes, with how many requests using wget/curl).
|
|
|
|
|
Logged
|
|
|
|
|
Offline
Newbie
Karma: 0
Posts: 2
|
 |
« Reply #66 on: August 03, 2011, 01:13:03 pm » |
Thanks for working on this. I'm sure it will be a big help to the community.
I recently purchased one of the eBay EtherShields with the intention of using it in conjunction with the iPhone app Ardumote (which uses only UDP messaging), but once I started digging around trying to code anything using the supplied ENC28J60 library I realized it wasn't worth the effort and ordered an Arduino W5100 Ethernet Shield. With your efforts however, I'm sure I will find a use for my ENC28J60 based shield one day and many others will benefit from the lower cost ethersheild!
|
|
|
|
|
Logged
|
|
|
|
|
Offline
Newbie
Karma: 0
Posts: 2
|
 |
« Reply #67 on: August 06, 2011, 11:33:45 am » |
Has anyone experience with this library and the nanode ? ( http://wiki.hackspace.org.uk/wiki/Project:Nanode) I tried to edit the file enc28j60.c as follows : #define ENC28J60_CONTROL_CS 8 without any success.
|
|
|
|
|
Logged
|
|
|
|
|
London
Offline
Faraday Member
Karma: 6
Posts: 6226
Have fun!
|
 |
« Reply #68 on: August 06, 2011, 01:10:26 pm » |
it would be easier to help if you said what the error was.
did you change also change the following? #define SPI_SS 8
did the sketch compile and run with the default CS/SS pin?
|
|
|
|
|
Logged
|
|
|
|
|
Offline
Newbie
Karma: 0
Posts: 2
|
 |
« Reply #69 on: August 06, 2011, 05:24:52 pm » |
The sketch uploads without any problem. What happens is that the board does not respond to either a ping or a http request, even after modification of the SPI_SS constant.
|
|
|
|
|
Logged
|
|
|
|
|
Rio de Janeiro, Brazil
Offline
Jr. Member
Karma: 0
Posts: 85
Software developer, free software activist
|
 |
« Reply #70 on: August 07, 2011, 04:46:43 am » |
Where can I buy a nanode for testing?
|
|
|
|
|
Logged
|
|
|
|
|
Seattle, WA
Offline
God Member
Karma: 4
Posts: 673
|
 |
« Reply #71 on: August 07, 2011, 08:40:33 am » |
Where can I buy a nanode for testing?
Sent you a PM with details.
|
|
|
|
|
Logged
|
|
|
|
|
Sydney, Australia
Offline
Full Member
Karma: 3
Posts: 230
Arduino rocks
|
 |
« Reply #72 on: August 08, 2011, 05:35:24 pm » |
I have see nice, cheap (10$) & small boards with the chip:  Where did you find this for $10? Cheers,
|
|
|
|
|
Logged
|
Is life really that serious...??!
|
|
|
|
Atlanta, GA
Offline
Jr. Member
Karma: 0
Posts: 85
|
 |
« Reply #73 on: August 08, 2011, 06:19:19 pm » |
I see that the picture has an embedded name on it - I found an ebay listing with that pictures' users name with the same item the listing was buy it now for 15.95 + 6 shipping from hong kong.
|
|
|
|
|
Logged
|
|
|
|
|
Rio de Janeiro, Brazil
Offline
Jr. Member
Karma: 0
Posts: 85
Software developer, free software activist
|
 |
« Reply #74 on: August 08, 2011, 07:34:44 pm » |
I see that the picture has an embedded name on it - I found an ebay listing with that pictures' users name with the same item the listing was buy it now for 15.95 + 6 shipping from hong kong.
Can you supply the link, please?
|
|
|
|
|
Logged
|
|
|
|
|
|