Comments (10)
@qq792368480 你好,我们PPP有实际测试过。你的应用中应该是PPP + 4G 模块,而我们提供的只是PPP协议栈,用户需要负责4G模块的组网等。关于调试,你可以启用下面两个的宏来查看各个阶段的状态和解码后的数据,如下图所示。另外这里是PPP的中文手册https://docs.microsoft.com/zh-cn/azure/rtos/netx-duo/netx-duo-ppp/chapter1
NX_PPP_DEBUG_LOG_ENABLE
NX_PPP_DEBUG_LOG_PRINT_ENABLE
from netxduo.
@qq792368480 你好,我是Azure RTOS的产品经理。请教下你这里用4G走PPP是个什么样的产品?我们最近正在做不少相关的工作,想更详细了解下你这里有关的需求。方便的话可以留个邮箱我们联系到你这里。
from netxduo.
@qq792368480 你好,我们PPP有实际测试过。你的应用中应该是PPP + 4G 模块,而我们提供的只是PPP协议栈,用户需要负责4G模块的组网等。关于调试,你可以启用下面两个的宏来查看各个阶段的状态和解码后的数据,如下图所示。另外这里是PPP的中文手册https://docs.microsoft.com/zh-cn/azure/rtos/netx-duo/netx-duo-ppp/chapter1
NX_PPP_DEBUG_LOG_ENABLE
NX_PPP_DEBUG_LOG_PRINT_ENABLE
谢谢。我开启调试,打印这些内容,一直停在LCP阶段状态NX_PPP_LCP_PEER_CONFIGURE_REQUEST_ACKED_STATE(4)请问能从以下信息看出是什么原因导致的吗,仿真调试发现ppp_ptr -> nx_ppp_transmit_id != ppp_ptr -> nx_ppp_receive_id。4G模块是已经连接成功才进行ppp协商的
at cmd = ATDT*99#
get len = 11
0D 0A 43 4F 4E 4E 45 43 54 0D 0A |..CONNECT..
rsp 0
————————————————————————————————————————————————————
Time: 20776, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 1, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Authenticated, Send Packet Length: 10, Packet: c0 21 01 00 00 08 01 04 05 dc
Time: 21176, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 2, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Authenticated, Send Packet Length: 10, Packet: c0 21 01 01 00 08 01 04 05 dc
Time: 21576, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 2, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Authenticated, Send Packet Length: 10, Packet: c0 21 01 02 00 08 01 04 05 dc
Time: 21748, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 2, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Authenticated, Received Packet Length: 26, Packet: c0 21 01 00 00 18 02 06 00 00 00 00 03 04 c0 23 05 06 ba 6d ef df 07 02 08 02
Time: 21918, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 26, Packet: c0 21 02 00 00 18 02 06 00 00 00 00 03 04 c0 23 05 06 ba 6d ef df 07 02 08 02
Time: 22276, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 03 00 08 01 04 05 dc
Time: 22526, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 10, Packet: c0 21 02 00 00 08 01 04 05 dc
Time: 22676, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 04 00 08 01 04 05 dc
Time: 23048, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 10, Packet: c0 21 02 01 00 08 01 04 05 dc
Time: 23166, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 05 00 08 01 04 05 dc
Time: 23571, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 10, Packet: c0 21 02 02 00 08 01 04 05 dc
Time: 23690, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 06 00 08 01 04 05 dc
Time: 24076, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 07 00 08 01 04 05 dc
Time: 24476, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 08 00 08 01 04 05 dc
Time: 24675, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 26, Packet: c0 21 01 01 00 18 02 06 00 00 00 00 03 04 c0 23 05 06 ba 6d ef df 07 02 08 02
Time: 24976, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 09 00 08 01 04 05 dc
Time: 25249, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 10, Packet: c0 21 02 03 00 08 01 04 05 dc
Time: 25376, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 0a 00 08 01 04 05 dc
Time: 25770, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 10, Packet: c0 21 02 04 00 08 01 04 05 dc
Time: 25890, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 0b 00 08 01 04 05 dc
Time: 26276, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 0c 00 08 01 04 05 dc
Time: 26676, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 0d 00 08 01 04 05 dc
Time: 26874, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 26, Packet: c0 21 01 02 00 18 02 06 00 00 00 00 03 04 c0 23 05 06 ba 6d ef df 07 02 08 02
Time: 27176, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 0e 00 08 01 04 05 dc
Time: 27450, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 10, Packet: c0 21 02 05 00 08 01 04 05 dc
Time: 27576, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 0f 00 08 01 04 05 dc
Time: 27969, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 10, Packet: c0 21 02 06 00 08 01 04 05 dc
Time: 28090, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 10 00 08 01 04 05 dc
Time: 28476, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 11 00 08 01 04 05 dc
Time: 28876, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 12 00 08 01 04 05 dc
Time: 29065, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 26, Packet: c0 21 01 03 00 18 02 06 00 00 00 00 03 04 c0 23 05 06 ba 6d ef df 07 02 08 02
Time: 29376, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 13 00 08 01 04 05 dc
Time: 29651, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 10, Packet: c0 21 02 07 00 08 01 04 05 dc
Time: 29776, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 1, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 14 00 08 01 04 05 dc
from netxduo.
@qq792368480 你好,我是Azure RTOS的产品经理。请教下你这里用4G走PPP是个什么样的产品?我们最近正在做不少相关的工作,想更详细了解下你这里有关的需求。方便的话可以留个邮箱我们联系到你这里。
用在DTU上面的,当前产品是用lwip实现的,因为netxduo集成了很多插件就自己尝试移植下
from netxduo.
@qq792368480 你好,我们PPP有实际测试过。你的应用中应该是PPP + 4G 模块,而我们提供的只是PPP协议栈,用户需要负责4G模块的组网等。关于调试,你可以启用下面两个的宏来查看各个阶段的状态和解码后的数据,如下图所示。另外这里是PPP的中文手册https://docs.microsoft.com/zh-cn/azure/rtos/netx-duo/netx-duo-ppp/chapter1
NX_PPP_DEBUG_LOG_ENABLE
NX_PPP_DEBUG_LOG_PRINT_ENABLE
谢谢。我开启调试,打印这些内容,一直停在LCP阶段状态NX_PPP_LCP_PEER_CONFIGURE_REQUEST_ACKED_STATE(4)请问能从以下信息看出是什么原因导致的吗,仿真调试发现ppp_ptr -> nx_ppp_transmit_id != ppp_ptr -> nx_ppp_receive_id。4G模块是已经连接成功才进行ppp协商的
at cmd = ATDT*99#
get len = 11
0D 0A 43 4F 4E 4E 45 43 54 0D 0A |..CONNECT..
rsp 0
————————————————————————————————————————————————————
Time: 20776, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 1, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Authenticated, Send Packet Length: 10, Packet: c0 21 01 00 00 08 01 04 05 dc
Time: 21176, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 2, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Authenticated, Send Packet Length: 10, Packet: c0 21 01 01 00 08 01 04 05 dc
Time: 21576, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 2, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Authenticated, Send Packet Length: 10, Packet: c0 21 01 02 00 08 01 04 05 dc
Time: 21748, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 2, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Authenticated, Received Packet Length: 26, Packet: c0 21 01 00 00 18 02 06 00 00 00 00 03 04 c0 23 05 06 ba 6d ef df 07 02 08 02
Time: 21918, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 26, Packet: c0 21 02 00 00 18 02 06 00 00 00 00 03 04 c0 23 05 06 ba 6d ef df 07 02 08 02
Time: 22276, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 03 00 08 01 04 05 dc
Time: 22526, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 10, Packet: c0 21 02 00 00 08 01 04 05 dc
Time: 22676, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 04 00 08 01 04 05 dc
Time: 23048, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 10, Packet: c0 21 02 01 00 08 01 04 05 dc
Time: 23166, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 05 00 08 01 04 05 dc
Time: 23571, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 10, Packet: c0 21 02 02 00 08 01 04 05 dc
Time: 23690, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 06 00 08 01 04 05 dc
Time: 24076, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 07 00 08 01 04 05 dc
Time: 24476, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 08 00 08 01 04 05 dc
Time: 24675, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 26, Packet: c0 21 01 01 00 18 02 06 00 00 00 00 03 04 c0 23 05 06 ba 6d ef df 07 02 08 02
Time: 24976, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 09 00 08 01 04 05 dc
Time: 25249, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 10, Packet: c0 21 02 03 00 08 01 04 05 dc
Time: 25376, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 0a 00 08 01 04 05 dc
Time: 25770, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 10, Packet: c0 21 02 04 00 08 01 04 05 dc
Time: 25890, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 0b 00 08 01 04 05 dc
Time: 26276, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 0c 00 08 01 04 05 dc
Time: 26676, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 0d 00 08 01 04 05 dc
Time: 26874, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 26, Packet: c0 21 01 02 00 18 02 06 00 00 00 00 03 04 c0 23 05 06 ba 6d ef df 07 02 08 02
Time: 27176, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 0e 00 08 01 04 05 dc
Time: 27450, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 10, Packet: c0 21 02 05 00 08 01 04 05 dc
Time: 27576, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 0f 00 08 01 04 05 dc
Time: 27969, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 10, Packet: c0 21 02 06 00 08 01 04 05 dc
Time: 28090, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 10 00 08 01 04 05 dc
Time: 28476, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 11 00 08 01 04 05 dc
Time: 28876, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 12 00 08 01 04 05 dc
Time: 29065, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 26, Packet: c0 21 01 03 00 18 02 06 00 00 00 00 03 04 c0 23 05 06 ba 6d ef df 07 02 08 02
Time: 29376, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 13 00 08 01 04 05 dc
Time: 29651, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 10, Packet: c0 21 02 07 00 08 01 04 05 dc
Time: 29776, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 1, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 14 00 08 01 04 05 dc
ID 是用来匹配请求和响应的。状态4表示对方发送了请求,我们响应了,并且我们发送了请求等待对方响应,但是因为响应的ID不匹配,所以没有完成。你这边测试的PPP server端是仿真的还是实际的?仿真的话你可以调试看看为什么前面3个请求server没有任何响应?并先启动server,然后启动client试试。
from netxduo.
@qq792368480 你好,我们PPP有实际测试过。你的应用中应该是PPP + 4G 模块,而我们提供的只是PPP协议栈,用户需要负责4G模块的组网等。关于调试,你可以启用下面两个的宏来查看各个阶段的状态和解码后的数据,如下图所示。另外这里是PPP的中文手册https://docs.microsoft.com/zh-cn/azure/rtos/netx-duo/netx-duo-ppp/chapter1
NX_PPP_DEBUG_LOG_ENABLE
NX_PPP_DEBUG_LOG_PRINT_ENABLE
谢谢。我开启调试,打印这些内容,一直停在LCP阶段状态NX_PPP_LCP_PEER_CONFIGURE_REQUEST_ACKED_STATE(4)请问能从以下信息看出是什么原因导致的吗,仿真调试发现ppp_ptr -> nx_ppp_transmit_id != ppp_ptr -> nx_ppp_receive_id。4G模块是已经连接成功才进行ppp协商的
at cmd = ATDT*99#
get len = 11
0D 0A 43 4F 4E 4E 45 43 54 0D 0A |..CONNECT..
rsp 0
————————————————————————————————————————————————————
Time: 20776, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 1, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Authenticated, Send Packet Length: 10, Packet: c0 21 01 00 00 08 01 04 05 dc
Time: 21176, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 2, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Authenticated, Send Packet Length: 10, Packet: c0 21 01 01 00 08 01 04 05 dc
Time: 21576, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 2, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Authenticated, Send Packet Length: 10, Packet: c0 21 01 02 00 08 01 04 05 dc
Time: 21748, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 2, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Authenticated, Received Packet Length: 26, Packet: c0 21 01 00 00 18 02 06 00 00 00 00 03 04 c0 23 05 06 ba 6d ef df 07 02 08 02
Time: 21918, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 26, Packet: c0 21 02 00 00 18 02 06 00 00 00 00 03 04 c0 23 05 06 ba 6d ef df 07 02 08 02
Time: 22276, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 03 00 08 01 04 05 dc
Time: 22526, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 10, Packet: c0 21 02 00 00 08 01 04 05 dc
Time: 22676, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 04 00 08 01 04 05 dc
Time: 23048, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 10, Packet: c0 21 02 01 00 08 01 04 05 dc
Time: 23166, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 05 00 08 01 04 05 dc
Time: 23571, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 10, Packet: c0 21 02 02 00 08 01 04 05 dc
Time: 23690, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 06 00 08 01 04 05 dc
Time: 24076, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 07 00 08 01 04 05 dc
Time: 24476, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 08 00 08 01 04 05 dc
Time: 24675, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 26, Packet: c0 21 01 01 00 18 02 06 00 00 00 00 03 04 c0 23 05 06 ba 6d ef df 07 02 08 02
Time: 24976, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 09 00 08 01 04 05 dc
Time: 25249, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 10, Packet: c0 21 02 03 00 08 01 04 05 dc
Time: 25376, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 0a 00 08 01 04 05 dc
Time: 25770, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 10, Packet: c0 21 02 04 00 08 01 04 05 dc
Time: 25890, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 0b 00 08 01 04 05 dc
Time: 26276, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 0c 00 08 01 04 05 dc
Time: 26676, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 0d 00 08 01 04 05 dc
Time: 26874, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 26, Packet: c0 21 01 02 00 18 02 06 00 00 00 00 03 04 c0 23 05 06 ba 6d ef df 07 02 08 02
Time: 27176, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 0e 00 08 01 04 05 dc
Time: 27450, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 10, Packet: c0 21 02 05 00 08 01 04 05 dc
Time: 27576, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 0f 00 08 01 04 05 dc
Time: 27969, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 10, Packet: c0 21 02 06 00 08 01 04 05 dc
Time: 28090, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 10 00 08 01 04 05 dc
Time: 28476, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 11 00 08 01 04 05 dc
Time: 28876, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 12 00 08 01 04 05 dc
Time: 29065, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 26, Packet: c0 21 01 03 00 18 02 06 00 00 00 00 03 04 c0 23 05 06 ba 6d ef df 07 02 08 02
Time: 29376, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 13 00 08 01 04 05 dc
Time: 29651, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 4, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Received Packet Length: 10, Packet: c0 21 02 07 00 08 01 04 05 dc
Time: 29776, PPP Name: NetX PPP Instance 1, PPP State: 1, PPP LCP State: 1, PPP PAP State: 0, PPP CHAP State: 0, PPP IPCP State: 0, Not Authenticated, Send Packet Length: 10, Packet: c0 21 01 14 00 08 01 04 05 dcID 是用来匹配请求和响应的。状态4表示对方发送了请求,我们响应了,并且我们发送了请求等待对方响应,但是因为响应的ID不匹配,所以没有完成。你这边测试的PPP server端是仿真的还是实际的?仿真的话你可以调试看看为什么前面3个请求server没有任何响应?并先启动server,然后启动client试试。
你好,是实际和4G模块进行通信的(EC20,通过串口)。对啊我也疑惑前面经过了3个请求包4G模块才响应导致ID不匹配,你们这个PPP包发送间隔是怎么设置的。
from netxduo.
默认的重传间隔是4s. nx_ppp.h: NX_PPP_PROTOCOL_TIMEOUT
from netxduo.
默认的重传间隔是4s. nx_ppp.h: NX_PPP_PROTOCOL_TIMEOUT
谢谢,可以了。是我这边MCU时基设置1ms,
这个没相应改过来
from netxduo.
默认的重传间隔是4s. nx_ppp.h: NX_PPP_PROTOCOL_TIMEOUT
了解,很高兴知道你这边跑通了。请问你能留个联系方式么?想进一步了解一下你这边的应用场景和需求等。
from netxduo.
@qq792368480 这个issue我关掉了,如果有任何问题你可以再开新的issue。
from netxduo.
Related Issues (20)
- BSD addon fails to compile HOT 3
- BSD socket create failed!
- Deployment in Device Update for IoT Hub is Failed with NETX DUO 6.4.1 HOT 3
- Improper handled of out of order packets in case Application connection restarts in multiple loop HOT 3
- http(s) client: how to download a big file chunk by chunk ? HOT 3
- DHCPv6 Server instance sends IPv6 response packets on incorrect index when DHCPv6 Client and DHCPv6 Server are brought up simultaneously
- Module (DHCPv6 Client) is getting a new IPv6 address each time we disconnect and reconnect from the Home Wi-Fi
- Can NETX DHCPv6 support simultaneous DHCPv6 Client & DHCPv6 Server on two interfaces?
- NetX BSD fails when select() is passed a timeout
- NetX Duo Socket Error NX_NOT_CONNECTED due to dropped SYN-ACKs
- MQTT with TLS1.3 on STMH563ZI nucleo board HOT 1
- High-speed transfer hang on mutex
- Is Netx DUO IPv6 standard certified or compliant for an end-node? HOT 1
- nx_ppp_delete leaks packet pool packets through nx_ppp_receive_partial_packet
- Range header support for Http client
- BSD tcp socket - send error with large data size HOT 8
- ALPN extension support in TLS
- nx_packet_allocated return false for RISCV-64 bits arch HOT 1
- Support for HTTP/2 and HTTP/3
- NetX Secure error NX_SECURE_PKCS1_INVALID_PRIVATE_KEY HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from netxduo.