TI中文支持网
TI专业的中文技术问题搜集分享网站

z-stack_linux_gateway-1.0.1 在bbb板上运行出错问题 求助

在ti官网上下载到的z-stack linux gateway 将文件里的Precompiled_arm 里的的文件 copy到bbb里,在bbb里运行 ./zigbeeHAgw bbb  打印出来一下信息

请问这是什么原因导致的,该如何去解决这个问题?????

———————————————————————————————————————————————————————————————————

root@beaglebone:~/Desktop/z-stack_linux_gateway_arm_binaries_38883# cd servers/root@beaglebone:~/Desktop/z-stack_linux_gateway_arm_binaries_38883/servers# lsGATEWAY_SRVR_arm NWKMGR_SRVR_arm config.ini start_applicationNPI_Gateway.cfg OTA_SRVR_arm gateway_config.tlg track_serversNPI_lnx_arm_server ZLSZNP_arm sample_app_ota.cfg zigbeeHAgwroot@beaglebone:~/Desktop/z-stack_linux_gateway_arm_binaries_38883/servers# ./zigbeeHAgw bbbrunning zigbeegw.scr on an ARMresetting beaglebone black./zigbeeHAgw: line 989: ../tools/bbb_usbreset.bin: No such file or directory sleeping 6 seconds after reset… ./zigbeeHAgw: line 997: ../tools/gw_soc_fw_version_query.bi
n: No such file or directorydone
stty: /dev/ttyACM0: No such file or directory
stty: /dev/ttyACM0: No such file or directory
Starting the ZigBee gateway subsystem
./zigbeeHAgw: line 332: ./NPI_lnx_arm_server: No such file or directory
NPI started (pid 687) at Wed Jan 13 09:59:08 UTC 2016
./zigbeeHAgw: line 359: ./ZLSZNP_arm: No such file or directory
ZLSZNP started (pid 690) at Wed Jan 13 09:59:12 UTC 2016
./zigbeeHAgw: line 417: ./NWKMGR_SRVR_arm: No such file or directory
NETWORK MANAGER started (pid 693) at Wed Jan 13 09:59:13 UTC 2016
./zigbeeHAgw: line 387: ./GATEWAY_SRVR_arm: No such file or directory
GATEWAY SERVER started (pid 696) at Wed Jan 13 09:59:15 UTC 2016
./zigbeeHAgw: line 446: ./OTA_SRVR_arm: No such file or directory
OTA SERVER started (pid 699) at Wed Jan 13 09:59:17 UTC 2016
starting tracker with our pid ./zigbeeHAgw and pid list 687 690 696 699
===================================================
oops! Network manager has already exited (!) at
Wed Jan 13 09:59:17 UTC 2016
./zigbeeHAgw: line 482: 706 Killed ./track_servers $$ "$pids"
killall: GATEWAY_SRVR_arm: no process killed
killall: OTA_SRVR_arm: no process killed
killall: ZLSZNP_arm: no process killed
killall: NPI_lnx_arm_server: no process killed
unexpected exit code (127) from netmgr!
resetting beaglebone black
./zigbeeHAgw: line 989: ../tools/bbb_usbreset.bin: No such file or directory
sleeping 6 seconds after reset… ./zigbeeHAgw: line 997: ../tools/gw_soc_fw_version_query.bi
n: No such file or directory
done
stty: /dev/ttyACM0: Inappropriate ioctl for device
stty: /dev/ttyACM0: Inappropriate ioctl for device
Starting the ZigBee gateway subsystem
./zigbeeHAgw: line 332: ./NPI_lnx_arm_server: No such file or directory
NPI started (pid 772) at Wed Jan 13 09:59:41 UTC 2016
./zigbeeHAgw: line 359: ./ZLSZNP_arm: No such file or directory
ZLSZNP started (pid 775) at Wed Jan 13 09:59:45 UTC 2016
./zigbeeHAgw: line 417: ./NWKMGR_SRVR_arm: No such file or directory
NETWORK MANAGER started (pid 778) at Wed Jan 13 09:59:46 UTC 2016
./zigbeeHAgw: line 387: ./GATEWAY_SRVR_arm: No such file or directory
GATEWAY SERVER started (pid 781) at Wed Jan 13 09:59:48 UTC 2016
./zigbeeHAgw: line 446: ./OTA_SRVR_arm: No such file or directory
OTA SERVER started (pid 784) at Wed Jan 13 09:59:50 UTC 2016
starting tracker with our pid ./zigbeeHAgw and pid list 772 775 781 784
===================================================
oops! Network manager has already exited (!) at
Wed Jan 13 09:59:51 UTC 2016
./zigbeeHAgw: line 482: 791 Killed ./track_servers $$ "$pids"
killall: GATEWAY_SRVR_arm: no process killed
killall: OTA_SRVR_arm: no process killed
killall: ZLSZNP_arm: no process killed
killall: NPI_lnx_arm_server: no process killed
^Ccaught SIGTERM, killing all the servers and cleaning up

———————————————————————————————————————————————————————————————————

Yaoming Qin:

请问您的下载链接是哪个?

您再bbb上跑的linuxsdk的版本和z-stack的版本匹配吗

user4566561:

回复 Yaoming Qin:

嗯 是的,我在官网上下载的z-stack_linux_gateway-1.0.1

