[SOLVED] indi_asi_ccd crashed on ASI ZWO 183MM capture

any question related to our SDK and driver

Moderators: yang, ray, chad

[SOLVED] indi_asi_ccd crashed on ASI ZWO 183MM capture

Postby sywong2000 » Sun Jan 07, 2018 2:47 pm

Using KStars EKOS was able to connect to the ASI ZWO 183MM Pro.
But crashed on Preview or Capturing... anybody help? Here's the log, see below in RED
Looks like indi asi not yet compatible with this camera yet?



org.kde.kstars.indi: INDI: Starting local drivers...
org.kde.kstars.indi: Starting INDI Server: ("-v", "-p", "7624", "-m", "100", "-f", "/tmp/indififo332d64f8") -f "/tmp/indififo332d64f8"
org.kde.kstars.indi: INDI Server Started? true
org.kde.kstars.indi: INDI: INDI Server started locally on port 7624
org.kde.kstars.indi: Starting INDI Driver "indi_asi_ccd"
org.kde.kstars.indi: Adding managed driver "ZWO CCD"
org.kde.kstars.indi: INDIListener: Adding a new client manager to INDI listener..
org.kde.kstars.indi: INDI: Connecting to local INDI server on port 7624 ...
org.kde.kstars.indi: INDI server connected.
org.kde.kstars.indi: Connection to INDI server is successful
org.kde.kstars.indi: INDI Server: "2018-01-07T13:09:51: startup: /usr/bin/indiserver -v -p 7624 -m 100 -f /tmp/indififo332d64f8 "
org.kde.kstars.indi: INDI Server: "2018-01-07T13:09:51: listening to port 7624 on fd 3"
org.kde.kstars.indi: INDI Server: "FIFO: start indi_asi_ccd"
org.kde.kstars.indi: INDI Server: "FIFO: Starting driver indi_asi_ccd"
org.kde.kstars.indi: INDI Server: "2018-01-07T13:09:51: Driver indi_asi_ccd: pid=4146 rfd=4 wfd=7 efd=8"
org.kde.kstars.indi: INDI Server: "2018-01-07T13:09:51: Client 5: new arrival from 127.0.0.1:47212 - welcome!"
org.kde.kstars.indi: INDI Server: ""
org.kde.kstars.indi: Received new device ZWO CCD ASI183MM Pro
org.kde.kstars.indi: INDI Server: "2018-01-07T13:09:51: Driver indi_asi_ccd: snooping on Telescope Simulator.EQUATORIAL_EOD_COORD"
org.kde.kstars.indi: INDI Server: "2018-01-07T13:09:51: Driver indi_asi_ccd: snooping on Telescope Simulator.TELESCOPE_INFO"
org.kde.kstars.indi: INDI Server: "2018-01-07T13:09:51: Driver indi_asi_ccd: snooping on Telescope Simulator.GEOGRAPHIC_COORD"
org.kde.kstars.indi: INDI Server: "2018-01-07T13:09:51: Driver indi_asi_ccd: snooping on Focuser Simulator.ABS_ROTATOR_ANGLE"
org.kde.kstars.indi: INDI Server: "2018-01-07T13:09:51: Driver indi_asi_ccd: snooping on CCD Simulator.FILTER_SLOT"
org.kde.kstars.indi: INDI Server: "2018-01-07T13:09:51: Driver indi_asi_ccd: snooping on CCD Simulator.FILTER_NAME"
org.kde.kstars.indi: INDI Server: "2018-01-07T13:09:51: Driver indi_asi_ccd: snooping on SQM.SKY_QUALITY"
org.kde.kstars.indi: INDI Server: ""
org.kde.kstars.indi: INDIListener: New device ZWO CCD ASI183MM Pro
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < CONNECTION >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < DRIVER_INFO >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < DEBUG >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < SIMULATION >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < CONFIG_PROCESS >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < ACTIVE_DEVICES >
org.kde.kstars.ekos: 1 devices connected out of 1
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < CCD_EXPOSURE >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < CCD_ABORT_EXPOSURE >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < CCD_FRAME >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < CCD_BINNING >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < FITS_HEADER >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < CCD_TEMPERATURE >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < CCD_INFO >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < CCD_COMPRESSION >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < CCD1 >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < CCD_FRAME_TYPE >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < CCD_FRAME_RESET >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < CCD_RAPID_GUIDE >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < TELESCOPE_TYPE >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < WCS_CONTROL >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < UPLOAD_MODE >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < UPLOAD_SETTINGS >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < CCD_VIDEO_STREAM >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < STREAM_OPTIONS >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < FPS >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < RECORD_STREAM >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < RECORD_FILE >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < RECORD_OPTIONS >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < CCD_STREAM_FRAME >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < CCD_STREAM_ENCODER >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < CCD_STREAM_RECORDER >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < CCD_COOLER_POWER >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < CCD_COOLER >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < CCD_CONTROLS >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < CCD_CONTROLS_MODE >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < CCD_VIDEO_FORMAT >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < DEBUG_LEVEL >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < LOGGING_LEVEL >
org.kde.kstars.indi: < ZWO CCD ASI183MM Pro >: < LOG_OUTPUT >
org.kde.kstars.indi: ZWO CCD ASI183MM Pro : "[DEBUG] Toggle Debug Level -- Driver Debug "
org.kde.kstars.indi: ZWO CCD ASI183MM Pro : "[DEBUG] Toggle Logging Level -- Driver Debug "
org.kde.kstars.ekos.capture: Preparing capture job "Light" for execution.
org.kde.kstars.indi: ZWO CCD ASI183MM Pro : "[DEBUG] StartExposure->setexp : 1.000s "
org.kde.kstars.indi: ZWO CCD ASI183MM Pro : "[DEBUG] ASIGetExpStatus failed (0). Restarting exposure... "
org.kde.kstars.indi: ZWO CCD ASI183MM Pro : "[DEBUG] StartExposure->setexp : 1.000s "
org.kde.kstars.indi: ZWO CCD ASI183MM Pro : "[DEBUG] ASIGetExpStatus failed (0). Restarting exposure... "
org.kde.kstars.indi: ZWO CCD ASI183MM Pro : "[DEBUG] StartExposure->setexp : 1.000s "
*** stack smashing detected ***: terminated
org.kde.kstars.indi: INDI Server: "2018-01-07T13:10:16: Driver indi_asi_ccd: stderr EOF"
org.kde.kstars.indi: INDI Server: "2018-01-07T13:10:16: Driver indi_asi_ccd: restart #1"
org.kde.kstars.indi: INDI Server: "2018-01-07T13:10:16: Driver indi_asi_ccd: pid=4165 rfd=4 wfd=8 efd=9"
org.kde.kstars.indi: INDI Server: "Child process 4146 died"
org.kde.kstars.indi: INDI Server: "2018-01-07T13:10:16: Driver indi_asi_ccd: snooping on Telescope Simulator.EQUATORIAL_EOD_COORD"
org.kde.kstars.indi: INDI Server: "2018-01-07T13:10:16: Driver indi_asi_ccd: snooping on Telescope Simulator.TELESCOPE_INFO"
org.kde.kstars.indi: INDI Server: "2018-01-07T13:10:16: Driver indi_asi_ccd: snooping on Telescope Simulator.GEOGRAPHIC_COORD"
org.kde.kstars.indi: INDI Server: "2018-01-07T13:10:16: Driver indi_asi_ccd: snooping on Focuser Simulator.ABS_ROTATOR_ANGLE"
org.kde.kstars.indi: INDI Server: "2018-01-07T13:10:16: Driver indi_asi_ccd: snooping on CCD Simulator.FILTER_SLOT"
org.kde.kstars.indi: INDI Server: "2018-01-07T13:10:16: Driver indi_asi_ccd: snooping on CCD Simulator.FILTER_NAME"
org.kde.kstars.indi: INDI Server: "2018-01-07T13:10:16: Driver indi_asi_ccd: snooping on SQM.SKY_QUALITY"
org.kde.kstars.indi: INDI Server: ""
org.kde.kstars.indi: INDI driver "indi_asi_ccd" crashed!
Last edited by sywong2000 on Wed Jan 17, 2018 3:49 am, edited 1 time in total.
sywong2000
 
