I followed the tutorial on MCUoneclipse for using lwIP and FreeRTOS (Tutorial: lwip with FreeRTOS and the Freescale FRDM-K64F Board | MCU on Eclipse) and I manage to start the lwIP task and see the output on semihosting console.
Although, I was not getting any response on the ethernet (green led on RJ-45 socket did not lit), I checked and Rx ethernet event were never trigered and lwIP was not able to get IP from DHCP. I tried changing the cable and other ports on the router. I connected the board to my laptop and windows did not reconized that the cable was connected.
Anyone had a similar problem?
Thanks mark,
I uploaded the uTaskerV1.4.8_FRDM-K64F_LAN.bin binary through mbed bootloader. I was able to access terminal application from utasker and went to LAN configurations, it had 192.168.0.3 IP (wich was on my subnet domain) and the correct gateway. Nonetheless, LAN did not work, green led did not lit once, I could not access the WEB server, even after I enabled it. The strangest thing is that I had 00-00-00-00-00-00 for MAC address. Is this a sign for bad ethernet interface? I tried changing the phy register without success. The attached image has a screenshot from the utasker terminal
Hi
The MAC address defaults to 00-00-00-00-00-00 but you can program a value in the LAN menu using the (secret command)
MAC 00-00-00-01-02-03 (for example). This will be saved and the board resets, after which it uses the new/final MAC address.
My feeling is that you have either a HW problem with the board or else with the cable being used. Attached is a version which will also display the state of the connection as follows:
Initially the LAN cable is not connected:
LAN configuration =================== up go to main menu phy Dump PHY registers set_phy set_dhcp <enable/disable> DHCP set_ip_add Set IPV4 address set_ip_mask Set IP subnet mask set_ip_gway Set default gateway set_ip_dns Set default DNS set_eth_speed Set LAN speed (10/100/AUTO) show_config Show network configuration show_config_o Show original network configuration save Save configuration to FLASH validate Validate temporary config. in FLASH ping Ping test IP address arp -a Request ARP table arp -d Delete ARP table hosts List multicast host groups join [multicast] join group leave [host ID] leave group multi send test frame help Display menu specific help quit Leave command mode #phy Reg: 0x00 = 0x3100 Reg: 0x01 = 0x7849 Reg: 0x02 = 0x0022 Reg: 0x03 = 0x1560 Reg: 0x04 = 0x85e1 Reg: 0x05 = 0x0000 Reg: 0x06 = 0x0004 Reg: 0x07 = 0x2001 Reg: 0x08 = 0x0000 Reg: 0x15 = 0x0000 Reg: 0x1b = 0x0000 Reg: 0x1e = 0x0000 Reg: 0x1f = 0x8100 The cable is inserted here #Eth0 link-up 100 full-duplex phy Reg: 0x00 = 0x3100 Reg: 0x01 = 0x786d Reg: 0x02 = 0x0022 Reg: 0x03 = 0x1560 Reg: 0x04 = 0x85e1 Reg: 0x05 = 0x0080 Reg: 0x06 = 0x0004 Reg: 0x07 = 0x2001 Reg: 0x08 = 0x0000 Reg: 0x15 = 0x0000 Reg: 0x1b = 0x0000 Reg: 0x1e = 0x0116 Reg: 0x1f = 0x8100 show_config IPV4 address = 192.168.0.45 MAC address = 00-00-00-00-00-00 Subnet mask = 255.255.255.0 Default gateway = 192.168.0.1 DNS server = 192.168.0.1 LAN speed AUTO DHCP_SERVER - disabled
Notice that the PHY registers change content when the cable is inserted and the values that you show are those when there is no cable connected!
Regards
Mark
Tried changing the cable and register 0x01 did not change.
PHY seems to be working (did a little check on the datasheet), I checked the signs on the RJ-45 and did not find anything unusual.
I'll try to unsolder the connector and put a new one.