×

INDI Library v2.0.6 is Released (02 Feb 2024)

Bi-monthly release with minor bug fixes and improvements

SOLVED Wunderground ~ crashes on Odroid-C1 (15.04)

  • Posts: 2247
  • Thank you received: 223
Wunderground crashes on Odroid-C1 running Ubuntu 15.04

root@heidenrod-obs:/# uname -a
Linux heidenrod-obs 3.10.66-49 #1 SMP PREEMPT Fri Jan 30 22:17:03 BRST 2015 armv7l armv7l armv7l GNU/Linux
root@heidenrod-obs:/#

root@heidenrod-obs:/# lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 15.04
Release: 15.04
Codename: vivid
root@heidenrod-obs:/#

root@heidenrod-obs:/home/heidenrod# dpkg -l | grep indi- | awk '{print $2 " \t" $3}'
indi-bin 1.1.0+r874.225~ubuntu15.04.1
indi-dbg 1.1.0+r874.225~ubuntu15.04.1
indi-eqmod 0.2+r73.224~ubuntu15.04.1
indi-qhy 1.4+r40.224~ubuntu15.04.1
indi-qhy-dbg 1.4+r40.224~ubuntu15.04.1
indi-sx 1.4+r131.224~ubuntu15.04.1
indi-sx-dbg 1.4+r131.224~ubuntu15.04.1
libindi-data 1.1.0+r874.225~ubuntu15.04.1
libindi-dev 1.1.0+r874.225~ubuntu15.04.1
root@heidenrod-obs:/home/heidenrod#



