This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Tool/software:
Hello, i am trying to run Enet_TCP_ECHO SERVER example provided in examples with tivaware.
When i first run the program i realized it didn't work, because it got stuck reading the mac address which i have not programmed in.
So i removed the mac address reading part and added it manually.
pui8MACArray[0] = 0x70; pui8MACArray[1] = 0xFF; pui8MACArray[2] = 0x76; pui8MACArray[3] = 0x1F; pui8MACArray[4] = 0x83; pui8MACArray[5] = 0x79;
#define IPADDR(a,b,c,d) ((uint32_t)((a) | ((b) << 8) | ((c) << 16) | ((d) << 24))) #define STATIC_IP_ADDRESS IPADDR(168,168,1,100) #define NETMASK IPADDR(255,255,255,0) #define GATEWAY IPADDR(168,168,1,1) lwIPInit(g_ui32SysClock, pui8MACArray, STATIC_IP_ADDRESS, NETMASK, GATEWAY, IPADDR_USE_STATIC);
#define LWIP_AUTOIP 0
#define LWIP_DHCP 0
But currently it is still refusing connection.
Hi,
Have you tried to run your modified example on a LaunchPad? Does it work?
Have you tried the DHCP address? Does it work?
Why do you use 168.168.1.100 instead of 192.168.1.100? Could this be a problem? 192.168.0.0 – 192.168.255.255 is a valid range for private IP4 addresses. I'm not aware of a private address starting with 168. Are you sure this is the address you want to statically assign to your server?
yes the program itself reaches the main loop fine, its probably an issue with the lwip configuration.
no i did not, i want to use a static address for my project.
ill try changing it and see the results.
There are some Ethernet examples in this app note. TM4C129x Ethernet Applications for Lightweight IP (lwIP)
Thank you, this is gonna be a question about udpecho_client_lwip project
i have programmed the mac adress and see the output from uart (I am using it with DHCP configuration).
after a while it assigns itself an ip, but i cant ping the ip it gives me over uart.
also when i look at ipconfig it shows that the media is disconnected even though i can see the connection in Ethernet settings.
Media State . . . . . . . . . . . : Media disconnected
Connection-specific DNS Suffix . :
i have connected the Ethernet cable to my computer and the uart.
I am using the default configurations of the projects and it gives me an ip to connect.
Are there more steps involved with this process ?
If you are getting an auto IP such as 169.254.xxx.xxx then it means there is no DHCP server on the network to assign an IP address to you. The stack picks a auto IP for itself. You need to find out if you have a DHCP server on you network. You can talk to your IT support.