Second try... (does not work either), starting to feel stupid by now :P
struct ip_addr ipaddr_local;
struct ip_addr ipmask_local;
struct ip_addr ipgate_local;
IP4_ADDR(&ipaddr_local, 192,168,100,30);
IP4_ADDR(&ipmask_local, 255,255,255,0);
IP4_ADDR(&ipgate_local, 192,168,100,1);
NetServer *net = NetServer::create(ipaddr_local, ipmask_local, ipgate_local);
But to no avail....
The readback still gives a wrong IP of 93.1.0.0
But in nerserver.cpp this shows up:
NetServer::NetServer(struct ip_addr ip, struct ip_addr nm, struct ip_addr gw)
....? am i misinterpreting the ip_addr structure or what ?
<search continues>
::EDIT:: EUREKA... see last post.
Hi,
I've looked around for hours now, and i give up.
What is the Static IP equivalent of this DHCP command:
I tried to look in the .h files, and tried this.
NetServer *net = NetServer::create( IPv4(192,168,100,31), //IP Address IPv4(255,255,255,0), //Netmask IPv4(192,168,100,31) //Gateway );But to no avail....
The readback gives an IP of 109.0.0.0
//Readback of IP ipaddr_local = net->getIPAddr(); lcd.printf("%c%c%c%c%c%cFlytimer ready.", CMD, LCLS, CMD, CurPos, Col1, Row1); lcd.printf("%c%c%c%cIP: %d.%d.%d.%d", CMD, CurPos, Col1, Row2,ip4_addr1(&ipaddr_local),ip4_addr2(&ipaddr_local),ip4_addr3(&ipaddr_local), ip4_addr4(&ipaddr_local));Anyone? Help? <whimpers>
Theo (nl)