Raspberry Pi stability problem
-
Ok - thanks will do that...
-
pi@pi:~ $ sudo gdb /home/pi/mysensors_dev/MySensors/bin/mysgw
GNU gdb (Raspbian 7.7.1+dfsg-5+rpi1) 7.7.1
Copyright (C) 2014 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later http://gnu.org/licenses/gpl.html
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "arm-linux-gnueabihf".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
http://www.gnu.org/software/gdb/bugs/.
Find the GDB manual and other documentation resources online at:
http://www.gnu.org/software/gdb/documentation/.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from /home/pi/mysensors_dev/MySensors/bin/mysgw...done.
(gdb) run -d
Starting program: /home/pi/mysensors_dev/MySensors/bin/mysgw -d
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/arm-linux-gnueabihf/libthread_db.so.1".
mysgw: Starting gateway...
mysgw: Protocol version - 2.2.0-rc.2
mysgw: MCO:BGN:INIT GW,CP=RNNGL-Q-,VER=2.2.0-rc.2
mysgw: TSF:LRT:OK
mysgw: TSM:INIT
mysgw: TSF:WUR:MS=0
[New Thread 0x75cc8450 (LWP 4703)]
mysgw: TSM:INIT:TSP OK
mysgw: TSM:INIT:GW MODE
mysgw: TSM:READY:ID=0,PAR=0,DIS=0
mysgw: MCO:REG:NOT NEEDED
mysgw: MCO:BGN:STP
mysgw: MCO:BGN:INIT OK,TSP=1
mysgw: GWT:RMQ:MQTT RECONNECT
mysgw: connected to 127.0.0.1
mysgw: GWT:RMQ:MQTT CONNECTED
mysgw: GWT:TPS:TOPIC=mysensors-out/0/255/0/0/18,MSG SENT
mysgw: TSF:MSG:READ,3-3-255,s=255,c=3,t=7,pt=0,l=0,sg=0:
mysgw: TSF:MSG:BC
mysgw: TSF:MSG:FPAR REQ,ID=3
mysgw: TSF:PNG:SEND,TO=0
mysgw: TSF:CKU:OK
mysgw: TSF:MSG:GWL OKProgram received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x75cc8450 (LWP 4703)]
0x0001ac74 in RF24_spiMultiByteTransfer (readMode=true, len=6 '\006', buf=0x1 <error: Cannot access memory at address 0x1>, cmd=97 'a') at ./drivers/RF24/RF24.cpp:87
87 *buf++ = *prx++;
(gdb) -
Here is another screenshot - seems that sometimes it works... for some time...
mysgw: TSF:MSG:READ,1-1-0,s=255,c=3,t=6,pt=1,l=1,sg=0:0
mysgw: GWT:TPS:TOPIC=mysensors-out/1/255/3/0/6,MSG SENT
mysgw: TSF:MSG:READ,6-6-0,s=255,c=3,t=24,pt=1,l=1,sg=0:1
mysgw: TSF:MSG:PINGED,ID=6,HP=1
mysgw: TSF:MSG:SEND,0-0-6-6,s=255,c=3,t=25,pt=1,l=1,sg=0,ft=0,st=OK:1
mysgw: TSF:MSG:READ,6-6-0,s=255,c=3,t=15,pt=6,l=2,sg=0:0100
mysgw: TSF:MSG:SEND,0-0-6-6,s=255,c=3,t=15,pt=6,l=2,sg=0,ft=0,st=OK:0100
mysgw: TSF:MSG:READ,6-6-0,s=255,c=0,t=17,pt=0,l=10,sg=0:2.2.0-beta
mysgw: GWT:TPS:TOPIC=mysensors-out/6/255/0/0/17,MSG SENT
mysgw: TSF:MSG:READ,6-6-0,s=255,c=3,t=6,pt=1,l=1,sg=0:0
mysgw: GWT:TPS:TOPIC=mysensors-out/6/255/3/0/6,MSG SENT
mysgw: TSF:MSG:READ,5-5-0,s=255,c=0,t=17,pt=0,l=10,sg=0:2.2.0-beta
mysgw: GWT:TPS:TOPIC=mysensors-out/5/255/0/0/17,MSG SENT
mysgw: TSF:MSG:READ,5-5-0,s=255,c=3,t=6,pt=1,l=1,sg=0:0
mysgw: GWT:TPS:TOPIC=mysensors-out/5/255/3/0/6,MSG SENT
mysgw: TSF:MSG:READ,1-1-0,s=255,c=3,t=11,pt=0,l=10,sg=0:WallLight1
mysgw: GWT:TPS:TOPIC=mysensors-out/1/255/3/0/11,MSG SENT
mysgw: TSF:MSG:READ,1-1-0,s=255,c=3,t=12,pt=0,l=3,sg=0:1.0
mysgw: GWT:TPS:TOPIC=mysensors-out/1/255/3/0/12,MSG SENT
mysgw: TSF:MSG:READ,1-1-0,s=1,c=0,t=4,pt=0,l=0,sg=0:
mysgw: GWT:TPS:TOPIC=mysensors-out/1/1/0/0/4,MSG SENT
mysgw: TSF:MSG:READ,1-1-0,s=255,c=3,t=26,pt=1,l=1,sg=0:2
mysgw: TSF:MSG:SEND,0-0-1-1,s=255,c=3,t=27,pt=1,l=1,sg=0,ft=0,st=OK:1
mysgw: TSF:MSG:READ,1-1-0,s=1,c=1,t=3,pt=2,l=2,sg=0:100
mysgw: GWT:TPS:TOPIC=mysensors-out/1/1/1/0/3,MSG SENT
mysgw: TSF:MSG:READ,3-3-255,s=255,c=3,t=7,pt=0,l=0,sg=0:
mysgw: TSF:MSG:BC
mysgw: TSF:MSG:FPAR REQ,ID=3
mysgw: TSF:CKU:OK,FCTRL
mysgw: TSF:MSG:GWL OK
mysgw: TSF:MSG:SEND,0-0-3-3,s=255,c=3,t=8,pt=1,l=1,sg=0,ft=0,st=OK:0
mysgw: TSF:MSG:READ,4-4-255,s=255,c=3,t=7,pt=0,l=0,sg=0:
mysgw: TSF:MSG:BC
mysgw: TSF:MSG:FPAR REQ,ID=4
mysgw: TSF:CKU:OK,FCTRL
mysgw: TSF:MSG:GWL OK
mysgw: TSF:MSG:SEND,0-0-4-4,s=255,c=3,t=8,pt=1,l=1,sg=0,ft=0,st=OK:0
mysgw: TSF:MSG:READ,6-6-0,s=255,c=3,t=11,pt=0,l=10,sg=0:WallLight6
mysgw: GWT:TPS:TOPIC=mysensors-out/6/255/3/0/11,MSG SENT
mysgw: TSF:MSG:READ,6-6-0,s=255,c=3,t=12,pt=0,l=3,sg=0:1.0
mysgw: GWT:TPS:TOPIC=mysensors-out/6/255/3/0/12,MSG SENT
mysgw: TSF:MSG:READ,6-6-0,s=1,c=0,t=4,pt=0,l=0,sg=0:
mysgw: GWT:TPS:TOPIC=mysensors-out/6/1/0/0/4,MSG SENT
mysgw: TSF:MSG:READ,6-6-0,s=255,c=3,t=26,pt=1,l=1,sg=0:2
mysgw: !TSF:MSG:SEND,0-0-6-6,s=255,c=3,t=27,pt=1,l=1,sg=0,ft=0,st=NACK:1
mysgw: TSF:MSG:READ,5-5-0,s=255,c=3,t=11,pt=0,l=10,sg=0:WallLight5
mysgw: GWT:TPS:TOPIC=mysensors-out/5/255/3/0/11,MSG SENT
mysgw: TSF:MSG:READ,5-5-0,s=255,c=3,t=12,pt=0,l=3,sg=0:1.0
mysgw: GWT:TPS:TOPIC=mysensors-out/5/255/3/0/12,MSG SENT
mysgw: TSF:MSG:READ,5-5-0,s=1,c=0,t=4,pt=0,l=0,sg=0:
mysgw: GWT:TPS:TOPIC=mysensors-out/5/1/0/0/4,MSG SENT
mysgw: TSF:MSG:READ,5-5-0,s=255,c=3,t=26,pt=1,l=1,sg=0:2
mysgw: TSF:MSG:SEND,0-0-5-5,s=255,c=3,t=27,pt=1,l=1,sg=0,ft=0,st=OK:1
mysgw: TSF:MSG:READ,5-5-0,s=1,c=1,t=3,pt=2,l=2,sg=0:100
mysgw: GWT:TPS:TOPIC=mysensors-out/5/1/1/0/3,MSG SENT
mysgw: TSF:MSG:READ,3-3-0,s=255,c=3,t=24,pt=1,l=1,sg=0:1
mysgw: TSF:MSG:PINGED,ID=3,HP=1
mysgw: TSF:MSG:SEND,0-0-3-3,s=255,c=3,t=25,pt=1,l=1,sg=0,ft=0,st=OK:1
mysgw: TSF:MSG:READ,3-3-0,s=255,c=3,t=15,pt=6,l=2,sg=0:0100
mysgw: TSF:MSG:SEND,0-0-3-3,s=255,c=3,t=15,pt=6,l=2,sg=0,ft=0,st=OK:0100
mysgw: TSF:MSG:READ,3-3-0,s=255,c=0,t=17,pt=0,l=10,sg=0:2.2.0-beta
mysgw: GWT:TPS:TOPIC=mysensors-out/3/255/0/0/17,MSG SENT
mysgw: TSF:MSG:READ,3-3-0,s=255,c=3,t=6,pt=1,l=1,sg=0:0
mysgw: GWT:TPS:TOPIC=mysensors-out/3/255/3/0/6,MSG SENT
mysgw: TSF:MSG:READ,4-4-0,s=255,c=3,t=24,pt=1,l=1,sg=0:1
mysgw: TSF:MSG:PINGED,ID=4,HP=1
mysgw: TSF:MSG:SEND,0-0-4-4,s=255,c=3,t=25,pt=1,l=1,sg=0,ft=0,st=OK:1
mysgw: TSF:MSG:READ,4-4-0,s=255,c=3,t=15,pt=6,l=2,sg=0:0100
mysgw: TSF:MSG:SEND,0-0-4-4,s=255,c=3,t=15,pt=6,l=2,sg=0,ft=0,st=OK:0100
mysgw: TSF:MSG:READ,3-3-0,s=255,c=3,t=11,pt=0,l=10,sg=0:WallLight3
mysgw: GWT:TPS:TOPIC=mysensors-out/3/255/3/0/11,MSG SENT
mysgw: TSF:MSG:READ,3-3-0,s=255,c=3,t=12,pt=0,l=3,sg=0:1.0
mysgw: GWT:TPS:TOPIC=mysensors-out/3/255/3/0/12,MSG SENT
mysgw: TSF:MSG:READ,3-3-0,s=1,c=0,t=4,pt=0,l=0,sg=0:
mysgw: GWT:TPS:TOPIC=mysensors-out/3/1/0/0/4,MSG SENT
mysgw: TSF:MSG:READ,3-3-0,s=255,c=3,t=26,pt=1,l=1,sg=0:2
mysgw: TSF:MSG:SEND,0-0-3-3,s=255,c=3,t=27,pt=1,l=1,sg=0,ft=0,st=OK:1
mysgw: TSF:MSG:READ,4-4-0,s=255,c=0,t=17,pt=0,l=10,sg=0:2.2.0-beta
mysgw: GWT:TPS:TOPIC=mysensors-out/4/255/0/0/17,MSG SENT
mysgw: TSF:MSG:READ,3-3-0,s=1,c=1,t=3,pt=2,l=2,sg=0:100
mysgw: GWT:TPS:TOPIC=mysensors-out/3/1/1/0/3,MSG SENT
mysgw: TSF:MSG:READ,4-4-0,s=255,c=3,t=6,pt=1,l=1,sg=0:0
mysgw: GWT:TPS:TOPIC=mysensors-out/4/255/3/0/6,MSG SENT
mysgw: TSF:MSG:READ,4-4-0,s=255,c=3,t=11,pt=0,l=10,sg=0:WallLight4
mysgw: GWT:TPS:TOPIC=mysensors-out/4/255/3/0/11,MSG SENT
mysgw: TSF:MSG:READ,4-4-0,s=255,c=3,t=12,pt=0,l=3,sg=0:1.0
mysgw: GWT:TPS:TOPIC=mysensors-out/4/255/3/0/12,MSG SENT
mysgw: TSF:MSG:READ,4-4-0,s=1,c=0,t=4,pt=0,l=0,sg=0:
mysgw: GWT:TPS:TOPIC=mysensors-out/4/1/0/0/4,MSG SENT
mysgw: TSF:MSG:READ,4-4-0,s=255,c=3,t=26,pt=1,l=1,sg=0:2
mysgw: TSF:MSG:SEND,0-0-4-4,s=255,c=3,t=27,pt=1,l=1,sg=0,ft=0,st=OK:1
mysgw: TSF:MSG:READ,4-4-0,s=1,c=1,t=3,pt=2,l=2,sg=0:100
mysgw: GWT:TPS:TOPIC=mysensors-out/4/1/1/0/3,MSG SENT -
until it crashes...
mysgw: TSF:MSG:BC
mysgw: TSF:MSG:FPAR REQ,ID=3
mysgw: TSF:PNG:SEND,TO=0
mysgw: TSF:CKU:OK
mysgw: TSF:MSG:GWL OKProgram received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x75cc8450 (LWP 4759)]
0x0001ac74 in RF24_spiMultiByteTransfer (readMode=true, len=6 '\006', buf=0x1 <error: Cannot access memory at address 0x1>, cmd=97 'a') at ./drivers/RF24/RF24.cpp:87
87 *buf++ = *prx++; -
until it crashes...
mysgw: TSF:MSG:BC
mysgw: TSF:MSG:FPAR REQ,ID=3
mysgw: TSF:PNG:SEND,TO=0
mysgw: TSF:CKU:OK
mysgw: TSF:MSG:GWL OKProgram received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x75cc8450 (LWP 4759)]
0x0001ac74 in RF24_spiMultiByteTransfer (readMode=true, len=6 '\006', buf=0x1 <error: Cannot access memory at address 0x1>, cmd=97 'a') at ./drivers/RF24/RF24.cpp:87
87 *buf++ = *prx++;@alterfritz thanks. Now we know where in the code the crash occurs. Hopefully @marceloaqno can figure out what's wrong. I'll take a look as well, but I am not familiar with that code so I am not sure I will understand it.
-
Thanks a lot. Looking forward to any update... have a nice weekend, I will try the version for ESP8266 in the meantime, however run it on the pi would be preferred.
Thanks again!
-
Just to let you know - I have uploaded the ESP8266 sketch (from 2.1.1) via Arduino IDE, seems to run stable with the same NRF24L01 module.
But if possible I would like to go back to have all run on the raspi.
Again thanks for all that support here!
-
Just to let you know - I have uploaded the ESP8266 sketch (from 2.1.1) via Arduino IDE, seems to run stable with the same NRF24L01 module.
But if possible I would like to go back to have all run on the raspi.
Again thanks for all that support here!
@alterfritz I've prepared a PR that should fix the segmentation fault: https://github.com/tekka007/MySensors/tree/nullptr - can you test this PR?
-
Many thanks - yes, will do today. Let you know results.
-
Seems this does the trick. Thanks!
-
Seems this does the trick. Thanks!