I was trying to test the http_server and http_client applications with two different frdm_k64f boards.
The steps I have followed for http server is as below:
cd zephyr/samples/net/http_server
make clean;make pristine && make BOARD=frdm_k64f
cp /outdir/frdm_k64f/zephyr.bin /run/media/MBED/
The steps I have followed for http client is as below:
cd zephyr/samples/net/http_server
change the settings of below config as below in the prj.conf file
With the above settings I was expecting that the http_client and http_server applications will be executed successfully on two frdm_k64f boards. But I am getting failure as below even though the ping between server and client works perfectly fine.
at the server side on frdm_k64f console:
shell> select net
net> iface
Interface 0x20001020 (Ethernet)
===============================
Link addr : 00:04:9F:04:16:A2
MTU : 1500
IPv6 unicast addresses (max 2):
fe80::204:9fff:fe04:16a2 autoconf preferred infinite
2001:db8::1 manual preferred infinite
IPv6 multicast addresses (max 4):
ff02::1
ff02::1:ff04:16a2
ff02::1:ff00:1
IPv6 prefixes (max 2):
<none>
IPv6 hop limit : 64
IPv6 base reachable time : 30000
IPv6 reachable time : 6455
IPv6 retransmit timer : 0
IPv4 unicast addresses (max 1):
192.0.2.1 manual preferred infinite
IPv4 multicast addresses (max 1):
<none>
IPv4 gateway : 0.0.0.0
IPv4 netmask : 255.255.255.0
net> ping 192.0.2.12
Sent a ping to 192.0.2.12
Ping timeout
net> ping 192.0.2.2
Sent a ping to 192.0.2.2
Received echo reply from 192.0.2.2 to 192.0.2.1
net> [dev/eth_mcux] [INF] eth_mcux_phy_event: Link down
[dev/eth_mcux] [INF] eth_mcux_phy_event: Enabled 100M full-duplex mode.
net> ping 192.0.2.2
Sent a ping to 192.0.2.2
Ping timeout
net> [dev/eth_mcux] [DBG] eth_0_init: MAC 00:04:9f:55:2f:66
shell> [dev/eth_mcux] [INF] eth_mcux_phy_event: Enabled 100M full-duplex mode.
[dev/eth_mcux] [INF] eth_mcux_phy_event: Link down
[dev/eth_mcux] [INF] eth_mcux_phy_event: Enabled 100M full-duplex mode.
shell> select net
net> ping 192.0.2.2
Sent a ping to 192.0.2.2
Received echo reply from 192.0.2.2 to 192.0.2.1
net> http
Enable CONFIG_NET_DEBUG_HTTP_CONN and CONFIG_HTTP_SERVER to get HTTP server connection information
net> get
Unrecognized command: get
Type 'help' for list of available commands
net> help
help
allocs
app
conn
dns
http
iface
mem
nbr
ping
route
rpl
stacks
stats
tcp
Enter 'exit' to leave current module.
net> stacks
HTTPS [https_stack] stack size 8192/8192 bytes unused 5868 usage 2324/8192 (28 %)
RX [rx_stack] stack size 1500/1500 bytes unused 980 usage 520/1500 (34 %)
TX [tx_stack] stack size 1200/1200 bytes unused 1032 usage 168/1200 (14 %)
MGMT [mgmt_stack] stack size 512/512 bytes unused 376 usage 136/512 (26 %)
main [_main_stack] stack size 1024/1024 bytes unused 532 usage 492/1024 (48 %)
ISR [_interrupt_stack] stack size 2048/2048 bytes unused 1880 usage 168/2048 (8 %)
net>
at the client side on frdm_k64f console:
shell> select net
net> iface
Interface 0x200009e0 (Ethernet)
===============================
Link addr : 00:04:9F:EC:E2:F6
MTU : 1500
IPv4 unicast addresses (max 1):
192.0.2.2 manual preferred infinite
IPv4 multicast addresses (max 1):
<none>
IPv4 gateway : 0.0.0.0
IPv4 netmask : 255.255.255.0
net> [dev/eth_mcux] [DBG] eth_0_init: MAC 00:04:9f:fb:21:4a
shell> [dev/eth_mcux] [INF] eth_mcux_phy_event: Enabled 100M full-duplex mode.
[http-client] [ERR] do_sync_http_req: Cannot send GET request (-60)
[http-client] [INF] main: Done!
shell> select net
net> ping 192.0.2.1
Sent a ping to 192.0.2.1
Ping timeout
net> ping 192.0.2.1
Sent a ping to 192.0.2.1
Ping timeout
net> [dev/eth_mcux] [INF] eth_mcux_phy_event: Link down
[dev/eth_mcux] [INF] eth_mcux_phy_event: Enabled 100M full-duplex mode.
[dev/eth_mcux] [DBG] eth_0_init: MAC 00:04:9f:a9:4a:c2
shell> [dev/eth_mcux] [INF] eth_mcux_phy_event: Enabled 100M full-duplex mode.
[http-client] [ERR] do_sync_http_req: Cannot send GET request (-60)
[http-client] [INF] main: Done!
shell> select net
net> ping 192.0.2.1
Sent a ping to 192.0.2.1
Received echo reply from 192.0.2.1 to 192.0.2.2
net> stacks
RX [rx_stack] stack size 1500/1500 bytes unused 1264 usage 236/1500 (15 %)
TX [tx_stack] stack size 1200/1200 bytes unused 1032 usage 168/1200 (14 %)
MGMT [mgmt_stack] stack size 512/512 bytes unused 416 usage 96/512 (18 %)
main [_main_stack] stack size 1024/1024 bytes unused 540 usage 484/1024 (47 %)
ISR [_interrupt_stack] stack size 2048/2048 bytes unused 1880 usage 168/2048 (8 %)
net>
Reported by gurucharan p:
I was trying to test the http_server and http_client applications with two different frdm_k64f boards. The steps I have followed for http server is as below:
cd zephyr/samples/net/http_server
make clean;make pristine && make BOARD=frdm_k64f
cp /outdir/frdm_k64f/zephyr.bin /run/media/MBED/
The steps I have followed for http client is as below:
cd zephyr/samples/net/http_server
change the settings of below config as below in the prj.conf file
CONFIG_NET_APP_MY_IPV4_ADDR="192.0.2.2" CONFIG_NET_APP_PEER_IPV4_ADDR="192.0.2.1"
make clean;make pristine && make BOARD=frdm_k64f
cp /outdir/frdm_k64f/zephyr.bin /run/media/MBED1/
With the above settings I was expecting that the http_client and http_server applications will be executed successfully on two frdm_k64f boards. But I am getting failure as below even though the ping between server and client works perfectly fine.
at the server side on frdm_k64f console:
at the client side on frdm_k64f console:
(Imported from Jira ZEP-2635)