搭建Beaglebone black运行环境,将z-stack_linux_gateway中Precompiled_arm中的可执行文件scp 到 Beaglebone blackPrecompiled_arm中的可执行文件有main.bin,和NPI_lnx_arm_server ,GATEWAY_SRVR_arm ,NWKMGR_SRVR_arm, ZLSZNP_arm ,OTA_SRVR_arm几个可执行文件。通过执行一个脚本文件 启动这几个sever,然后在执行应用程序main.bin再执行脚本启动server的时候 打印出 ./zigbeeHAgw: line 332: ./NPI_lnx_arm_server: No such file or directory 原因已经明确。对于这个问题,首先联想到的事gcc的版本,arm开发板的gcc一般是arm-linux-gcc,但是这个系列的gcc还是有很多版本的,看了下板子上的gcc和电脑上交叉编译的版本同时gcc-4.7.3.再想了一下,它用的是beaglebone black板子,多了个hf是因为该芯片支持硬件浮点数运算。 对于gcc也是有对hf进行优化的,也就是带hf的gcc编译器:arm-linux-gnueabihf-gcc在beaglebong运行的文件系统上的gcc是arm-angstrom-linux-gnueabi,而交叉编译环境下的gcc却是:arm-linux-gnueabihf-gcc,所以放到板子上运行时直接是不能解释该文件。

通过在beaglebong的环境下使用arm-angstrom-linux-gnueabi编译了一个可执行程序,并且运行成功。 通过file命令查看文件信息root@beaglebone:~/Desktop/z-stack_linux_gateway_arm_binaries_38883/app# file main.bin  main.bin: ELF 32-bit LSB executable, ARM, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.16, not stripped然而提供的可执行程序通过file命令查看文件信息为:root@beaglebone:~/Desktop/z-stack_linux_gateway_arm_binaries_38883/app# file main.bin main.bin: ELF 32-bit LSB executable, ARM, EABI5 version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.31, BuildID[sha1]=9b748c88b78cfe7032ffb1e2f37e59b1ca2396a3, not stripped由于application的源码提供了,我们可以自己修改编译器,重新编译即可,不过几个server的源码暂时还没有,不过也可以通过相同的方法来解决这一问题。

最后我更新了Beagle bone Black 的系统为最新版本,解决了可执行程序不能运行的问题

user4566561:

回复 Yaoming Qin:

另外,解决了程序不能运行的问题后,又遇到了一个新的问题,希望你们帮助我看一下,ps我是按照z-stack_linux_gateway官方提供的文档一步一步做的啊?

z-stack_linux_gateway 在BB Black上运行./zigbeeHWgw bbb 出现错误

完全按照TI发布的z-stack_linux_gateway 的文档上操作。但在运行时还是出现了

一下错误,请问这个问题是可执行程序和BB Black上的系统不兼容么?还有有其他原因……

root@beaglebone:~/z-stack_linux_gateway_arm_binaries_38883# lsapp misc protobuf servers toolsroot@beaglebone:~/z-stack_linux_gateway_arm_binaries_38883# cd servers/root@beaglebone:~/z-stack_linux_gateway_arm_binaries_38883/servers# lsconfig.ini NPI_Gateway.cfg OTA_SRVR_arm track_serversgateway_config.tlg NPI_lnx_arm_server sample_app_ota.cfg zigbeeHAgwGATEWAY_SRVR_arm NWKMGR_SRVR_arm start_application ZLSZNP_armroot@beaglebone:~/z-stack_linux_gateway_arm_binaries_38883/servers# ./zigbeeHAgw bbbrunning zigbeegw.scr on an ARMresetting beaglebone blacksleeping 6 seconds after reset… Using serial port: /dev/ttyACM0zbSocProcessRpc: CMD0:41, CMD1:80, not handledReceived System version.Transport Protocol Version: 2Product ID: 0Software Release: 2.6.1Software Revision: 38724doneStarting the ZigBee gateway subsystemdeviceKey = 0 (0 )devPath = '/dev/ttyACM0'logPath = './NpiLnxLog.txt'… freeing memory (ret 0)Port: 2533Following IP addresses are available:

./zigbeeHAgw: line 324: 676 Segmentation fault $NPI_CMDNPI started (pid 676) at Thu Nov 12 21:30:07 UTC 2015connect: Connection refused[ZSTACKZNP_SRVR/MAIN] ERROR: ERROR: signal 11 was trigerred:[ZSTACKZNP_SRVR/MAIN] ERROR: Fault address: (nil)[ZSTACKZNP_SRVR/MAIN] ERROR: Fault reason: address not mapped to object[ZSTACKZNP_SRVR/MAIN] ERROR: Stack trace unavailable[ZSTACKZNP_SRVR/MAIN] ERROR: Executing original handler…./zigbeeHAgw: line 351: 681 Segmentation fault $ZLSZNP_CMDZLSZNP started (pid 681) at Thu Nov 12 21:30:12 UTC 2015[NWK_MGR/MAIN] : there are 2 args[NWK_MGR/MAIN] : argv[0] = ./NWKMGR_SRVR_arm[NWK_MGR/MAIN] : argv[1] = 127.0.0.1:2536connect: Connection refused[NWK_MGR/MAIN] ERROR: ERROR: signal 11 was trigerred:[NWK_MGR/MAIN] ERROR: Fault address: (nil)[NWK_MGR/MAIN] ERROR: Fault reason: address not mapped to object[NWK_MGR/MAIN] ERROR: Stack trace unavailable[NWK_MGR/MAIN] ERROR: Executing original handler…./zigbeeHAgw: line 407: 684 Segmentation fault $NWKMGR_CMD $NWKMGR_RESTART_FLAGNETWORK MANAGER started (pid 684) at Thu Nov 12 21:30:13 UTC 2015connect: Connection refused

user4566561:

回复 Yaoming Qin:

在http://www.ti.com.cn/tool/cn/z-stack?keyMatch=z-stack-linux-gateway&tisearch=Search-CN-Everything

下载的z-stack-linux-gateway

赞(0)
未经允许不得转载:TI中文支持网 » z-stack_linux_gateway-1.0.1 在bbb板上运行出错问题 求助
分享到: 更多 (0)