On 29/08/17 14:03, 'Yakun Xu' via openthread-users wrote:
> 1. As you posted, it seems Thread node didn't get the on-mesh prefix you
> configured. Did you build the image with BORDER_ROUTER=1 and
> TMF_PROXY=1? If not, try building with these two FLAGS on and see if it
> works. more info <
https://github.com/openthread/borderrouter/wiki>
Ahh okay, so those translate to configure options:
--enable-tmf-proxy
and
--enable-border-router
I also noted JOINER=1 was in there, so added --enable-joiner too.
With that, it seems I'm still not able to ping the outside world. Is
there a way to inspect the routing table on the nodes (ala `ip -6 route`
on Linux or `route print` on OpenBSD)?
At times I also see this message in /var/log/daemon.log on the border
router:
> Aug 29 15:27:41 wsg-74fe481fe117 wpantund[373]: wpantund[373]: Resetting interface(s). . .
> Aug 29 15:27:41 wsg-74fe481fe117 wpantund[373]: Resetting interface(s). . .
> Aug 29 15:27:41 wsg-74fe481fe117 wpantund[373]: Finished initializing NCP
> Aug 29 15:27:41 wsg-74fe481fe117 otbr-agent[628]: otbr-agent[628]: NCP property NCP:State changed.
> Aug 29 15:27:41 wsg-74fe481fe117 wpantund[373]: wpantund[373]: Finished initializing NCP
> Aug 29 15:27:41 wsg-74fe481fe117 otbr-agent[628]: otbr-agent[628]: NCP property Daemon:ReadyForHostSleep changed.
> Aug 29 15:27:41 wsg-74fe481fe117 otbr-agent[628]: otbr-agent[628]: NCP property Daemon:ReadyForHostSleep changed.
> Aug 29 15:27:41 wsg-74fe481fe117 otbr-agent[628]: otbr-agent[628]: NCP property Network:PANID changed.
> Aug 29 15:27:41 wsg-74fe481fe117 otbr-agent[628]: otbr-agent[628]: NCP property Network:XPANID changed.
> Aug 29 15:27:41 wsg-74fe481fe117 otbr-agent[628]: otbr-agent[628]: NCP property IPv6:MeshLocalAddress changed.
> Aug 29 15:27:41 wsg-74fe481fe117 wpantund[373]: State change: "offline" -> "associating"
> Aug 29 15:27:41 wsg-74fe481fe117 wpantund[373]: wpantund[373]: State change: "offline" -> "associating"
> Aug 29 15:27:41 wsg-74fe481fe117 otbr-agent[628]: otbr-agent[628]: NCP property NCP:State changed.
> Aug 29 15:27:41 wsg-74fe481fe117 otbr-agent[628]: otbr-agent[628]: NCP property NCP:Channel changed.
> Aug 29 15:27:41 wsg-74fe481fe117 otbr-agent[628]: otbr-agent[628]: NCP property Network:Name changed.
> Aug 29 15:27:43 wsg-74fe481fe117 wpantund[373]: State change: "associating" -> "associated"
> Aug 29 15:27:43 wsg-74fe481fe117 wpantund[373]: Node type change: "unknown" -> "end-device"
> Aug 29 15:27:43 wsg-74fe481fe117 wpantund[373]: wpantund[373]: State change: "associating" -> "associated"
> Aug 29 15:27:43 wsg-74fe481fe117 wpantund[373]: wpantund[373]: Node type change: "unknown" -> "end-device"
> Aug 29 15:27:43 wsg-74fe481fe117 otbr-agent[628]: otbr-agent[628]: NCP property NCP:State changed.
> Aug 29 15:27:43 wsg-74fe481fe117 otbr-agent[628]: otbr-agent[628]: NCP property Network:NodeType changed.
> Aug 29 15:27:43 wsg-74fe481fe117 otbr-web[375]: otWeb[375]: wpan service error: 8
> Aug 29 15:27:43 wsg-74fe481fe117 otbr-agent[628]: otbr-agent[628]: NCP property Daemon:ReadyForHostSleep changed.
Quite what error 8 means, I am not sure.
For what it's worth, this is what I have in my Makefile (I build two
separate instances of OpenThread for the sake of memory consumption):
> NODE_TYPE=ftd
…
> # --- OpenThread build targets ---
>
> $(BUILD_DIR)/demo-lib/lib/libopenthread-$(NODE_TYPE).a \
> $(BUILD_DIR)/demo-lib/lib/libopenthread-cli-$(NODE_TYPE).a \
> $(BUILD_DIR)/demo-lib/lib/libopenthread-platform-utils.a \
> $(BUILD_DIR)/demo-lib/lib/libmbedcrypto.a: | \
> $(shell find $(OPENTHREAD_DIR) -type f -name \*.[ch])
> $(MAKE) -f $(TOP_DIR)/Makefile.ot \
> OPENTHREAD_BUILD_OPTS="\
> --with-platform-info=WIDESKYHUB \
> --enable-application-coap \
> --disable-docs --enable-joiner --enable-$(NODE_TYPE) \
> --enable-cli-app=$(NODE_TYPE) --disable-raw-link-api" \
> BUILD_DIR=$(BUILD_DIR)/demo/ot \
> INSTALL_DIR=$(BUILD_DIR)/demo-lib \
> NODE_TYPE=$(NODE_TYPE)
>
> $(BUILD_DIR)/ncp-lib/lib/libopenthread-$(NODE_TYPE).a \
> $(BUILD_DIR)/ncp-lib/lib/libopenthread-ncp-$(NODE_TYPE).a \
> $(BUILD_DIR)/ncp-lib/lib/libopenthread-platform-utils.a \
> $(BUILD_DIR)/ncp-lib/lib/libmbedcrypto.a: | \
> $(shell find $(OPENTHREAD_DIR) -type f -name \*.[ch])
> $(MAKE) -f $(TOP_DIR)/Makefile.ot \
> OPENTHREAD_BUILD_OPTS="\
> --with-platform-info=WIDESKYHUBNCP \
> --disable-docs --enable-$(NODE_TYPE) \
> --enable-ncp-app=$(NODE_TYPE) \
> --with-ncp-bus=uart --disable-raw-link-api \
> --enable-tmf-proxy --enable-border-router \
> --enable-joiner" \
> BUILD_DIR=$(BUILD_DIR)/ncp/ot \
> INSTALL_DIR=$(BUILD_DIR)/ncp-lib \
> NODE_TYPE=$(NODE_TYPE)
and in Makefile.ot:
> $(BUILD_DIR)/.configure: $(BUILD_DIR)/.bootstrap
> cd $(BUILD_DIR) && CXXFLAGS="$(CXXFLAGS) -Wno-unused-function" \
> $(OPENTHREAD_DIR)/configure \
> --host=arm-none-eabi --prefix=$(INSTALL_DIR) \
> $(OPENTHREAD_BUILD_OPTS)
> touch $@
I tried re-forming the network after flashing the updated firmware, and
even re-booting the border router, to no avail, it would appear the
nodes still don't know how to get beyond the border router.