Did it ever work? Does yur browser work as expected? What have you done to troubleshoot?
I never tried it before, Did it with an android and an iphone(phones are not mine to test all day :frown:) , none opend up .I could see the header , but I think it has to do with the sizes not comming over right , everything is in px , and it sould be % to get it to always fit , So i am going to change those , gonna take some time .ill fix it later .
Ok I understand that part , but I dont understand where I am supose to add the code , is it in the main pub just before it goes in the loop. or in the multi socket server
I wanna name it px-100 as hostname , and the ip is currently set to 192.168.2.200.
is the snipet supose to look like this then ?
Or do I also have to change some values in the dns file ,
The hole idea was for it to get its ip and gateway automaticly assignd with dhcp to the wiznet ,so I can plug it in any network and get the px-100 hostname running the page.
But i need to be able to see the ip somewhere so I can know the ip on a given network , for it to be redirected in the modem for WWW connection. Other than that getting to the page by typing px-100 in any brouwser connected to the network sould bring up the page
I never tried it before, Did it with an android and an iphone(phones are not mine to test all day ) , none opend up .I could see the header , but I think it has to do with the sizes not comming over right , everything is in px , and it sould be % to get it to always fit , So i am going to change those , gonna take some time .ill fix it later .
My android phone pulled up the test graph no problem. You're right the HTML should be updated to accommodate smaller screen sizes or detect smart phones and send the appropriate HTML.
If the page is not rendering but the header is displayed in terminal, check for a timeout. The W5200 server might be timing out the request and closing the socket before completely the transaction. I've seen this symptom on slower networks and smart phones. There also could be error on the page. Troubleshoot accordingly.
Ok I understand that part , but I dont understand where I am supose to add the code , is it in the main pub just before it goes in the loop. or in the multi socket server
I wanna name it px-100 as hostname , and the ip is currently set to 192.168.2.200.
is the snipet supose to look like this then ?
Please see the demo code in post 3 for implementation. Also demo code is a DNS client not a DNS server. you must enter the IP address of the DNS server to resolve the domain.
Or do I also have to change some values in the dns file ,
The hole idea was for it to get its ip and gateway automaticly assignd with dhcp to the wiznet ,so I can plug it in any network and get the px-100 hostname running the page.
But i need to be able to see the ip somewhere so I can know the ip on a given network , for it to be redirected in the modem for WWW connection. Other than that getting to the page by typing px-100 in any brouwser connected to the network sould bring up the page
The DHCP demo in post 3 populates gateway, DNS, assigns IP, and registers a client name and displays the results to the terminal. In order to register a host name with DNS you must have a DNS server. Otherwise, use the NetBIOS protocol to broadcast client name/IP for name resolution on the local network. NetBIOS will not function across network boundaries.
If you have a DNS server then use the DHCP client to register with the server. You'll have to make some changes to the DHCP client.
I'm working on the DNS and NetBIOS registration. Feel free to jump in and help any time.
By the way, I coded basic authentication and will release the code in the very near future.
I'm working on the DNS and NetBIOS registration. Feel free to jump in and help any time.
He mike , Nice to hear that you are also working on the DNS server. And happy to help with the DNS netbios if I can be of some handy , 2 brains better than 1
Is it posted somewhere , or are you working alone . give me some homework :P
The netbios solution is just what I had in mind. a DNS server i dont have, and dont want to use (suposing it is a seperate device ).
The prop is supose to do it all , I know it can.
That the hostname is not accesable acros network boundaries is not a problem, Inside the local network its supose to be easy to get the page running with a simple name even without the .com extension ( so someone entering e.g. ¨controller¨ in there bouwser sould get the page . if you enter ¨controller.com¨ the brouwser probably would redirect you somehere you dont want to be , Thats why i dont even want the .com extension just a name )
,If it was accesable to the net , the name would have to be uniqe to get it working . anyway were on the same page to how to get it done,
I would have to be able to see the ip somewhere easaly in the bouwser orso when it all is finished , so I can use that ip to forward it in the modem to get it www connected (Plug & Play)
the DHCP demo ive noticed that it does it all , but theres where i din get get any result yet ,. that the DNSdemo is as client , also i noticed , but how to make it work :blank:
Let me know if I can help. struggeling with the same thing,
I was working on the buttons, managed to get them working making a POST ,propeller cating the post and setting a variable:= variable + 1
so the setpont and offset can be adjusted 1 count at a time , working nicee
now i want to make an input form also for when you want to increase or decrease more then 1 count at a time
giving you an input box whit the actual value , and that you can change it
letting the propeler get the variable inside the post , and using it to set as the new setpoint , is kinda the new chalage , and the small popup form orso
after that I thout i would return to the login form . But I hear you made one with come basic authentification
ive spend 2 nights reading about login forms , alot with php ,mysql andso , but I thik the basic authenification encripted is good enoug for it . if the name and password get scrambled up in the link is more than enoug . Ket ne know when you release that piece, Gotta love that
So i found some Nice Buttons Adopted them into my script . And added them into the html file in my dat section
[HTML]<div id='interface-buttons3'>
<p id='Set_point'>
<a onclick="Setpointmin()" class='a_demo_two'>-</a>
<a onclick="SetpointVar()" class='a_demo_two'>Setpoint</a>
<a onclick="Setpointplus()" class='a_demo_two'>+</a></p>
</div> [/HTML]
When clicking the buttons there are 2 different buttons . left+right and the middle one
button setpointmin and setpointplus (l+r), simply doe a post with the same name to the server with there name when click on
[HTML]function Setpointplus()
{
var xmlhttp;
if (window.XMLHttpRequest)
{// code for IE7+, Firefox, Chrome, Opera, Safari
xmlhttp=new XMLHttpRequest();
}
else
{// code for IE6, IE5
xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
}
@@ UPDATE , I found out that the propeller still was sending out the full index page when i made a post to the server( pressing button on page), thats the default setting orso . anyway .
a return statement was enough to stop it easyfix
Works Fine , Ever wanted A button to talk to the propeller , This is How:p
Now The Middle Button , its A diferent story
This Buttons , Pops up a prompt box , Asking you to put in some text.
So Far So Good
[HTML]
function SetpointVar()
{
var x;
var name=prompt("Set Manual Setpoint","Setpoint");
if (name!=null)
{
var xmlhttp;
if (window.XMLHttpRequest)
{// code for IE7+, Firefox, Chrome, Opera, Safari
xmlhttp=new XMLHttpRequest();
}
else
{// code for IE6, IE5
xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
}
xmlhttp.open("POST","setvar"+ name,true);
xmlhttp.send();
}
}
[/HTML]
Box pops out on click , you can enter a value , and if you click ok setvar+input would get attached together and send out to the host with a xmlhttp Post , just like the 2 other buttons .
[HTML]Request URL:http://192.168.2.200:8080/setvar53
Request Method:POST
Status Code:200 OK
Request Headersview source
Accept:*/*
Accept-Charset:ISO-8859-1,utf-8;q=0.7,*;q=0.3
Accept-Encoding:gzip,deflate,sdch
Accept-Language:nl-NL,nl;q=0.8,en-US;q=0.6,en;q=0.4
Connection:keep-alive
Content-Length:0
Host:192.168.2.200:8080
Origin:http://192.168.2.200:8080
Referer:http://192.168.2.200:8080/
User-Agent:Mozilla/5.0 (X11; Linux i686) AppleWebKit/537.4 (KHTML, like Gecko) Chrome/22.0.1229.79 Safari/537.4
Response Headersview source
Content-Type:text/html[/HTML]
How to make the propeller extract the input behind the setvar that gets posted , There is were I met Mister Brick Wall till now ,
knowing, the input can be diferent at every submit ,
Tring to understand what it means for me , think it my be causing why i cant make the nicly running dhcp demo , just run the multisocketserver after that .
thout you wanna know about these sheets , found the on the Wiznet page today published 13-9-2012.
Have you seen these newly published errata sheets ???
Tring to understand what it means for me , think it my be causing why i cant make the nicly running dhcp demo , just run the multisocketserver after that .
thout you wanna know about these sheets , found the on the Wiznet page today published 13-9-2012.
Any Advice ?
I'm not sure what kind of problem you are having. I'm guessing the DHCP object works but you are having a issues integrating the object in your project. Can you be more specific? Does the DHCP demo function as expected? D.P. verified the demos were working on his network.
He mike, the DHCP demo works fine , its when its finnished and you see the assined ip etc , i wanted to add the multisocketserver loop , but when i do just that , the instance the init socket starts , in the serial terminal all the code gets scrambled up .Imm bugging my way around it now , hoping to get it working .
Ill chek the basic authentication soon , Nice to hear mike ,
without your work on the wiznet . it wouldent be the same .
Thankss
The moment the init socket starts , all the code in the terminal get mixed up
ive tried to reset the initialization values but with no succes , any idea what is doing this Mike ??
I sounds like you have created a bug. I simply copied the DHCP initialization from the TcpSocketClientDemoDhcpDns.spin example from post 3 and pasted it in the HtmlGraphright below PST.Start. It just worked. The DHCP object is like a special socket that does all the work.
Mike i have to admit that your right again , when looking closer , I have set both the ip address and the gateway to 0,0,0,0, in the wiznet object ,
When i used a pre-set ip it didn't seem to matter what values were in the wiznet object , before. didi some weird stuff , when i changed it to 0,0,0,0 if worked fine again . anyway
I took a fresh copy of the code , and it works like a charm indeed, I think ill never find that bug so i just replaced it thinking it was the ip adres changed
anyway , its working thanks man
question
is there a way you can call the host without the :8080 behind the ip or hostname ?? so ¨ propnet_5200 ¨ in place of ¨ propnet_5200:8080 ¨
.
running bit low on time for the moment . ill release my work when im done putting it all together , whit a nice page
Mike i have to admit that your right again , when looking closer , I have set both the ip address and the gateway to 0,0,0,0, in the wiznet object ,
When i used a pre-set ip it didn't seem to matter what values were in the wiznet object , before. didi some weird stuff , when i changed it to 0,0,0,0 if worked fine again . anyway
I took a fresh copy of the code , and it works like a charm indeed, I think ill never find that bug so i just replaced it thinking it was the ip adres changed
anyway , its working thanks man
question
is there a way you can call the host without the :8080 behind the ip or hostname ?? so ¨ propnet_5200 ¨ in place of ¨ propnet_5200:8080 ¨
.
running bit low on time for the moment . ill release my work when im done putting it all together , whit a nice page
igor
Now mike , it did seem to matter or so after all . I got it working the first time all right ,
But now I am getting that work one time/don't work allot a time syndrome I have had earlier . So im still whit the same not working sample , dont understand whats afecting it.
the Multisocket server allone works every single time , cant even get the thing working again strange ,
How can I hold my pin 8 high trouout all the running cogs , now its just the firts cog , just to make sure its not that bothering me ,
because its like , 30/70 work /not work
or is it something else , stranje that you dont encounter any of those , i took a fresh copy of all the driver objects. still the same
I did a mod , enterd a reboot statment , for it to reboot when it gets the error ,
mostly it reboots 1 time , for the second time it gets the ip set , some times it reboots 3 or 4 time before succes
Error 1 is a Discover error. It means that the Discover request was made but an Offer was not returned. This can be due to a timeout or configuration. In the DHCP object there is a DELAY constant. The Delay is in milliseconds. The constants are in the Dhcp.spin object.
Mike , how can I now if i am close enough with the timing ,
my internet provider modem works with about 450 500 delay , after about 2 or 3 resets it gets the right ip
I went testing it on another wireless network modem that I have , Linksys(wrt54GC ver 4.0)
with this modem it takes ages , so when i leave it and forget about it it gets the ip set about the 10 20 reboot time
I have changed the delay in steps form 100 till 1000, doenst seem to make any difference
dont know whats a good value ,
what are the other settings that can affect this behavior
From what you have told me, it sounds like the Discover -> Offer request does not return consistently or the Offer packet is not an expected format.
I updated the socket object to better control timeout values. Socket.Available handles an initial request a little differently than when data is being transferred. The default behavior is to loop 10,000 times waiting for an initial response. If the loop expires Socket.Available returns a -1. I added two delays to the Socket.Available; one for the initial one for data transfer. You can find the delay values in the Socket object header.
TIMEOUT = 10000' Number of loops to execute before issuing a timeout
INIT_DELAY = 1' Amount of time (ms) to wait in each timeout loop
TRANS_DELAY = 0' Milliseconds to wait between receiving data blocks
Try updating the INIT_DELAY from 1 to 2 and so on. If that helps then we know it's something to do with the initial response. If it does not work then I'll have to add some debug code to grab the some data. It could be that the Offer packet format is not expected.
From what you have told me, it sounds like the Discover -> Offer request does not return consistently or the Offer packet is not an expected format.
I updated the socket object to better control timeout values. Socket.Available handles an initial request a little differently than when data is being transferred. The default behavior is to loop 10,000 times waiting for an initial response. If the loop expires Socket.Available returns a -1. I added two delays to the Socket.Available; one for the initial one for data transfer. You can find the delay values in the Socket object header.
TIMEOUT = 10000' Number of loops to execute before issuing a timeout
INIT_DELAY = 1' Amount of time (ms) to wait in each timeout loop
TRANS_DELAY = 0' Milliseconds to wait between receiving data blocks
Try updating the INIT_DELAY from 1 to 2 and so on. If that helps then we know it's something to do with the initial response. If it does not work then I'll have to add some debug code to grab the some data. It could be that the Offer packet format is not expected.
Mike i have tryied it with the both modems , changing the INIT_DELAY doesnt seem to make any differace in how it reacts .
connection with my ISP modem succeds with about 2 to 4 reboots , rarly it does connect the first time
with the linksys modem , the proble looks to be the same *** before , when it reboots coutles times eventually it gets the ip . but sure this is not how its supose to work
think it wil be the second solution u where talking about may solve the problem, with the some data. Your magic
Sorry, my fault. Please download Socket.Spin from the code repository and try again. Source Code
FYI, I removed all default values from the objects and updated the demos.
Done that , but I think Im missing something in the first part , or not ??
because its not giving any response at all with the new codes . with any of the 2 network modems , strange
You are right the code does not work. It returns a discover error. Not sure why.
Load the attached code and see if it works.
Negative Mike ,
Still no sign of working , getting error code 1
eee . tje pins in the w5200 object
yes I have changed them to my configuration
SPI_MOSI = 4' SPI master out serial in to slave
SPI_SCK = 5' SPI clock from master to all slaves
SPI_CS = 6' SPI chip select (active low)
SPI_MISO = 7' SPI master in serial out from slave
when you say it works fine , you mean your demo , or the one i just archived for u ??
the one you just attached is not working ,ill try a full system restart in the meantime
Verry stange i find , but it still the same,
I have made sure the pins are correct. used a fresh copy of the source the one you post last .
put the
wiz.start(6, 5, 4, 7)
still getting the same #1 error. Not getting any results on nether network modems
The same code work in my environment. That error message means that the router is not returning an Offer packet. Try restarting your router. Also execute the DhcpDemo and post the packet results. It could be an unexpected packet format.
I'm going to be away from my desk for a few hours.
I see that there is a different ip used with the remote ip a couple of times , sometimes 0.0.0.0. sometimes 255.255.255.255 sometimes 255.255.255.0 and sometimes 192.168.2.254
the seems to be no relation with the ip and it beeing set or not , because at all ip somethimes it gets set correct , otrher times i get a discovery error
but my best guess is that thatś why it doenst connect every time , because the ip is different every time I restart it
Comments
Ok I understand that part , but I dont understand where I am supose to add the code , is it in the main pub just before it goes in the loop. or in the multi socket server
I wanna name it px-100 as hostname , and the ip is currently set to 192.168.2.200.
is the snipet supose to look like this then ?
pst.str(string("Resolve domain IP", CR)) dns.Init(@buff, 6) dns.SetDnsServerIp(192, 168, 2, 200) ptr := dns.ResolveDomain(string("px-100"))
Or do I also have to change some values in the dns file ,The hole idea was for it to get its ip and gateway automaticly assignd with dhcp to the wiznet ,so I can plug it in any network and get the px-100 hostname running the page.
But i need to be able to see the ip somewhere so I can know the ip on a given network , for it to be redirected in the modem for WWW connection. Other than that getting to the page by typing px-100 in any brouwser connected to the network sould bring up the page
But im struggeling with the implemintation.
Ill post it later
If the page is not rendering but the header is displayed in terminal, check for a timeout. The W5200 server might be timing out the request and closing the socket before completely the transaction. I've seen this symptom on slower networks and smart phones. There also could be error on the page. Troubleshoot accordingly.
Please see the demo code in post 3 for implementation. Also demo code is a DNS client not a DNS server. you must enter the IP address of the DNS server to resolve the domain.
The DHCP demo in post 3 populates gateway, DNS, assigns IP, and registers a client name and displays the results to the terminal. In order to register a host name with DNS you must have a DNS server. Otherwise, use the NetBIOS protocol to broadcast client name/IP for name resolution on the local network. NetBIOS will not function across network boundaries.
If you have a DNS server then use the DHCP client to register with the server. You'll have to make some changes to the DHCP client.
I'm working on the DNS and NetBIOS registration. Feel free to jump in and help any time.
By the way, I coded basic authentication and will release the code in the very near future.
He mike , Nice to hear that you are also working on the DNS server. And happy to help with the DNS netbios if I can be of some handy , 2 brains better than 1
Is it posted somewhere , or are you working alone . give me some homework :P
The netbios solution is just what I had in mind. a DNS server i dont have, and dont want to use (suposing it is a seperate device ).
The prop is supose to do it all , I know it can.
That the hostname is not accesable acros network boundaries is not a problem, Inside the local network its supose to be easy to get the page running with a simple name even without the .com extension ( so someone entering e.g. ¨controller¨ in there bouwser sould get the page . if you enter ¨controller.com¨ the brouwser probably would redirect you somehere you dont want to be , Thats why i dont even want the .com extension just a name )
,If it was accesable to the net , the name would have to be uniqe to get it working . anyway were on the same page to how to get it done,
I would have to be able to see the ip somewhere easaly in the bouwser orso when it all is finished , so I can use that ip to forward it in the modem to get it www connected (Plug & Play)
the DHCP demo ive noticed that it does it all , but theres where i din get get any result yet ,. that the DNSdemo is as client , also i noticed , but how to make it work :blank:
Let me know if I can help. struggeling with the same thing,
I was working on the buttons, managed to get them working making a POST ,propeller cating the post and setting a variable:= variable + 1
so the setpont and offset can be adjusted 1 count at a time , working nicee
now i want to make an input form also for when you want to increase or decrease more then 1 count at a time
giving you an input box whit the actual value , and that you can change it
letting the propeler get the variable inside the post , and using it to set as the new setpoint , is kinda the new chalage , and the small popup form orso
after that I thout i would return to the login form .
ive spend 2 nights reading about login forms , alot with php ,mysql andso , but I thik the basic authenification encripted is good enoug for it . if the name and password get scrambled up in the link is more than enoug . Ket ne know when you release that piece, Gotta love that
let me know
So i found some Nice Buttons Adopted them into my script . And added them into the html file in my dat section
[HTML]<div id='interface-buttons3'>
<p id='Set_point'>
<a onclick="Setpointmin()" class='a_demo_two'>-</a>
<a onclick="SetpointVar()" class='a_demo_two'>Setpoint</a>
<a onclick="Setpointplus()" class='a_demo_two'>+</a></p>
</div> [/HTML]
When clicking the buttons there are 2 different buttons . left+right and the middle one
button setpointmin and setpointplus (l+r), simply doe a post with the same name to the server with there name when click on
[HTML]function Setpointplus()
{
var xmlhttp;
if (window.XMLHttpRequest)
{// code for IE7+, Firefox, Chrome, Opera, Safari
xmlhttp=new XMLHttpRequest();
}
else
{// code for IE6, IE5
xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
}
xmlhttp.open("POST","setpointplus",true);
xmlhttp.send();
}[/HTML]
This was enough Because at the Server side in the ParseResourse method we are able to detect the post by its name
PUB ParseResource(header) | ptr, value, i, done, j ptr := header i := 0 done := false repeat until IsEndOfLine(byte[ptr]) if(IsToken(byte[ptr])) byte[ptr] := 0 resPtr[i++] := ++ptr else ++ptr if(ptr - header > 500) pst.str(string(CR, "+++++++++++++++[ERROR]++++++++++++++",CR)) return @index resPtr[0] := header repeat j from 0 to i-1 pst.str(string("ID")) pst.dec(j) pst.char($20) pst.str(resPtr[j]) pst.char(CR) repeat j from 0 to i-1 if(strcomp(resPtr[j], string("HTTP"))) return @index if(strcomp(resPtr[j], string("halo"))) return @halo if(strcomp(resPtr[j], string("xmltemp"))) value := GetTemp Settemp(tempc3,@temperature) Setlv(lv3,@lvlv) Settemp(tempmax,@t_max) Settemp(tempmin,@t_min) Setlv(lvmax,@lv_max) Setlv(lvmin,@lv_min) Setlv(setpoint,@Set_p) Setlv(offset,@off_s) return @xml if(strcomp(resPtr[j], string("setpointplus"))) setpointplus return if(strcomp(resPtr[j], string("setpointmin"))) setpointmin return if(strcomp(resPtr[j], string("offsetplus"))) offsetplus return if(strcomp(resPtr[j], string("offsetmin"))) offsetmin return
@@ UPDATE , I found out that the propeller still was sending out the full index page when i made a post to the server( pressing button on page), thats the default setting orso . anyway .
a return statement was enough to stop it
if(strcomp(resPtr[j], string("setpointplus")))
setpointplus
return
When it get detected , it runs the command to increase/decrease the setpoint
PUB setpointplus if setpoint < 99 Setpoint:= Setpoint + 1 return
Works Fine , Ever wanted A button to talk to the propeller , This is How:p
Now The Middle Button , its A diferent story
This Buttons , Pops up a prompt box , Asking you to put in some text.
So Far So Good
[HTML]
function SetpointVar()
{
var x;
var name=prompt("Set Manual Setpoint","Setpoint");
if (name!=null)
{
var xmlhttp;
if (window.XMLHttpRequest)
{// code for IE7+, Firefox, Chrome, Opera, Safari
xmlhttp=new XMLHttpRequest();
}
else
{// code for IE6, IE5
xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
}
xmlhttp.open("POST","setvar"+ name,true);
xmlhttp.send();
}
}
[/HTML]
Box pops out on click , you can enter a value , and if you click ok setvar+input would get attached together and send out to the host with a xmlhttp Post , just like the 2 other buttons .
[HTML]Request URL:http://192.168.2.200:8080/setvar53
Request Method:POST
Status Code:200 OK
Request Headersview source
Accept:*/*
Accept-Charset:ISO-8859-1,utf-8;q=0.7,*;q=0.3
Accept-Encoding:gzip,deflate,sdch
Accept-Language:nl-NL,nl;q=0.8,en-US;q=0.6,en;q=0.4
Connection:keep-alive
Content-Length:0
Host:192.168.2.200:8080
Origin:http://192.168.2.200:8080
Referer:http://192.168.2.200:8080/
User-Agent:Mozilla/5.0 (X11; Linux i686) AppleWebKit/537.4 (KHTML, like Gecko) Chrome/22.0.1229.79 Safari/537.4
Response Headersview source
Content-Type:text/html[/HTML]
How to make the propeller extract the input behind the setvar that gets posted , There is were I met Mister Brick Wall till now ,
knowing, the input can be diferent at every submit ,
if(strcomp(resPtr[j], string("setpointplus"))) setpointplus
is not going to work , neither making one for every possible VALID combination , and what if someone enterd there name. what wil happen , nothing ?Hoping you could point me in the way
For everybody else Reading ,Hopfully you can get your button running Now
Have you seen these newly published errata sheets ???
Tring to understand what it means for me , think it my be causing why i cant make the nicly running dhcp demo , just run the multisocketserver after that .
thout you wanna know about these sheets , found the on the Wiznet page today published 13-9-2012.
Any Advice ?
I'm not sure what kind of problem you are having. I'm guessing the DHCP object works but you are having a issues integrating the object in your project. Can you be more specific? Does the DHCP demo function as expected? D.P. verified the demos were working on his network.
I added source code for basic authentication. You can find the source in the Roll Your Own Basic Authentication thread.
Ill chek the basic authentication soon , Nice to hear mike ,
without your work on the wiznet . it wouldent be the same .
Thankss
PUB Init|i buffPtr := @buff pst.Start(115_200) pause(500) pst.str(string("Initialize", CR)) CreateTransactionId 'Wiz Mac and Ip wiz.Init wiz.SetIp(192, 168, 1, 107) wiz.SetMac($00, $08, $DC, $16, $F8, $01) 'DHCP Port, Mac and Ip sock.Init(0, UDP, 68) 'Broadcast to port 67 sock.RemoteIp(255, 255, 255, 255) sock.RemotePort(67) 'DHCP Process Discover Offer Request if(Ack) pst.str(string("IP Assigned.......")) else pst.str(string("DHCP Failed", CR)) PrintIp(wiz.GetIp) pst.str(string("DNS...............")) PrintIp(wiz.GetDns) pst.str(string("DHCP Server.......")) printIp(wiz.GetDhcpServerIp) pst.str(string("Router IP.........")) printIp(wiz.GetRouter) pst.char(CR) sock.Close pst.str(string("**************************************************")) pst.char(CR) wiz.SetMac($00, $08, $DC, $16, $F8, $01) pst.str(string("IP ingesteld .............")) printIp(wiz.Setip2) pst.str(string("Gateway ingesteld .............")) printIp(wiz.Setip3) pst.str(string("subnet ingesteld .............")) printIp(wiz.Setip4) repeat pst.str(string("Initialize Sockets",CR)) repeat i from 0 to SOCKETS-1 sock[i].Init(i, TCP, 8080) OpenListeners StartListners pst.str(string("Start Socket server",CR)) \MultiSocketServer pst.str(string("I blew up!")) pause(5000)
PUB SetIp2 getip Write(SOURCE_IP0, @_ip, 4 ) return @_ip PUB SetIp3 serverip Write(GATEWAY0, @_dhcpServer, 4) return @_dhcpServer PUB Setip4 subnetip Write(SUBNET_MASK0, @_subnetmask, 4) return @_subnetmask PUB GetIp return @_ip PUB serverip return @_dhcpServer PUB subnetip return @_subnetmask
The moment the init socket starts , all the code in the terminal get mixed up
ive tried to reset the initialization values but with no succes , any idea what is doing this Mike ??
OBJ pst : "Parallax Serial Terminal" wiz : "W5200.spin" sock[SOCKETS] : "Socket.spin" dhcp : "Dhcp" PUB Main | i, page, dnsServer pst.Start(115_200) pause(500) pst.str(string("Initialize W5200", CR)) wiz.Init wiz.SetIp(192, 168, 1, 107) wiz.SetMac($00, $08, $DC, $16, $F8, $01) pst.str(string("Getting network paramters", CR)) dhcp.Init(@buff, 7) pst.str(string("Requesting IP.....")) PrintIp(dhcp.DoDhcp) pst.str(string("DNS...............")) dnsServer := wiz.GetDns PrintIp(wiz.GetDns) pst.str(string("DHCP Server.......")) printIp(wiz.GetDhcpServerIp) pst.str(string("Router IP.........")) printIp(wiz.GetRouter) pst.char(CR) repeat pst.str(string("Initialize Sockets",CR)) repeat i from 0 to SOCKETS-1 sock[i].Init(i, TCP, 8080) OpenListeners StartListners pst.str(string("Start Socket server",CR)) \MultiSocketServer pst.str(string("I blew up!")) pause(5000)
When i used a pre-set ip it didn't seem to matter what values were in the wiznet object , before. didi some weird stuff , when i changed it to 0,0,0,0 if worked fine again . anyway
I took a fresh copy of the code , and it works like a charm indeed, I think ill never find that bug so i just replaced it
anyway , its working thanks man
question
is there a way you can call the host without the :8080 behind the ip or hostname ?? so ¨ propnet_5200 ¨ in place of ¨ propnet_5200:8080 ¨
.
running bit low on time for the moment . ill release my work when im done putting it all together , whit a nice page
igor
But now I am getting that work one time/don't work allot a time syndrome I have had earlier . So im still whit the same not working sample , dont understand whats afecting it.
the Multisocket server allone works every single time , cant even get the thing working again strange ,
I made a few validation checks to the DHCP library. So get the latest from post 3.
This init code will display any errors with the DHCP library.
OBJ pst : "Parallax Serial Terminal" wiz : "W5200.spin" sock[SOCKETS] : "Socket.spin" dhcp : "Dhcp" PUB Main | i, page, dnsServer pst.Start(115_200) pause(500) pst.str(string("Initialize W5200", CR)) wiz.Init 'wiz.SetIp(192, 168, 1, 107) wiz.SetIp(0, 0, 0, 0) wiz.SetMac($00, $08, $DC, $16, $F8, $01) pst.str(string("Getting network paramters", CR)) dhcp.Init(@buff, 7) pst.str(string("Requesting IP.....")) ifnot(dhcp.DoDhcp) pst.str(string(CR, "Error Code: ")) pst.dec(dhcp.GetErrorCode) pst.char(CR) pst.str(dhcp.GetErrorMessage) pst.char(CR) return else PrintIp(dhcp.GetIp) pst.str(string("DNS...............")) dnsServer := wiz.GetDns PrintIp(wiz.GetDns) pst.str(string("DHCP Server.......")) printIp(wiz.GetDhcpServerIp) pst.str(string("Router IP.........")) printIp(wiz.GetRouter) pst.char(CR) repeat pst.str(string("Initialize Sockets",CR)) repeat i from 0 to SOCKETS-1 sock[i].Init(i, TCP, 8080)
Use port 80 which is assumed for HTTP traffic. However, this might affect your ability to hit the web server from the internet. My ISP blocks port 80.where do i find what the error codes mean ?
How can I hold my pin 8 high trouout all the running cogs , now its just the firts cog , just to make sure its not that bothering me ,
because its like , 30/70 work /not work
or is it something else , stranje that you dont encounter any of those , i took a fresh copy of all the driver objects. still the same
I did a mod , enterd a reboot statment , for it to reboot when it gets the error ,
mostly it reboots 1 time , for the second time it gets the ip set , some times it reboots 3 or 4 time before succes
pst.str(string("Getting network paramters", CR)) dhcp.Init(@buff, 7) pst.str(string("Requesting IP.....")) ifnot(dhcp.DoDhcp) pst.str(string(CR, "Error Code: ")) pst.dec(dhcp.GetErrorCode) pst.char(CR) pst.str(dhcp.GetErrorMessage) pst.char(CR) reboot else PrintIp(dhcp.GetIp
any idea ??
DELAY = 500
Try increasing and decreasing the delay.
my internet provider modem works with about 450 500 delay , after about 2 or 3 resets it gets the right ip
I went testing it on another wireless network modem that I have , Linksys(wrt54GC ver 4.0)
with this modem it takes ages , so when i leave it and forget about it it gets the ip set about the 10 20 reboot time
I have changed the delay in steps form 100 till 1000, doenst seem to make any difference
dont know whats a good value ,
what are the other settings that can affect this behavior
I updated the socket object to better control timeout values. Socket.Available handles an initial request a little differently than when data is being transferred. The default behavior is to loop 10,000 times waiting for an initial response. If the loop expires Socket.Available returns a -1. I added two delays to the Socket.Available; one for the initial one for data transfer. You can find the delay values in the Socket object header.
TIMEOUT = 10000 ' Number of loops to execute before issuing a timeout INIT_DELAY = 1 ' Amount of time (ms) to wait in each timeout loop TRANS_DELAY = 0 ' Milliseconds to wait between receiving data blocks
Try updating the INIT_DELAY from 1 to 2 and so on. If that helps then we know it's something to do with the initial response. If it does not work then I'll have to add some debug code to grab the some data. It could be that the Offer packet format is not expected.
Source code
http://code.google.com/p/propeller-w5200-driver/source/browse/trunk/#trunk%2F%20propeller-w5200-driver
Mike i have tryied it with the both modems , changing the INIT_DELAY doesnt seem to make any differace in how it reacts .
connection with my ISP modem succeds with about 2 to 4 reboots , rarly it does connect the first time
with the linksys modem , the proble looks to be the same *** before , when it reboots coutles times eventually it gets the ip . but sure this is not how its supose to work
think it wil be the second solution u where talking about may solve the problem, with the some data. Your magic
Source Code
FYI, I removed all default values from the objects and updated the demos.
Done that , but I think Im missing something in the first part , or not ??
because its not giving any response at all with the new codes . with any of the 2 network modems , strange
PUB Main | i, page, dnsServer setpoint := i2cObject.ReadLong(i2cSCL, EEPROMAddr, $7981) offset := i2cObject.ReadLong(i2cSCL, EEPROMAddr, $7977) dira[8]~~ outa[8]~~ cognew(tempcontrol,@stack1) cognew(controller,@stack2) pst.Start(115_200) pause(1000) pst.str(string("Initialize W5200", CR)) wiz.Init 'wiz.SetIp(192, 168, 1, 107) wiz.SetIp(0, 0, 0, 0) wiz.SetMac($00, $08, $DC, $16, $F8, $01) pst.str(string("Getting network paramters", CR)) dhcp.Init(@buff, 7) pst.str(string("Requesting IP.....")) ifnot(dhcp.DoDhcp) pst.str(string(CR, "Error Code: ")) pst.dec(dhcp.GetErrorCode) pst.char(CR) pst.str(dhcp.GetErrorMessage) pst.char(CR) reboot else PrintIp(dhcp.GetIp) pst.str(string("DNS...............")) dnsServer := wiz.GetDns PrintIp(wiz.GetDns) pst.str(string("DHCP Server.......")) printIp(wiz.GetDhcpServerIp) pst.str(string("Router IP.........")) printIp(wiz.GetRouter) pst.char(CR)
Mind taking a look at the complete code
IDE_Prop.zip
pst.str(string("Initialize W5200", CR)) wiz.Init wiz.SetMac($00, $08, $DC, $16, $F8, $01) pst.str(string("Getting network paramters", CR)) dhcp.Init(@buff, 7) pst.str(string("Requesting IP.....")) ifnot(dhcp.DoDhcp) pst.str(string(CR, "Error Code: ")) pst.dec(dhcp.GetErrorCode) pst.char(CR) pst.str(dhcp.GetErrorMessage) pst.char(CR) return else PrintIp(dhcp.GetIp) pst.str(string("DNS...............")) dnsServer := wiz.GetDns PrintIp(wiz.GetDns) pst.str(string("DHCP Server.......")) printIp(wiz.GetDhcpServerIp) pst.str(string("Router IP.........")) printIp(wiz.GetRouter) pst.char(CR)
Your source is missing basic_i2c_driver. I can't run the code.
sorry here are the missing drivers
Load the attached code and see if it works.
Negative Mike ,
Still no sign of working , getting error code 1
eee . tje pins in the w5200 object
yes I have changed them to my configuration
SPI_MOSI = 4 ' SPI master out serial in to slave SPI_SCK = 5 ' SPI clock from master to all slaves SPI_CS = 6 ' SPI chip select (active low) SPI_MISO = 7 ' SPI master in serial out from slave
when you say it works fine , you mean your demo , or the one i just archived for u ??
the one you just attached is not working ,ill try a full system restart in the meantime
PUB Main | bytesToRead, buffer, bytesSent, receiving, remoteIP, dnsServer, totalBytes receiving := true bytesToRead := 0 pst.Start(115_200) pause(500) pst.str(string("Initialize W5200", CR)) wiz.Start(3, 0, 1, 2) wiz.SetMac($00, $08, $DC, $16, $F8, $01)
I have made sure the pins are correct. used a fresh copy of the source the one you post last .
put the
wiz.start(6, 5, 4, 7)
still getting the same #1 error. Not getting any results on nether network modems
I'm going to be away from my desk for a few hours.
Ill post it up injust a sec
this one fails
Initialize Remote IP: 0.0.0.0 Send Discover ----------------------------------------------------- 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 0000 01 01 06 00 E9 6B DB 70 00 00 00 00 00 00 00 00 0010 00 00 00 00 00 00 00 00 00 00 00 00 00 08 DC 16 0020 F8 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0040 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0050 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0060 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0070 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0080 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0090 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00A0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00B0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00C0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00D0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00E0 00 00 00 00 00 00 00 00 00 00 00 00 63 82 53 63 00F0 35 01 01 32 04 00 00 00 00 37 04 01 03 06 2A 0C 0100 0B 50 72 6F 70 4E 65 74 35 32 30 30 FF 00 00 00 0110 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0120 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0130 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0140 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0150 00 00 00 00 00 00 00 Start: 160 Len: 342 ----------------------------------------------------- Send Bytes.......342 Bytes to Read....-1 Error: Discover
another one failingInitialize Remote IP: 192.168.2.254 Send Discover ----------------------------------------------------- 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 0000 01 01 06 00 F0 09 5D 1E 00 00 00 00 00 00 00 00 0010 00 00 00 00 00 00 00 00 00 00 00 00 00 08 DC 16 0020 F8 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0040 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0050 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0060 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0070 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0080 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0090 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00A0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00B0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00C0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00D0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00E0 00 00 00 00 00 00 00 00 00 00 00 00 63 82 53 63 00F0 35 01 01 32 04 00 00 00 00 37 04 01 03 06 2A 0C 0100 0B 50 72 6F 70 4E 65 74 35 32 30 30 FF 00 00 00 0110 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0120 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0130 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0140 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0150 00 00 00 00 00 00 00 Start: 160 Len: 342 ----------------------------------------------------- Send Bytes.......342 Bytes to Read....-1 Error: Discover
ANd another one , every time a diferent remote ip . I just did a restart nothing more , still its different every time
Initialize Remote IP: 255.255.255.255 Send Discover ----------------------------------------------------- 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 0000 01 01 06 00 07 DA 7E 5A 00 00 00 00 00 00 00 00 0010 00 00 00 00 00 00 00 00 00 00 00 00 00 08 DC 16 0020 F8 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0040 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0050 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0060 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0070 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0080 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0090 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00A0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00B0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00C0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00D0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00E0 00 00 00 00 00 00 00 00 00 00 00 00 63 82 53 63 00F0 35 01 01 32 04 00 00 00 00 37 04 01 03 06 2A 0C 0100 0B 50 72 6F 70 4E 65 74 35 32 30 30 FF 00 00 00 0110 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0120 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0130 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0140 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0150 00 00 00 00 00 00 00 Start: 160 Len: 342 ----------------------------------------------------- Send Bytes.......342 Bytes to Read....-1 Error: Discover
Thisone succeds
Initialize Remote IP: 0.0.0.0 Send Discover ----------------------------------------------------- 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 0000 01 01 06 00 9E 8C B0 C9 00 00 00 00 00 00 00 00 0010 00 00 00 00 00 00 00 00 00 00 00 00 00 08 DC 16 0020 F8 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0040 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0050 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0060 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0070 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0080 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0090 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00A0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00B0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00C0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00D0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00E0 00 00 00 00 00 00 00 00 00 00 00 00 63 82 53 63 00F0 35 01 01 32 04 00 00 00 00 37 04 01 03 06 2A 0C 0100 0B 50 72 6F 70 4E 65 74 35 32 30 30 FF 00 00 00 0110 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0120 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0130 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0140 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0150 00 00 00 00 00 00 00 Start: 160 Len: 342 ----------------------------------------------------- Send Bytes.......342 Bytes to Read....556 Message from: 192.168.2.254:67 (548) ----------------------------------------------------- 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 0000 02 01 06 00 9E 8C B0 C9 00 00 00 00 00 00 00 00 0010 C0 A8 02 02 00 00 00 00 00 00 00 00 00 08 DC 16 0020 F8 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0040 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0050 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0060 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0070 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0080 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0090 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00A0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00B0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00C0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00D0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00E0 00 00 00 00 00 00 00 00 00 00 00 00 63 82 53 63 00F0 35 01 02 01 04 FF FF FF 00 03 04 C0 A8 02 FE 06 0100 04 C0 A8 02 FE 0F 03 6C 61 6E 36 04 C0 A8 02 FE 0110 33 04 00 01 51 80 FF 00 00 00 00 00 00 00 00 00 0120 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0130 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0140 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0150 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0160 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0170 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0180 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0190 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01A0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01B0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01C0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01D0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01E0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01F0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0200 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0210 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0220 00 00 00 00 00 Start: 168 Len: 548 ----------------------------------------------------- Receive Offer Assigned IP: 192.168.2.2 Gateway IP: 0.0.0.0 Send Request ----------------------------------------------------- 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 0000 01 01 06 00 9E 8C B0 C9 00 00 00 00 00 00 00 00 0010 00 00 00 00 C0 A8 02 FE 00 00 00 00 00 08 DC 16 0020 F8 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0040 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0050 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0060 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0070 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0080 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0090 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00A0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00B0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00C0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00D0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00E0 00 00 00 00 00 00 00 00 00 00 00 00 63 82 53 63 00F0 35 01 03 32 04 C0 A8 02 02 36 04 C0 A8 02 FE 0C 0100 0B 50 72 6F 70 4E 65 74 35 32 30 30 FF 00 00 00 0110 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0120 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0130 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0140 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0150 00 00 00 00 00 00 00 Start: 160 Len: 342 ----------------------------------------------------- Send Bytes.......342 Bytes to Read....556 Message from: 192.168.2.254:67 (548) ----------------------------------------------------- 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 0000 02 01 06 00 9E 8C B0 C9 00 00 00 00 00 00 00 00 0010 C0 A8 02 02 00 00 00 00 00 00 00 00 00 08 DC 16 0020 F8 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0040 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0050 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0060 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0070 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0080 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0090 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00A0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00B0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00C0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00D0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00E0 00 00 00 00 00 00 00 00 00 00 00 00 63 82 53 63 00F0 35 01 05 01 04 FF FF FF 00 03 04 C0 A8 02 FE 06 0100 04 C0 A8 02 FE 0F 03 6C 61 6E 36 04 C0 A8 02 FE 0110 33 04 00 01 51 80 FF 00 00 00 00 00 00 00 00 00 0120 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0130 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0140 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0150 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0160 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0170 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0180 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0190 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01A0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01B0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01C0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01D0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01E0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01F0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0200 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0210 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0220 00 00 00 00 00 Start: 168 Len: 548 ----------------------------------------------------- Receive Ack IP Assigned.......192.168.2.2 DNS...............192.168.2.254 DHCP Server.......192.168.2.254 Router IP.........192.168.2.254
This time it also succeeded wit a 255.255.255.255 as remote ip
Initialize Remote IP: 255.255.255.255 Send Discover ----------------------------------------------------- 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 0000 01 01 06 00 60 A3 21 31 00 00 00 00 00 00 00 00 0010 00 00 00 00 00 00 00 00 00 00 00 00 00 08 DC 16 0020 F8 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0040 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0050 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0060 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0070 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0080 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0090 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00A0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00B0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00C0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00D0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00E0 00 00 00 00 00 00 00 00 00 00 00 00 63 82 53 63 00F0 35 01 01 32 04 00 00 00 00 37 04 01 03 06 2A 0C 0100 0B 50 72 6F 70 4E 65 74 35 32 30 30 FF 00 00 00 0110 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0120 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0130 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0140 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0150 00 00 00 00 00 00 00 Start: 160 Len: 342 ----------------------------------------------------- Send Bytes.......342 Bytes to Read....556 Message from: 192.168.2.254:67 (548) ----------------------------------------------------- 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 0000 02 01 06 00 60 A3 21 31 00 00 00 00 00 00 00 00 0010 C0 A8 02 02 00 00 00 00 00 00 00 00 00 08 DC 16 0020 F8 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0040 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0050 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0060 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0070 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0080 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0090 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00A0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00B0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00C0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00D0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00E0 00 00 00 00 00 00 00 00 00 00 00 00 63 82 53 63 00F0 35 01 02 01 04 FF FF FF 00 03 04 C0 A8 02 FE 06 0100 04 C0 A8 02 FE 0F 03 6C 61 6E 36 04 C0 A8 02 FE 0110 33 04 00 01 51 80 FF 00 00 00 00 00 00 00 00 00 0120 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0130 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0140 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0150 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0160 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0170 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0180 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0190 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01A0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01B0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01C0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01D0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01E0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01F0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0200 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0210 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0220 00 00 00 00 00 Start: 168 Len: 548 ----------------------------------------------------- Receive Offer Assigned IP: 192.168.2.2 Gateway IP: 0.0.0.0 Send Request ----------------------------------------------------- 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 0000 01 01 06 00 60 A3 21 31 00 00 00 00 00 00 00 00 0010 00 00 00 00 C0 A8 02 FE 00 00 00 00 00 08 DC 16 0020 F8 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0040 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0050 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0060 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0070 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0080 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0090 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00A0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00B0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00C0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00D0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00E0 00 00 00 00 00 00 00 00 00 00 00 00 63 82 53 63 00F0 35 01 03 32 04 C0 A8 02 02 36 04 C0 A8 02 FE 0C 0100 0B 50 72 6F 70 4E 65 74 35 32 30 30 FF 00 00 00 0110 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0120 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0130 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0140 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0150 00 00 00 00 00 00 00 Start: 160 Len: 342 ----------------------------------------------------- Send Bytes.......342 Bytes to Read....556 Message from: 192.168.2.254:67 (548) ----------------------------------------------------- 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 0000 02 01 06 00 60 A3 21 31 00 00 00 00 00 00 00 00 0010 C0 A8 02 02 00 00 00 00 00 00 00 00 00 08 DC 16 0020 F8 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0040 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0050 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0060 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0070 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0080 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0090 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00A0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00B0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00C0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00D0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00E0 00 00 00 00 00 00 00 00 00 00 00 00 63 82 53 63 00F0 35 01 05 01 04 FF FF FF 00 03 04 C0 A8 02 FE 06 0100 04 C0 A8 02 FE 0F 03 6C 61 6E 36 04 C0 A8 02 FE 0110 33 04 00 01 51 80 FF 00 00 00 00 00 00 00 00 00 0120 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0130 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0140 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0150 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0160 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0170 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0180 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0190 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01A0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01B0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01C0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01D0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01E0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01F0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0200 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0210 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0220 00 00 00 00 00 Start: 168 Len: 548 ----------------------------------------------------- Receive Ack IP Assigned.......192.168.2.2 DNS...............192.168.2.254 DHCP Server.......192.168.2.254 Router IP.........192.168.2.254
Ok Mike,
I saw this
I see that there is a different ip used with the remote ip a couple of times , sometimes 0.0.0.0. sometimes 255.255.255.255 sometimes 255.255.255.0 and sometimes 192.168.2.254
the seems to be no relation with the ip and it beeing set or not , because at all ip somethimes it gets set correct , otrher times i get a discovery error
but my best guess is that thatś why it doenst connect every time , because the ip is different every time I restart it