完善资料让更多小伙伴认识你,还能领取20积分哦, 立即完善>
——和谐V1.09——默认情况下,我的设备最初启动TCPIP,并通过静态IP设置(DHCP客户端服务禁用)将网络连接起来(TCPIPPSTACKBRIGNETUP)。然后从非易失性存储中加载用户配置的网络设置并应用这些。但是,从上述状态(DHCP禁用,即静态IP设置),如果DHCP客户端稍后通过TCPIpH.DHCPYEnable()启用,则DHCP指定的DNS服务器值不被*应用!这个问题的决定点可以在.HealthV1O09FraseTCPISrcDHCP C中,在函数ydHCPSETeNeLeasee()中,在1767行,其中检查BISDNSSEVALUAL标志。注意!!此标志仅在整个堆栈中的一个实例中被触摸和声明**…当配置的地址服务被检查时(参见第3049—3064行)。此外,调用yLoopNeWorkStudio()的唯一公共API函数是TCPIPpStAcxNETUP()。当简单地启用DHCP客户端模式时,这里出现了一些错误。请告知。如果这是预期的行为,那么请指定什么是正确的过程,使DHCP客户端从初始化网络的状态已经没有地址服务激活。
以上来自于百度翻译 以下为原文 -- HARMony v1.09 -- By default, my device initially starts TCPIP and brings networking up (TCPIP_STACK_BringNetUp) with static IP settings (DHCP client service disabled). It then loads user-configured network settings from nonvolatile storage and applies those. However, from the above state (DHCP disabled, i.e. static IP settings), if DHCP client is later enabled via TCPIP_DHCP_Enable(), the DHCP-assigned DNS server values are *NOT* applied! The deciding point of this issue can be found in ..Harmonyv1_09frameworktcpipsrcdhcp.c, in function _DHCPSetNewLease(), at ~ line 1767, where the bIsDNSServerAuto flag is checked. NOTE!! ... this flag is **only touched and asserted in _one_ instance in the entire stack** ... which is in _LoadNetworkConfig(), when the configured address service is checked (see lines 3049-3064). Furthermore, the only public API function which calls _LoadNetworkConfig() is TCPIP_STACK_NetUp(). I see nowhere in the documentation specifying that networking must be brought down/up, or reinitialized, when simply enabling DHCP client mode. There appears to be something wrong here. Please advise. If this is said to be intended behavior, then please specify what is the correct procedure to enable DHCP client from a state of initialized networking already with no address service active. Thank you |
|
相关推荐
9个回答
|
|
你是对的:没有必要关闭这个接口,你可以在运行时启用DHCP,它应该是好的。让我看看并做一些测试,我会给你回复。
以上来自于百度翻译 以下为原文 You're right: there is no need to turn down/up the interface, you can enable the DHCP at run time and it should be OK. Let me take a look and do some tests and I'll get back to you. |
|
|
|
好的,谢谢你的确认。然后,我认为这是个问题。BISDNSServAutoAuto标志是否设置为1?隐式设置为1的唯一位置是在.Load NeWorkSt配置()中,它只被调用为Net UP或NET初始化。因此,除了在网络初始化或网络注册时启用DHCP客户端之外,否则应用于指定的DNS值的ydHCPSETeNeLeasee()中的条件和封闭代码将永远不会被执行。
以上来自于百度翻译 以下为原文 OK, thanks for confirming. Then, I think this is a problem. Is there some other way that bIsDNSServerAuto flag is set to 1? The only place it is implicitly set to 1 is in _LoadNetworkConfig(), which is only called for net up, or net initialization. Therefore, the condition and enclosed code in _DHCPSetNewLease() which applies the assigned DNS values will never be executed except if DHCP client is enabled at the time of net initialization or net up. |
|
|
|
您发现的问题得到确认,并在V2.04中被修复。如果您想在发布之前应用修复程序,那么请更新您的TCPIPSHealth.C行3061:否则{D/HC/DHCPC将更新这些PNETIF-&Gr.BasdSnServer Auto=1;} /DHCPC将更新这些PNETIFF & Gt;Flags.bIsDNSServerA。UTO=1;这将允许DHCP用从DHCP服务器接收的数据更新DNS设置。谢谢您查找和报告Test.PS。我将为用户添加一个配置标志,禁止DHCP客户端重写静态DNS设置。这是BISDNSServer AutoAuto的意图。但是对于V2.04版本来说已经太迟了,它必须等待下一个版本。
以上来自于百度翻译 以下为原文 The issue you found is confirmed and it's fixed for v2.04. If you want to apply the fix before the release, then please update your tcpip_manager.c line #3061: else { // The DHCPc will update these pNetIf->Flags.bIsDNSServerAuto = 1; } to // The DHCPc will update these pNetIf->Flags.bIsDNSServerAuto = 1; This will allow DHCP to update the DNS settings with data received from the DHCP server. Thank you for finding and reporting this. PS. I'll add a configuration flag for the user to forbid the DHCP client to override the static DNS settings. That was the intention for the bIsDNSServerAuto. But it's too late for the v2.04 release, it will have to wait for the next. |
|
|
|
好的,谢谢你的回复。和谐V2.XX在beta版本中,和声V1.XX仍然是积极支持的发布产品,是吗?所以我假设这个修复是在V1.XX中实现的吗?我问的原因是,我见过它在多个场合说,“这将是固定在和谐V2.xx”,但由于和谐V2.xx是贝塔,是不是相当标准的做法,目前活跃的产品(V1.xx),以积极支持,直到一个新的产品是在beta版和完全释放的状态?谢谢你
以上来自于百度翻译 以下为原文 OK, thanks for the response. With Harmony v2.xx at beta, Harmony v1.xx is still the actively-supported release product, yes? So I assume this fix be implemented in Harmony v1.xx? The reason I ask is, I have seen it said on multiple occasions, "this will be fixed in Harmony v2.xx", but since Harmony v2.xx is beta, isn't it fairly standard practice for current active product (v1.xx) to be actively supported until a new product is out of beta and at full release status? Thank you |
|
|
|
即将发布的V2.04版本不是beta版。不会有其他的V1.XX版本。请告诉我们,如果提供的修复不适合你,我们会尝试提供一些有用的东西。
以上来自于百度翻译 以下为原文 The coming v2.04 release is not Beta. There won't be other v1.xx releases. Please let us know if the provided fix doesn't work for you and we'll try to provide something that works. |
|
|
|
|
|
|
|
是的,应该始终执行PNETIF-GT;FraseBISDNSServer Auto= 1;
以上来自于百度翻译 以下为原文 Yes, the: pNetIf->Flags.bIsDNSServerAuto = 1; should be always executed. |
|
|
|
从最初的测试来看,FIX确实起作用,即DHCP服务器提供的DNS设置现在被正确应用。如果我发现更多的问题,我会向你汇报,谢谢你的及时和有效的答复,雷纳德!
以上来自于百度翻译 以下为原文 From initial tests the fix does appear to work, i.e. the DNS settings provided by DHCP server are now properly applied. I will report back if I discover any further issues. Thank you for the prompt and effective response, rainad ! |
|
|
|
当然,很高兴我们能帮上忙。如果测试结果显示出来,请告诉我们。
以上来自于百度翻译 以下为原文 Sure, glad we could help. Let us know if the tests reveal anything else. Regards. |
|
|
|
只有小组成员才能发言,加入小组>>
5160 浏览 9 评论
1998 浏览 8 评论
1927 浏览 10 评论
请问是否能把一个ADC值转换成两个字节用来设置PWM占空比?
3170 浏览 3 评论
请问电源和晶体值之间有什么关系吗?PIC在正常条件下运行4MHz需要多少电压?
2225 浏览 5 评论
727浏览 1评论
612浏览 1评论
有偿咨询,关于MPLAB X IPE烧录PIC32MX所遇到的问题
501浏览 1评论
PIC Kit3出现目标设备ID(00000000)与预期的设备ID(02c20000)不匹配。是什么原因
626浏览 0评论
524浏览 0评论
小黑屋| 手机版| Archiver| 电子发烧友 ( 湘ICP备2023018690号 )
GMT+8, 2024-11-22 06:50 , Processed in 1.389493 second(s), Total 95, Slave 78 queries .
Powered by 电子发烧友网
© 2015 bbs.elecfans.com
关注我们的微信
下载发烧友APP
电子发烧友观察
版权所有 © 湖南华秋数字科技有限公司
电子发烧友 (电路图) 湘公网安备 43011202000918 号 电信与信息服务业务经营许可证:合字B2-20210191 工商网监 湘ICP备2023018690号