DHCP for K60

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

DHCP for K60

1,310 Views
dnappier
Contributor I

I am working on a DHCP client with the K60 client. My hope is to run a telnet program on the router at my house.

 

I am having problems with retrieving the IP data using DHCP. I have tried both ways in the attached C file specifically the rtcs_init() function.

 

Do I need to place jumpers anywhere on the board? I have already adjusted the jumpers for clocking and sucessfully run the program on a static ip network.

 

Any suggestions?

0 Kudos
5 Replies

919 Views
Dekiru
Contributor IV

In MQX, there is a shell example where you can try various commands (\Freescale MQX 3.7\rtcs\examples\shell).

You should try that to confirm everything is ok before doing your own app.

 

With dhcp, you can try commands like:

shell> ipconfig 0 initEthernet device 0 initialization successful.shell> ipconfig dhcpBind via dhcp successful.shell> ipconfig staticip 192.168.1.10 255.255.255.0 192.168.1.1
Static ip bind successful.shell> ping 192.168.1.1
Pinging  [192.168.1.1]:Reply from 192.168.1.1: time<1msReply from 192.168.1.1: time<1msReply from 192.168.1.1: time<1msReply from 192.168.1.1: time<1ms

For ethernet apps, remember to configure the system to use clock from TWR-SER otherwise it will not work correctly (if you use clock from TWR-K60, it still may work but fail sometime)


Regards

 

 

0 Kudos

919 Views
dnappier
Contributor I

I ran the shell and it still did not work.

 

Any ideas?

0 Kudos

919 Views
dnappier
Contributor I

I wiresharked the DHCP packets with a hub and found that the k60 is sending out a DHCP Discovery packet/s but is not getting a response back. Is it possible that the packet is not formatted correctly? I tried it on multiple routers so I know it is now the router.

0 Kudos

919 Views
esaias_pech
Contributor I

Hi,

 

Were you able to fix this issue? I have encountered the same problem. I am running CW10.1 and MQX3.7 (I tried with MQX 3.8 as well)

0 Kudos

919 Views
dnappier
Contributor I

Yeah, when I had the issue I upgraded to 3.8 that fixed that problem

0 Kudos