Posts: 13
Joined: Sun Jan 07, 2018 2:45 pm

Re: indi_asi_ccd crashed when start capturing for ASI ZWO 18

Postby wulfblat » Sun Jan 07, 2018 3:34 pm

You should post this error to the indilib forum, but include details such as the OS (be sure to include if it is 64 bit or not), plus the camera control settings you have used -- especially the format (8 bit, 16 bit, or whatever).

If you provide this information here I can look at the code to see if there is an obvious error.

I have been working on the indi-asi driver in a local repo over the past week and have found and corrected numerous issues, but I am not sure I've seen anything that would cause a crash during an exposure.

I can make available a debug version of indi-asi for 64 bit Linux if you are interested.

Leonard
User avatar
wulfblat
 
Posts: 13
Joined: Thu Jan 04, 2018 4:19 pm
Location: Prineville, OR USA

Re: indi_asi_ccd crashed when start capturing for ASI ZWO 18

Postby chad » Mon Jan 08, 2018 3:09 am

Hi,
Please try to test it in sharpcap. I am not sure the reason, by testing it in sharpcap, You can exclude some camera problems and most of our software problems.
Thanks
chad
ZWO Driver Engineer
Location:lon=120.6 lat=31.3
SuZhou China
User avatar
chad
 
Posts: 229
Joined: Thu Feb 09, 2017 4:58 am