I ran a gdb as per the 'READ before you post any support request" post.
root@heidenrod-obs:/home/heidenrod# gdb --eval-command="set follow-fork-mode child" --args indiserver -v indi_wunderground_weather 
GNU gdb (Ubuntu 7.9-1ubuntu1) 7.9
Copyright (C) 2015 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 indiserver...Reading symbols from /usr/lib/debug//usr/bin/indiserver...done.
done.
(gdb) run
Starting program: /usr/bin/indiserver -v indi_wunderground_weather
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/arm-linux-gnueabihf/libthread_db.so.1".
2015-09-15T17:04:02: startup: /usr/bin/indiserver -v indi_wunderground_weather 
[New process 31564]
2015-09-15T17:04:02: Driver indi_wunderground_weather: pid=31564 rfd=3 wfd=6 efd=7
2015-09-15T17:04:02: listening to port 7624 on fd 4
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/arm-linux-gnueabihf/libthread_db.so.1".
process 31564 is executing new program: /usr/bin/indi_wunderground_weather
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/arm-linux-gnueabihf/libthread_db.so.1".
2015-09-15T17:04:03: Driver indi_wunderground_weather: snooping on GPS Simulator.GEOGRAPHIC_COORD
2015-09-15T17:04:17: Client 0: new arrival from 217.71.199.185:52826 - welcome!
[New Thread 0xb5f4f430 (LWP 31874)]
[Thread 0xb5f4f430 (LWP 31874) exited]
2015-09-15T17:05:51: Driver indi_wunderground_weather: indi_wunderground_weather: /build/libindi-CFJN5O/libindi-1.1.0+r874.225~ubuntu15.04.1/drivers/weather/gason.h:55: JsonValue::JsonValue(JsonTag, void*): Assertion `(uint64_t)payload <= 0x00007FFFFFFFFFFFULL' failed.
 
Program received signal SIGABRT, Aborted.
[Switching to Thread 0xb6ff9000 (LWP 31564)]
__libc_do_syscall () at ../sysdeps/unix/sysv/linux/arm/libc-do-syscall.S:47
47	../sysdeps/unix/sysv/linux/arm/libc-do-syscall.S: No such file or directory.
(gdb)
 
(gdb) bt
#0  __libc_do_syscall () at ../sysdeps/unix/sysv/linux/arm/libc-do-syscall.S:47
#1  0xb6d0c62e in __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:55
#2  0xb6d0d332 in __GI_abort () at abort.c:89
#3  0xb6d0798a in __assert_fail_base (fmt=0x1 <error: Cannot access memory at address 0x1>, 
    assertion=0x1395c "(uint64_t)payload <= 0x00007", 'F' <repeats 11 times>, "ULL", assertion@entry=0x2 <error: Cannot access memory at address 0x2>, 
    file=file@entry=0xb5f51000 "\001", line=55, line@entry=3067949192, 
    function=function@entry=0x138d8 <JsonValue::JsonValue(JsonTag, void*)::__PRETTY_FUNCTION__> "JsonValue::JsonValue(JsonTag, void*)") at assert.c:92
#4  0xb6d07a22 in __GI___assert_fail (assertion=0x2 <error: Cannot access memory at address 0x2>, file=0xb5f51000 "\001", line=3067949192, 
    function=0x138d8 <JsonValue::JsonValue(JsonTag, void*)::__PRETTY_FUNCTION__> "JsonValue::JsonValue(JsonTag, void*)") at assert.c:101
#5  0x0001282c in JsonValue (payload=<optimized out>, tag=<optimized out>, this=<optimized out>)
    at /build/libindi-CFJN5O/libindi-1.1.0+r874.225~ubuntu15.04.1/drivers/weather/gason.h:55
#6  jsonParse (s=0xb6dd3088 <lock> "", 
    s@entry=0xbeffe2d8 "\n{\n  \"response\": {\n  \"version\":\"0.1\",\n  \"termsofService\":\"http://www.wunderground.com/weather/api/d/terms.html\",\n  \"features\": {\n  \"conditions\": 1\n  }\n\t}\n  ,\t\"current_observation\": {\n\t\t\"image\": {\n\t\t\"u"..., endptr=0xbeffed50, endptr@entry=0xbeffed90, 
    value=0x1395c, value@entry=0xbeffeda8, allocator=...) at /build/libindi-CFJN5O/libindi-1.1.0+r874.225~ubuntu15.04.1/drivers/weather/gason.cpp:198
#7  0x00012b50 in WunderGround::updateWeather (this=0x3ba58)
    at /build/libindi-CFJN5O/libindi-1.1.0+r874.225~ubuntu15.04.1/drivers/weather/wunderground.cpp:221
#8  0xb6f37c64 in INDI::Weather::TimerHit (this=0x3ba58) at /build/libindi-CFJN5O/libindi-1.1.0+r874.225~ubuntu15.04.1/libs/indibase/indiweather.cpp:277
#9  0xb6f1f4c2 in checkTimer () at /build/libindi-CFJN5O/libindi-1.1.0+r874.225~ubuntu15.04.1/eventloop.c:369
#10 oneLoop () at /build/libindi-CFJN5O/libindi-1.1.0+r874.225~ubuntu15.04.1/eventloop.c:428
#11 0xb6f1f5a2 in eventLoop () at /build/libindi-CFJN5O/libindi-1.1.0+r874.225~ubuntu15.04.1/eventloop.c:105
#12 0xb6f18b74 in main (ac=0, av=<optimized out>) at /build/libindi-CFJN5O/libindi-1.1.0+r874.225~ubuntu15.04.1/indidrivermain.c:97
#13 0xb6cfe776 in __libc_start_main (main=0x11c6c <main@plt>, argc=1, argv=0xbefff804, init=<optimized out>, fini=0x13899 <__libc_csu_fini>, 
    rtld_fini=0xb6fe2add <_dl_fini>, stack_end=0xbefff804) at libc-start.c:289
#14 0x00011f30 in _start ()
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
(gdb)


The driver works well on the VM.
Last edit: 8 years 6 months ago by Gonzothegreat.
8 years 6 months ago #5105

Please Log in or Create an account to join the conversation.

  • Posts: 2247
  • Thank you received: 223
After much diy debugging..... I believe the issue lies with the Odroid-C1 which somehow add \n and \r to files.
I'll be digging into this and will report once fixed.
8 years 6 months ago #5107

Please Log in or Create an account to join the conversation.

  • Posts: 2247
  • Thank you received: 223
great news !!!! It is now fixed on the Odroid-c1

With the great help of a Gason contributor, he was able to find out why it crashed.
root@heidenrod-obs:/home/jasem/Projects/indi/trunk/libindi/drivers/weather# diff gason.h gason.h-old 
55c55
<         assert(([b]uintptr_t[/b])payload <= JSON_VALUE_PAYLOAD_MASK);
---
>         assert(([b]uint64t[/b])payload <= JSON_VALUE_PAYLOAD_MASK);
root@heidenrod-obs:/home/jasem/Projects/indi/trunk/libindi/drivers/weather#


I have compiled it and I can confirm that WunderGround weather works well on the Odroid-C1
8 years 6 months ago #5117

Please Log in or Create an account to join the conversation.

  • Posts: 2247
  • Thank you received: 223
slight addition, the line should be:
assert((uint64_t)(uintptr_t)payload <= JSON_VALUE_PAYLOAD_MASK);
8 years 6 months ago #5118

Please Log in or Create an account to join the conversation.

Time to create page: 0.245 seconds