Re: indi_asi_ccd crashed when start capturing for ASI ZWO 18

Postby sywong2000 » Tue Jan 09, 2018 5:57 am

Leonard,
Thank you and I did post in indilib.. may be we can discuss it in indi forum. Anyways my OS was 32 bit ubuntu (on Rpi3), and I'm trying to capture in RAW 8 Bit. I'm not sure if you'd get me a 32bit version package (or github and send me the instructions to compile the indi-asi) so I can try to get the source and work on sending back the debug info.

Chad,
Thanks for the suggestion. I tested in both SharpCap 3.0 and Firecapture (2.6 beta) and both works fine in Windows platform. (Firecapture 2.5 did not work though but i think it's due to the old API being used.)

So pretty sure the camera is working fine. Likely it's INDI driver compatibility issue yet to be resolved for the new camera.

Thanks again,
Stephen
sywong2000
 
Posts: 13
Joined: Sun Jan 07, 2018 2:45 pm

Re: indi_asi_ccd crashed when start capturing for ASI ZWO 18

Postby wulfblat » Tue Jan 09, 2018 6:12 am

I saw your post on the indi forum, and tried to reply but there seems to be an issue with my replies and they either take 24 hours to show up, or simply go missing.

The issue for building a debug version of the indi asi ccd driver is not just 32 bit or 64 bit: I have all Intel (x64) based hardware, and the RP uses a different cpu altogether. I need to download the RP cross platform tool kit and see if it lets me build a binary for your platform. Unfortunately I will have no way to verify it other than to have you try it.

Based upon the indi log output you originally provided the driver started the exposure, and then the get status API returned the failed exposure status, and so the driver tried again with the same result, and some time after it tried for the third time it crashed.

Do you have gdb installed on your system? If so you can temporarily enable core files before starting the indiserver (ulimit -c unlimited) then recreate the crash (and disable core files again via "ulimit -c 0"). Find the core file (its name should be in the format core.<number>) and use gdb to obtain the stack trace from the core file.

gdb /usr/bin/indi_asi_ccd <core file name>
thread apply all where
quit

Leonard
User avatar
wulfblat
 
Posts: 13
Joined: Thu Jan 04, 2018 4:19 pm
Location: Prineville, OR USA

Re: indi_asi_ccd crashed when start capturing for ASI ZWO 18

Postby chad » Tue Jan 09, 2018 9:51 am

Sorry to answer you so later. I will test it on our Rp3 tomorrow。And I will keep you update if any further information.
Thanks
chad
ZWO Driver Engineer
Location:lon=120.6 lat=31.3
SuZhou China
User avatar
chad
 
Posts: 229
Joined: Thu Feb 09, 2017 4:58 am

Re: indi_asi_ccd crashed when start capturing for ASI ZWO 18

Postby sywong2000 » Tue Jan 09, 2018 10:50 am

Hi Leonard and chad
Thanks for your reply and I will try getting the stacktrace and post it here once I got it
Thanks
Stephen
sywong2000
 
Posts: 13
Joined: Sun Jan 07, 2018 2:45 pm

Re: indi_asi_ccd crashed when start capturing for ASI ZWO 18

Postby sywong2000 » Tue Jan 09, 2018 3:21 pm

Hi Leonard,
This is the gdb dump after the crash.
let me know if you need more info. Thanks.


ubuntu@ubuntu-standard:~$ gdb /usr/bin/indi_asi_ccd ./core
GNU gdb (Ubuntu 7.11.1-0ubuntu1~16.5) 7.11.1
Copyright (C) 2016 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 /usr/bin/indi_asi_ccd...(no debugging symbols found)...done.
[New LWP 19821]
[New LWP 19804]
[New LWP 19810]
[New LWP 19812]a
[New LWP 19811]
[New LWP 19813]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/arm-linux-gnueabihf/libthread_db.so.1".
threaCore was generated by `indi_asi_ccd'.
Program terminated with signal SIGABRT, Aborted.
#0 __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.
[Current thread is 1 (Thread 0x62cc3450 (LWP 19821))]
d(gdb) thread apply all where

Thread 6 (Thread 0x664ff450 (LWP 19813)):
#0 __libc_do_syscall () at ../sysdeps/unix/sysv/linux/arm/libc-do-syscall.S:46
#1 0x76d8bdba in __pthread_cond_wait (cond=0x55099510, mutex=0x55099540)
at pthread_cond_wait.c:186
#2 0x54aeb86e in ASICCD::streamVideo() ()
#3 0x54aeb9b4 in ASICCD::streamVideoHelper(void*) ()
#4 0x76d875b4 in start_thread (arg=0x0) at pthread_create.c:335
#5 0x76b64bec in ?? () at ../sysdeps/unix/sysv/linux/arm/clone.S:89
from /lib/arm-linux-gnueabihf/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)

Thread 5 (Thread 0x6e97e450 (LWP 19811)):
#0 __libc_do_syscall () at ../sysdeps/unix/sysv/linux/arm/libc-do-syscall.S:46
#1 0x76d8bdba in __pthread_cond_wait (cond=0x550a86fc, mutex=0x550a872c)
at pthread_cond_wait.c:186
#2 0x54b67142 in ?? ()
#3 0x76d875b4 in start_thread (arg=0x0) at pthread_create.c:335
#4 0x76b64bec in ?? () at ../sysdeps/unix/sysv/linux/arm/clone.S:89
from /lib/arm-linux-gnueabihf/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)

Thread 4 (Thread 0x66e01450 (LWP 19812)):
---Type <return> to continue, or q <return> to quit---
#0 0x76b41e20 in nanosleep () at ../sysdeps/unix/syscall-template.S:84
#1 0x76b60acc in usleep (useconds=10000) at ../sysdeps/posix/usleep.c:32
#2 0x54b65686 in ?? ()
#3 0x76d875b4 in start_thread (arg=0x0) at pthread_create.c:335
#4 0x76b64bec in ?? () at ../sysdeps/unix/sysv/linux/arm/clone.S:89
from /lib/arm-linux-gnueabihf/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
Thread 3 (Thread 0x7651d450 (LWP 19810)):
#0 0x76b5eb90 in poll () at ../sysdeps/unix/syscall-template.S:84
#1 0x76db0f4c in poll (__timeout=-1, __nfds=2, __fds=0x7651ce34)
at /usr/include/arm-linux-gnueabihf/bits/poll2.h:46
#2 linux_udev_event_thread_main (arg=<optimized out>)
at ../../libusb/os/linux_udev.c:175
#3 0x76d875b4 in start_thread (arg=0x0) at pthread_create.c:335
#4 0x76b64bec in ?? () at ../sysdeps/unix/sysv/linux/arm/clone.S:89
from /lib/arm-linux-gnueabihf/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)

Thread 2 (Thread 0x76f35000 (LWP 19804)):
#0 0x76b60472 in select () at ../sysdeps/unix/syscall-template.S:84
#1 0x76decdae in ?? () from /usr/lib/arm-linux-gnueabihf/libindidriver.so.1
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
---Type <return> to continue, or q <return> to quit---

Thread 1 (Thread 0x62cc3450 (LWP 19821)):
#0 __libc_do_syscall () at ../sysdeps/unix/sysv/linux/arm/libc-do-syscall.S:47
#1 0x76af6648 in __GI_raise (sig=sig@entry=6)
at ../sysdeps/unix/sysv/linux/raise.c:54
#2 0x76af734a in __GI_abort () at abort.c:89
#3 0x76b1d5a6 in __libc_message (do_abort=do_abort@entry=1,
fmt=0x76ba0c14 "*** %s ***: %s terminated\n")
at ../sysdeps/posix/libc_fatal.c:175
#4 0x76b7039a in __GI___fortify_fail (
msg=0x76ba0bf4 "stack smashing detected") at fortify_fail.c:37
#5 0x76b7035e in __stack_chk_fail () at stack_chk_fail.c:28
#6 0x76dad77a in libusb_control_transfer (dev_handle=0x550bf750,
bmRequestType=<optimized out>, bRequest=<optimized out>,
wValue=<optimized out>, wIndex=0, data=0x0, wLength=0, timeout=200)
at ../../libusb/sync.c:157
#7 0x54b65a84 in CCameraFX3::SendCMD(unsigned char) ()
#8 0x54b40b2e in ?? ()
#9 0x76d875b4 in start_thread (arg=0x0) at pthread_create.c:335
#10 0x76b64bec in ?? () at ../sysdeps/unix/sysv/linux/arm/clone.S:89
from /lib/arm-linux-gnueabihf/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
(gdb)
sywong2000
 
Posts: 13
Joined: Sun Jan 07, 2018 2:45 pm

Re: indi_asi_ccd crashed when start capturing for ASI ZWO 18

Postby wulfblat » Tue Jan 09, 2018 5:38 pm

Thanks for the stack trace. The faulting thread was the last one displayed, and it is down in the libusb code, which I believe is used by the ASI SDK.

You can enable debug logging for the ASI SDK by editing ~/.ZWO/ASIconfig.xml and setting a non-zero value for DebugPrint for your camera.

For example:

<DebugPrint type="3">01</DebugPrint>

Now restart indiserver and enable verbose logging for the CCD in Ekos (logging to a file makes it easier to capture).

Post the results when it crashes.

If need be you can also enable debug logging for libusb, but let's see what the ASI SDK reports for the crash first.
User avatar
wulfblat
 
Posts: 13
Joined: Thu Jan 04, 2018 4:19 pm
Location: Prineville, OR USA

Re: indi_asi_ccd crashed when start capturing for ASI ZWO 18

Postby chad » Wed Jan 10, 2018 7:13 am

Hi,
We downloaded a new indi source code, compiled and installed on our raspberry pi, running with our latest SDK, it works fine。
So could you update your indi to the latest version and have a try?
Thanks
chad
ZWO Driver Engineer
Location:lon=120.6 lat=31.3
SuZhou China
User avatar
chad
 
Posts: 229
Joined: Thu Feb 09, 2017 4:58 am

Next

Return to SDK & Driver

Who is online

Users browsing this forum: No registered users and 2 guests