AllskyTeam / allsky

A Raspberry Pi operated Wireless Allsky Camera
MIT License
1.16k stars 180 forks source link

ERROR: Failed getting image, status = 11 (ASI_ERROR_TIMEOUT) #417

Closed bbillp closed 2 years ago

bbillp commented 3 years ago

Latest ALLSKY 8/10/2021 about 7PM PDT Los Angeles.

Pi 3b+ ZWO ASI178MC

Previous ALLSKY versions worked fine but except a recent version makes the ASI178 run hot

Attached as TEXT Files for the upload here,: config.sh and settings_ZWO.json config.sh.txt settings_ZWO.json.txt

Problem One successful DARK image then ASI_ERROR_TIMEOUT repeats for any image.

In subsequent attempts I tried increasing USB from 40 to 100; autoUSB, reduced photo quality, No luck What next ?

● allsky.service - All Sky Camera Loaded: loaded (/lib/systemd/system/allsky.service; enabled; vendor preset: enabled) Active: active (running) since Tue 2021-08-10 20:01:36 PDT; 11s ago Main PID: 10191 (allsky.sh) CGroup: /system.slice/allsky.service ├─10191 /bin/bash /home/pi/allsky/allsky.sh └─10282 /home/pi/allsky/capture -alwaysshowadvanced 1 -angle -6 -autousb 0 -autowhitebalance 0 -coolerEnabled 0 -darkframe 1 -dayautoexposure 1 -daybin 1 -daybrightness 50 -daydelay 5000 -dayexposure .5 -debuglevel 1 -extratext -extratextage 600 -filename image.jpg -flip 0 -fontcolor 255 255 255 -fontline 1 -fontname 0 -fontsize 7 -fonttype 0 -gaintransitiontime 15 -gamma 50 -height 0 -histogrambox 500 500 50 50 -latitude 33.5N -locale en_US.UTF-8 -longitude 118.1W -nightautoexposure 1 -nightautogain 0 -nightbin 1 -nightbrightness 50 -nightdelay 10 -nightexposure 10000 -nightgain 195 -nightmaxexposure 20000 -nightmaxgain 200 -notificationimages 1 -outlinefont 0 -quality 95 -showBrightness 0 -showExposure 1 -showGain 1 -showHistogram 0 -showTemp 1 -showTime 1 -showhistogrambox 0 -smallfontcolor 0 0 255 -targetTemp 0 -temptype C -text -textlineheight 60 -textx 15 -texty 30 -timeformat %Y%m%d %H:%M:%S -type 99 -usb 90 -wbb 90 -wbr 53 -width 0 -daytime 0 -tty 0

Aug 10 20:01:40 Allsky3B allsky.sh[10191]: Debug Level: 1 Aug 10 20:01:40 Allsky3B allsky.sh[10191]: TTY: 0 (no) Aug 10 20:01:40 Allsky3B allsky.sh[10191]: Aug 10 20:01:40 Allsky3B allsky.sh[10191]: Will NOT adjust gain at transitions Aug 10 20:01:40 Allsky3B allsky.sh[10191]: Stop the allsky service to end this process. Aug 10 20:01:40 Allsky3B allsky.sh[10191]: WARNING: Value of -1 less than min value allowed (32) for control 'Exposure' (#1). Aug 10 20:01:40 Allsky3B allsky.sh[10191]: Taking dark frames... Aug 10 20:01:41 Allsky3B allsky.sh[10191]: > ERROR: Failed getting image, status = 11 (ASI_ERROR_TIMEOUT) Aug 10 20:01:43 Allsky3B allsky.sh[10191]: > ERROR: Failed getting image, status = 11 (ASI_ERROR_TIMEOUT) Aug 10 20:01:46 Allsky3B allsky.sh[10191]: > ERROR: Failed getting image, status = 11 (ASI_ERROR_TIMEOUT)

thomasjacquin commented 3 years ago

Browse the commits and hit the <> button to get a snapshot of the code at a certain time. https://github.com/thomasjacquin/allsky/commits/

I believe this is where the repo was before you committed all the new v0.8 features. https://github.com/thomasjacquin/allsky/tree/cdd7c1e3b332bb3b73361be04e34d94ca502a737

You will have to apply the same logic for the allsky-portal. https://github.com/thomasjacquin/allsky-portal/tree/c7b732c4e2bd5c85bc4839c3c8388cd346213102

manfredwilhelm commented 3 years ago

Hi Eric, sorry, i've been busy at work. I will try to do the changes this weekend.

Am So., 15. Aug. 2021 um 21:55 Uhr schrieb EricClaeys < @.***>:

Manfred, If you're willing, in capture.cpp, please look for the line with ASI_HIGH_SPEED_MODE in it, then try two things:

  1. Put "//" (without quotes) at the beginning of the line, save the file, run "make capture" from the /home/pi/allsky directory, and restart allsky. Look at /var/log/allsky.log - you'll know within 30 seconds if it helped (i.e., look for the TIMEOUT errors).
  2. If # 1 didn't help, remove the "//" from that line and change the "0" to "1", save the file, run "make capture", and restart allsky. Again, look in the log file.
  3. If neither of them helped, try increasing your "USB Bandwidth" to 90 or 100 via the GUI, and look in the log.
  4. If still getting the TIMEOUT error, try setting the "Auto USB" to "Yes".

Let me know how it goes. Since I changed my settings to USB speed 80 and Auto USB to "Yes", I haven't had any problems.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/thomasjacquin/allsky/issues/417#issuecomment-899101808, or unsubscribe https://github.com/notifications/unsubscribe-auth/ALRKPANFALFATABDIHWT73TT5ALR3ANCNFSM5B5NAWRQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&utm_campaign=notification-email .

EricClaeys commented 3 years ago

Manfred, Thanks. Attached is a newer capture.cpp to use, in capture0.8.zip

pierrebilb and others, Also attached is the 0.7 version of capture.cpp that knows about the new 0.8 setting names. If you use it, you will still get many of the other benefits of 0.8, but with the 0.7 capture, and don't need to back anything out. To use it, rename your existing capture.cpp to capture0.8.cpp, then rename capture0.7.cpp to capture.cpp, and run "make capture".

capture0.8.zip capture0.7.zip

22878120 commented 3 years ago

@EricClaeys you saved the day. Thank you. Now my 0.8 version is working without ASI_TIMEOUT_ERROR

Thank you

EricClaeys commented 3 years ago

Glad it works, mhammady911. I've been running it on my test Pi for a couple days with no issues, although as soon as I started running I noticed the ZWO daylight exposure bug - one shot was light, the next couple dark, then light, etc. Version 0.8 fixed that.

I'd like to slowly include additional version 0.8 features into the modified 0.7 capture.cpp file until the ASI_TIMEOUT_ERROR returns, to help determine where the problem is. Would you be willing to help? You'd just need to save the current capture.cpp to a temporary name, then install the new one and recompile and let me know if you see the problem. It tends to happen pretty quickly.

Unfortunately I don't see the problem on either of my two cameras so I have no way to test it myself.

Thanks - Eric

22878120 commented 3 years ago

Hi @EricClaeys, sure, I'd be happy to help. Keep sending me the updated capture.cpp and will test them

pierrebilb commented 3 years ago

Hi, also working for me! I will try the updated capture.cpp as they come. I have an orange pi+2e with a t7 color on a usb2 port.

EricClaeys commented 3 years ago

Thanks in advance for helping, mhammady911 and pierrebilb. I have a hunch the TIMEOUT error is related to the way version 0.8 handles exposures. Version 0.7 would turn on video mode, then take a picture, sleep, take another, sleep, etc., going on until you stopped the program or rebooted the Pi. That meant the camera was constantly taking pictures as fast as it can (which it does in video mode), which would heat up the camera. Version 0.8 starts video mode, takes a picture, stops video mode, then sleeps until the next picture, restarting that sequence. So the camera was only heating up when it was taking pictures, which was dependent on how long a delay you had. For the next test version I think I'll add ALL the other version 0.8 enhancements EXCEPT the video mode one. If that works, we'll know where the issue is, then I can try to find ways around it. Eric

EricClaeys commented 3 years ago

mhammady911 and pierrebilb, Attached is an updated version 0.8 capture.cpp using the 0.7 style of exposure control. Also included is an updated camera_options_ZWO.json file (that goes in /etc/raspap). It has a new option called "Version 0.8 Exposure" that when Yes uses the 0.8 exposure method and when set to No uses the version 0.7 method. Would you please try this and let me know how it goes?

  1. On the GUI "Camera Settings" page at the bottom, click on "Show advanced options". Then set "Version 0.8 Exposure" to Yes. Look in /var/log/allsky.log to see if you get TIMEOUT's. You likely will, but if you don't, see if you can get them by playing with the USB settings.

  2. Then, set "Version 0.8 Exposure" to No. Look in the log to see if you get TIMEOUTs - hopefully you won't.

Thanks much - Eric test_capture_cpp.zip

22878120 commented 3 years ago

Hi Eric,

  1. the "Version 0.8 Exposure" option present only in the json file and not the UI.
  2. As soon as I save the camera settings, it override the new json with original structure
  3. I didnt change the settings of .json to make sure i use the 0.8 exposure settings

the following is the log output

Aug 27 19:39:13 allskycam01 allsky.sh[4490]: === Starting daytime capture === Aug 27 19:39:13 allskycam01 allsky.sh[4490]: ========== Aug 27 19:39:13 allskycam01 allsky.sh[4490]: Saving images with delay of 5,000 ms (5 sec) Aug 27 19:39:13 allskycam01 allsky.sh[4490]: WARNING: Value of 200 greater than max value allowed (100) for control 'AutoExpMaxGain' (#10). Aug 27 19:39:17 allskycam01 allsky.sh[4490]: STARTING EXPOSURE at: 2021-08-27 19:39:17 Aug 27 19:39:17 allskycam01 allsky.sh[4490]: > ERROR: Failed getting image, status = 11 (ASI_ERROR_TIMEOUT) Aug 27 19:39:19 allskycam01 allsky.sh[4490]: STARTING EXPOSURE at: 2021-08-27 19:39:19 Aug 27 19:39:20 allskycam01 allsky.sh[4490]: > ERROR: Failed getting image, status = 11 (ASI_ERROR_TIMEOUT) Aug 27 19:39:22 allskycam01 allsky.sh[4490]: > Saving DAY image 'image.jpg' that started at 2021-08-27 19:39:19 Aug 27 19:39:22 allskycam01 allsky.sh[4490]: jq: error (at /etc/raspap/settings_ZWO.json:592): Cannot index array with string "filename" Aug 27 19:39:22 allskycam01 allsky.sh[4490]: jq: error (at /etc/raspap/settings_ZWO.json:592): Cannot index array with string "darkframe" Aug 27 19:39:22 allskycam01 allsky.sh[4490]: jq: error (at /etc/raspap/settings_ZWO.json:592): Cannot index array with string "filename" Aug 27 19:39:22 allskycam01 allsky.sh[4490]: *** copy_notification_image.sh: ERROR: File 'notification_images/NotRunning.' does not exist or is empty! Aug 27 19:39:22 allskycam01 allsky.sh[4490]: jq: error (at /etc/raspap/settings_ZWO.json:592): Cannot index array with string "notificationimages"

Capture Capture2

EricClaeys commented 3 years ago

mhammady911, You copied the camera_options_ZWO.json file to /etc/raspap, correct? And that file has the "newexposure" setting as shown in your screenshot? What does config.sh have for the settings directory (it'snear the bottom)? /etc/raspap? If so, then the server isn't getting the updated camera_settings_ZWO file. After you install that file you need to refresh your browser window before pressing the "Save changes" button.

Which jason file are referring to: I didnt change the settings of .json to make sure i use the 0.8 exposure settings

The jq errors imply something wrong with the settings_ZWO.json file. Let's not worry about those until you can see the Version 0.8 option in the GUI.

A minor thing but your camera only supports a maximum gain of 100, not 200. Eric

PrimeAmp2016 commented 3 years ago

May not fix the Issue described but for information: I loaded exactly the same 0.8 install on a Pi Zero W and a PI 4 8GB. It worked first time on PI 4 using a ZWO ASI120MC-S but not on PI Zero. After a trying a few variations of the advanced USB settings in the Camera Config to no avail I connected the ZWO via a ANKER powered USB Hub and the ASI_ERROR_TIMEOUT has gone and camera working fine.

EricClaeys commented 3 years ago

PrimeAmp2016, That's good to know. I suspected it was either the camera or Pi hardware causing the issue, since it only happens to certain people, but not others with the same Pi and camera model. But that doesn't explain why it never (?) happened in version 0.7 and sometimes happens in 0.8. Would you please look at the post a few above this where I attached test_capture_cpp.zip, and try it on the Pi Zero withOUT the ANKER? I'm really curious if the version 0.7 exposure method will work but the 0.8 method fails. Before you copy the capture.cpp from the .zip file, rename the current one to capture0.8.cpp, so you can easily restore it if needed. Thanks - Eric

bobhillier99 commented 3 years ago

ZWO ASI183MC bin2 with RPi 4 I would get consistent timeouts using v8 exposure control. Setting the option "Use v8 exposure" to No and I get images.

EricClaeys commented 3 years ago

Bob, Thanks for letting me know. By any chance do you have a powered USB3 hub you could try with the 0.8 exposure control?

PrimeAmp2016, Could you also check if you are getting the following errors in /var/log/kern.log when running in 0.8 mode and the ANKAR?
usb 2-1: reset SuperSpeed Gen 1 USB device number 4 using xhci_hcd

Thanks - Eric

PrimeAmp2016 commented 3 years ago

Attached screen captures show log files as requested. File names reflect connected items. All used AS120MC-S

PiZeroW_ANKER_A7515Hub_Capture ccpFromZipFile(Works) PiZeroW_ASI120MC-S_ANKHER_A7515_7PortPoweredHub PiZeroW_NoHub_Capture ccpFromZipFile(1) PiZeroW_NoHub_Capture ccpFromZipFile

PrimeAmp2016 commented 3 years ago

Top jpeg = PiZeroW_ANKER_A7515Hub_Capture.ccpFromZipFile(Works) Kernal log (works) 2nd jpeg = PiZeroW_ANKER_A7515Hub_Capture.ccpFromZipFile(Works) Kernal log (works) 3rd jpeg = PiZeroW_NoHub_Capture.ccpFromZipFile (does not work) Kernal log Bottom jpeg = PiZeroW_NoHub_Capture.ccpFromZipFile (does not work) Allsky Log

linuxkidd commented 3 years ago

Count me in the crew with the v8 not working.

System:

With 'master' branch:

Aug 31 20:19:28 skycam allsky.sh[11804]: NOTICE: Camera does not support ControlCap # 2; not setting to 50.
Aug 31 20:19:28 skycam allsky.sh[11804]: Will adjust gain at transitions
Aug 31 20:19:28 skycam allsky.sh[11804]: Stop the allsky service to end this process.
Aug 31 20:19:28 skycam allsky.sh[11804]: xxx resetGainTransitionVariables(0, 50) called at NIGHT
Aug 31 20:19:28 skycam allsky.sh[11804]: xxx will not adjust gain right now - numExposures == 0
Aug 31 20:19:28 skycam allsky.sh[11804]: ==========
Aug 31 20:19:28 skycam allsky.sh[11804]: === Starting nighttime capture ===
Aug 31 20:19:28 skycam allsky.sh[11804]: ==========
Aug 31 20:19:28 skycam allsky.sh[11804]: Saving auto exposed night images with delay of 10 ms (0 sec)
Aug 31 20:19:28 skycam allsky.sh[11804]: ===Taking 3 images to clear buffer...
Aug 31 20:19:28 skycam allsky.sh[11804]:   > Exposure set to 30000 µs (30.00 ms), timeout: 560 ms
Aug 31 20:19:28 skycam allsky.sh[11804]:   > ERROR: Failed getting image, status = 11 (ASI_ERROR_TIMEOUT)
Aug 31 20:19:31 skycam allsky.sh[11804]:   > Exposure set to 30000 µs (30.00 ms), timeout: 560 ms
Aug 31 20:19:31 skycam allsky.sh[11804]:   > ERROR: Failed getting image, status = 11 (ASI_ERROR_TIMEOUT)
Aug 31 20:19:34 skycam allsky.sh[11804]:   > Exposure set to 30000 µs (30.00 ms), timeout: 560 ms
Aug 31 20:19:34 skycam allsky.sh[11804]:   > ERROR: Failed getting image, status = 11 (ASI_ERROR_TIMEOUT)
Aug 31 20:19:40 skycam allsky.sh[11804]:      ***** Stopping AllSky *****
Aug 31 20:19:40 skycam allsky.sh[11707]: capture exited with retcode=2

With 'newexposure' disabled:

Aug 31 20:20:37 skycam allsky.sh[12098]: NOTICE: Camera does not support ControlCap # 2; not setting to 50.
Aug 31 20:20:37 skycam allsky.sh[12098]: Will adjust gain at transitions
Aug 31 20:20:37 skycam allsky.sh[12098]: Stop the allsky service to end this process.
Aug 31 20:20:37 skycam allsky.sh[12098]: xxx resetGainTransitionVariables(0, 50) called at NIGHT
Aug 31 20:20:37 skycam allsky.sh[12098]: xxx will not adjust gain right now - numExposures == 0
Aug 31 20:20:37 skycam allsky.sh[12098]: ==========
Aug 31 20:20:37 skycam allsky.sh[12098]: === Starting nighttime capture ===
Aug 31 20:20:37 skycam allsky.sh[12098]: ==========
Aug 31 20:20:37 skycam allsky.sh[12098]: Saving auto exposed night images with delay of 10 ms (0 sec)
Aug 31 20:20:37 skycam allsky.sh[12098]: ===Taking 3 images to clear buffer...
Aug 31 20:20:37 skycam allsky.sh[12098]:   > Exposure set to 30000 µs (30.00 ms), timeout: 560 ms
Aug 31 20:20:38 skycam allsky.sh[12098]:   > ERROR: Failed getting image, status = 11 (ASI_ERROR_TIMEOUT)
Aug 31 20:20:40 skycam allsky.sh[12098]:   > Exposure set to 30000 µs (30.00 ms), timeout: 560 ms
Aug 31 20:20:40 skycam allsky.sh[12098]:   > Got image @ exposure: 30000 µs (30.00 ms)
Aug 31 20:20:40 skycam allsky.sh[12098]:   > Exposure set to 30000 µs (30.00 ms), timeout: 560 ms
Aug 31 20:20:40 skycam allsky.sh[12098]:   > Got image @ exposure: 30000 µs (30.00 ms)
Aug 31 20:20:40 skycam allsky.sh[12098]: ...DONE.  Reset exposure to 10000000 µs
Aug 31 20:20:40 skycam allsky.sh[12098]: STARTING EXPOSURE at: 2021-08-31 20:20:40
Aug 31 20:20:40 skycam allsky.sh[12098]:   > Exposure set to 10000000 µs (10000.00 ms), timeout: 20500 ms
Aug 31 20:20:40 skycam allsky.sh[12098]:   > Got image @ exposure: 14950000 µs (14950.00 ms)
Aug 31 20:20:40 skycam allsky.sh[12098]:   > Saving image 'image.jpg' that started at 2021-08-31 20:20:40  (0 µs)
Aug 31 20:20:40 skycam allsky.sh[12098]:   > Sleeping: 5060 ms
Aug 31 20:20:46 skycam allsky.sh[12098]: STARTING EXPOSURE at: 2021-08-31 20:20:46
Aug 31 20:20:46 skycam allsky.sh[12098]:   > Exposure set to 14950000 µs (14950.00 ms), timeout: 30400 ms
Aug 31 20:20:46 skycam allsky.sh[12098]:   > Got image @ exposure: 14950000 µs (14950.00 ms)
Aug 31 20:20:46 skycam allsky.sh[12098]:   > Saving image 'image.jpg' that started at 2021-08-31 20:20:46  (0 µs)
Aug 31 20:20:46 skycam allsky.sh[12098]:   > Sleeping: 5060 ms
Aug 31 20:20:51 skycam allsky.sh[12098]: STARTING EXPOSURE at: 2021-08-31 20:20:51
Aug 31 20:20:51 skycam allsky.sh[12098]:   > Exposure set to 14950000 µs (14950.00 ms), timeout: 30400 ms
Aug 31 20:20:56 skycam allsky.sh[12098]:   > Got image @ exposure: 12969125 µs (12969.12 ms)
Aug 31 20:20:56 skycam allsky.sh[12098]:   > Saving image 'image.jpg' that started at 2021-08-31 20:20:51  (0 µs)
Aug 31 20:20:56 skycam allsky.sh[12098]:   > Sleeping: 7040 ms

Note:

EricClaeys commented 3 years ago

PrimeAmp2016, Thanks for the info. Interesting that you are still getting all the USB resets even though things are working.

Would you please try the Zero withOUT the ANKER with the capturre.cpp and .json files in the zip file above? You'll need to copy it to /home/pi/allsky, then "cd allsky ; make capture". Then in the GUI, click on the "Show advanced options" at the bottom, and UNcheck the "Version 0.8 Exposure" box. That will force it to use the 0.7 exposure, which I expect will work ok withOUT the ANKER. You'll know you have the correct capture.cpp file running when the log shows "New exposure: yes|no" after the "TTY: line" - about midway in your last screenshot.

If that works for you, you can leave it - no need to revert to the prior version.

linuxkidd commented 3 years ago

@thomasjacquin FYI - PR created with -only- the '-newexposure' option for quick merge.

EricClaeys commented 3 years ago

linuxkidd, Thanks much for the info. It looks like UNchecking the "Version 0.8 exposure" box WORKED for you, correct? The very first image got an ASI_ERROR_TIMEOUT but none of the others did. The first 3 images are never displayed anyhow - they are very short exposures to "flush the buffer", so to speak. If this is working, I suggest leaving it as is. If a few other people tell me that UNchecking that box fixed it for them, I'll ask Thomas to push a high-priority fix.

FYI, the version 0.7 code never checked for timeouts, so everyone may have been getting them and never knowing it.

EricClaeys commented 3 years ago

Michael, I though I recognized your handle "linuxkidd". I helped you when you first started building your observatory at Rusty's. I want to say we dug some holes for the concrete? I remember it was you, me, and another guy. Nice presentation you gave on the AIC. I'm glad the observatory's working for you. I had one built in the mountains by Alamogordo, next to New Mexico Skies. Eric Claeys

linuxkidd commented 3 years ago

@EricClaeys Ha! Small world, eh! :D Thanks for your help with the Obs.. and glad you enjoyed my tAIC presentation. :) We plan to be back out at Rusty's mid October. o/

And yes, setting -newexposure to 0 allowed images to be downloaded. Interesting that there are likely silent USB timeouts due to the original code not checking...

EricClaeys commented 3 years ago

@linuxkidd I would guess there's an underlying hardware/OS issue with either the Pi or the ZWO cameras which causes the USB resets in /var/log/kern.log and sometimes also causes ASI_ERROR_TIMEOUTs in the AllSky software.

The USB reset messages appear every time we turn the ZWO video mode on. In version 0.7 we did that once, and left it on until the program exited. That meant the camera was always taking pictures so it heated up. In version 0.8 we turn video mode on before taking a picture, then turn it off after taking a picture, so the camera is only doing something while taking a picture, not in the delay between pictures. This also means with version 0.8 we see lots of USB reset messages in the kern.log.

I suspect in version 0.7 the first image may have failed for some people but no one noticed - partially due to a bug somewhere that causes the first 3 images to be identical. My test Pi doesn't exhibit the TIMEOUT issue so it's hard for me to test it.

Eric

jryd2000 commented 3 years ago

I can also confirm that using the new "Version 0.8 Exposure" set to No, resolves the issue for me when running an ASI 224MC on a raspberry pi zero W.

PrimeAmp2016 commented 3 years ago

Thank you, I followed your advice Eric and PiZeroW working now without hub and Capture0.7. Kernal log below for your information. Given that Capture0.8 works with a powered Hub the problem may be related to 'loading' of the usb bus. A high bandwidth Oscilloscope may show subtle differences in the USB waveform but it is not really accessible. A bit nugatory now as problem is sorted.

An additional question: Do the log files clear after a period of time? They seem to get rather large.

I certainly appreciate your help in resolving this problem. Thank you again from Lincolnshire UK

PiZeroW_NoHub_Capture0 7 ccp_Working

EricClaeys commented 3 years ago

@jryd2000, thanks for the good news. UNchecking "Version 0.8 Exposure" seems to fixing the TIMEOUT issues for people (not everyone) that was having them.

@PrimeAmp2016, are you running the capture.cpp I included in the .zip file with "Version 0.8 Exposure" unchecked, or are you running the older version 0.7 capture.cpp. It's interesting that you're still getting USB reset messages, but not at consistent times - some a few seconds apart, then about 30 seconds to the next one, then a few seconds apart.

PrimeAmp2016 commented 3 years ago

I used the instructions you gave to mhammady911 6 days ago so I was using the capture0.7.

PrimeAmp2016 commented 3 years ago

Thank you again.

EricClaeys commented 3 years ago

@PrimeAmp2016, forgot to answer your log question. The current log file is renamed allsky.log.1 after some period of time, and a new log file created. I think it's a week but don't quote me. You can decrease what's written to the file by decreasing Log Level in the GUI. If everything is working fine you can set it to 0 and only increase it if you have a problem.

Just for clarification, you are running the capture.cpp I included in the zip file several days ago and have "Version 0.8 Exposure" UNchecked? Eric

PrimeAmp2016 commented 3 years ago

Thank you Eric, I will set debug to '0'.

Yes I am running the capture.ccp included in the zip file several days ago and have 'Version 0.8 Exposure' UNchecked.

EricClaeys commented 3 years ago

Thanks @PrimeAmp2016. You may have noticed an update to capture.cpp and the ZWO .json file that Thomas just posted that fixes the ASI_ERROR_TIMEOUT. You already have the fix so don't need the update on GitHub.

Astrothumb commented 3 years ago

Hi, i'm a french astrophotograph. Just installed the allsky soft on my raspberry with a 120mm ASI camera. And just getting the bug error timeout when i launch the soft.... I didn't really understand if the pb was solved or not... Anyone.would tell me what to.do with this issue ? I tried to change the autousb & USB bandwith, but useless.... Thanks all

EricClaeys commented 3 years ago

Astrothumb, try the attached file. I'm 99% sure I found the issue you are having yesterday and submitted a fix to Thomas, but he hasn't had a chance to post it. The attached file is what I submitted. Copy the file to /home/pi/allsky, then "cd allsky; make capture", then restart the service. Let me know how it goes. Eric capture.zip

Astrothumb commented 3 years ago

Hi Éric !

Thanks a lot. It did the job, after putting the New exposure 0.8 Switch to no.

Now i have to manage getting the right focus with my ASI 120 mini ans the 2,1mm Lens... Tricky...

Thanks gain. Xavier

Le dim. 5 sept. 2021 à 01:27, EricClaeys @.***> a écrit :

Astrothumb, try the attached file. I'm 99% sure I found the issue you are having yesterday and submitted a fix to Thomas, but he hasn't had a chance to post it. The attached file is what I submitted. Copy the file to /home/pi/allsky, then "cd allsky; make capture", then restart the service. Let me know how it goes. Eric capture.zip https://github.com/thomasjacquin/allsky/files/7110637/capture.zip

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/thomasjacquin/allsky/issues/417#issuecomment-913054173, or unsubscribe https://github.com/notifications/unsubscribe-auth/AVPMDXVZDV7HSFWJ7UZ62V3UAKTP3ANCNFSM5B5NAWRQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

bbillp commented 3 years ago

ASI Focus Adjustment: Easy, just use ASICAP or ASI Suite on a windows machine for a live view from the camera. Preset the focus to a very distant tree then the Moon then Jupiter or Saturn. ASICAP and ASI Suite are ZWO software from their site. After setting the focus plug the ASI back into the RPi. Good Luck

Sent from my iPad

On Sep 4, 2021, at 10:22 PM, Astrothumb @.***> wrote:

 Hi Éric !

Thanks a lot. It did the job, after putting the New exposure 0.8 Switch to no.

Now i have to manage getting the right focus with my ASI 120 mini ans the 2,1mm Lens... Tricky...

Thanks gain. Xavier

Le dim. 5 sept. 2021 à 01:27, EricClaeys @.***> a écrit :

Astrothumb, try the attached file. I'm 99% sure I found the issue you are having yesterday and submitted a fix to Thomas, but he hasn't had a chance to post it. The attached file is what I submitted. Copy the file to /home/pi/allsky, then "cd allsky; make capture", then restart the service. Let me know how it goes. Eric capture.zip https://github.com/thomasjacquin/allsky/files/7110637/capture.zip

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/thomasjacquin/allsky/issues/417#issuecomment-913054173, or unsubscribe https://github.com/notifications/unsubscribe-auth/AVPMDXVZDV7HSFWJ7UZ62V3UAKTP3ANCNFSM5B5NAWRQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe. Triage notifications on the go with GitHub Mobile for iOS or Android.

Astrothumb commented 3 years ago

Hi ! Thanks for your answer. I'll now have to wait for the night. But it's quite good. Just needed to go outside for a far point to focus. 👍 Afficher le texte

Le dim. 5 sept. 2021 à 07:42, Bill P. @.***> a écrit :

ASI Focus Adjustment: Easy, just use ASICAP or ASI Suite on a windows machine for a live view from the camera. Preset the focus to a very distant tree then the Moon then Jupiter or Saturn. ASICAP and ASI Suite are ZWO software from their site. After setting the focus plug the ASI back into the RPi. Good Luck

Sent from my iPad

On Sep 4, 2021, at 10:22 PM, Astrothumb @.***> wrote:

 Hi Éric !

Thanks a lot. It did the job, after putting the New exposure 0.8 Switch to no.

Now i have to manage getting the right focus with my ASI 120 mini ans the 2,1mm Lens... Tricky...

Thanks gain. Xavier

Le dim. 5 sept. 2021 à 01:27, EricClaeys @.***> a écrit :

Astrothumb, try the attached file. I'm 99% sure I found the issue you are having yesterday and submitted a fix to Thomas, but he hasn't had a chance to post it. The attached file is what I submitted. Copy the file to /home/pi/allsky, then "cd allsky; make capture", then restart the service. Let me know how it goes. Eric capture.zip https://github.com/thomasjacquin/allsky/files/7110637/capture.zip

— You are receiving this because you commented. Reply to this email directly, view it on GitHub < https://github.com/thomasjacquin/allsky/issues/417#issuecomment-913054173 , or unsubscribe < https://github.com/notifications/unsubscribe-auth/AVPMDXVZDV7HSFWJ7UZ62V3UAKTP3ANCNFSM5B5NAWRQ

. Triage notifications on the go with GitHub Mobile for iOS < https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675

or Android < https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub .

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe. Triage notifications on the go with GitHub Mobile for iOS or Android.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/thomasjacquin/allsky/issues/417#issuecomment-913090757, or unsubscribe https://github.com/notifications/unsubscribe-auth/AVPMDXQWGFOQGXR7XVBIN7DUAL7M3ANCNFSM5B5NAWRQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

maphilli14 commented 3 years ago

I've tried several 0.8 and 0.7 cpp files here to no avail. I'm on a Pi3 and have a 174mm and usb3 cable. This is all I get now with a black screen

 make capture
arm-linux-gnueabihf-g++  capture.cpp -o capture -Wall -Wno-psabi -g -D_LIN -D_DEBUG   -Llib/armv7 -I./include -lpthread  -DGLIBC_20 -I/usr/include/opencv -lopencv_shape -lopencv_stitching -lopencv_superres -lopencv_videostab -lopencv_aruco -lopencv_bgsegm -lopencv_bioinspired -lopencv_ccalib -lopencv_datasets -lopencv_dpm -lopencv_face -lopencv_freetype -lopencv_fuzzy -lopencv_hdf -lopencv_line_descriptor -lopencv_optflow -lopencv_video -lopencv_plot -lopencv_reg -lopencv_saliency -lopencv_stereo -lopencv_structured_light -lopencv_phase_unwrapping -lopencv_rgbd -lopencv_viz -lopencv_surface_matching -lopencv_text -lopencv_ximgproc -lopencv_calib3d -lopencv_features2d -lopencv_flann -lopencv_xobjdetect -lopencv_objdetect -lopencv_ml -lopencv_xphoto -lopencv_highgui -lopencv_videoio -lopencv_imgcodecs -lopencv_photo -lopencv_imgproc -lopencv_core -lASICamera2 -I/usr/include/libusb-1.0 -lusb-1.0
pi@allsky:~/allsky $ sudo service allsky restart

pi@allsky:~/allsky $ sudo service allsky status
● allsky.service - All Sky Camera
   Loaded: loaded (/lib/systemd/system/allsky.service; enabled; vendor preset: enabled)
   Active: activating (auto-restart) (Result: exit-code) since Sun 2021-09-05 11:55:04 EDT; 1s ago
  Process: 3019 ExecStart=/home/pi/allsky/allsky.sh (code=exited, status=2)
 Main PID: 3019 (code=exited, status=2)
pi@allsky:~/allsky $
linuxkidd commented 3 years ago

Astrothumb, try the attached file. I'm 99% sure I found the issue you are having yesterday and submitted a fix to Thomas, but he hasn't had a chance to post it. The attached file is what I submitted. Copy the file to /home/pi/allsky, then "cd allsky; make capture", then restart the service. Let me know how it goes. Eric

Gah, sorry I missed those lines... that's what I get for manually editing and submitting patches on code I can't compile... ( running on bullseye ). Thanks for correcting it @EricClaeys .

EricClaeys commented 3 years ago

@maphilli14, please use the capture.cpp I included in the zip file a few messages above. When you restart the service, look in /var/log/allsky.log. It will give you an idea of the issue. Feel free to post the file (don't just copy/paste, but attach the file instead). Eric

maphilli14 commented 3 years ago

image allsky.log

Thanks Eric! I tried your zipped file, the most recent one and got this result.

EricClaeys commented 3 years ago

maphilli14, Something is stange with the arguments passed to the "capture" program. What does allsky/log.txt look like?

maphilli14 commented 3 years ago

pi@allsky:~/allsky $ cat log.txt
 -alwaysshowadvanced 0 -angle -6 -autousb 1 -autowhitebalance 0 -coolerEnabled 0 -darkframe 0 -dayautoexposure 1 -daybin 1 -daybrightness 50 -daydelay 5000 -dayexposure .5 -debuglevel 1 -extratext -extratextage 600 -filename image.jpg -flip 0 -fontcolor 255 255 255 -fontline 1 -fontname 0 -fontsize 7 -fonttype 0 -gaintransitiontime 15 -gamma 50 -height 0 -histogrambox 500 500 50 50 -latitude 60.7N -locale en_US.UTF-8 -longitude 135.05W -newexposure 0 -nightautoexposure 1 -nightautogain 0 -nightbin 1 -nightbrightness 50 -nightdelay 10 -nightexposure 1000 -nightgain 50 -nightmaxexposure 1000 -nightmaxgain 200 -notificationimages 1 -outlinefont 0 -quality 95 -showBrightness 0 -showExposure 1 -showGain 1 -showHistogram 0 -showTemp 1 -showTime 1 -showhistogrambox 0 -smallfontcolor 0 0 255 -targetTemp 0 -temptype C -text -textlineheight 60 -textx 15 -texty 30 -timeformat %Y%m%d %H:%M:%S -type 99 -usb 80 -wbb 90 -wbr 53 -width 0 -daytime 1 -tty 0

I'm trying the latest branch of allsky too.

EricClaeys commented 3 years ago

@maphilli14, please make sure you are using the latest allsky.sh. Also, please post the /etc/raspap/settings_ZWO.json file.

maphilli14 commented 3 years ago

I did a git and also freshened by hand from github web for /home/pi/allsky/allsky.sh and attached is the settings file, perhaps i'm an outlier using the ASI174mm ??? :( settings_ZWO.zip

EricClaeys commented 3 years ago

@maphilli14, the settings_ZWO.json file you sent is from version 0.7. If you are running version 0.8 of AllSky you'll need to update your settings_ZWO.json file to the version 0.8 one. If you use version 0.7 of the web GUI it creates the correct settings_ZWO.json file (which is in /etc/raspap when using the GUI).

EricClaeys commented 3 years ago

Based on the contents of your log.txt file, I'd guess you are using the GUI and sent the settings_ZWO.json file from ~/allsky, not the one from /etc/raspap? When you install the GUI it copies the settings_ZWO.json file from ~/allsky to /etc/raspap; unfortunately it leaves an unused copy in ~/allsky. If my guess is correct, please stop the allsky service, then "sudo rm /var/log/allsky.log", then in the GUI click on the "Show advanced options button at the bottom and set the debug log to 3, then click the "Save settings" button. Post the first couple hundred lines from /var/log/allsky.log.

azapf1972 commented 3 years ago

OK, joining this one and first of all, thanks for the great piece of software! It perfectly works with my RaspiHQ but I wanted to get my ZWO ASI 120 MM connected and that results in the discussed ASI_ERROR_TIMEOUT as well (Raspberry 4 Model B). I tried what was stated above (got the updated capture.cpp and recompiled it, set the NewExposure switch to off and play a bit with the AutoUSB and USB Bandwith settings (no success). I also tried both, a USB3 and a USB2 connection - both works on the ZWO ASI Studio, none work at the moment with AllSkyCam. So following :)

PS: I tried this with my ZWO ASI 533 as well - just to make sure that it was not something with that model of the ZWO ASI Cameras... same result ;)

allsky.log settings_ZWO.json.txt

EricClaeys commented 3 years ago

@azapf1972, Please check that you are running the newest capture.cpp. There should be a line in the log stating whether or not Version 0.8 Exposure is yes or no. It would be next to this line: Sep 8 16:19:26 ASCZWO allsky.sh[859]: TTY: 0 (no) Eric

mpv1953 commented 3 years ago

Hello! I posted this in entry #460 before I saw this thread. I'm having the same issue. This is a brand new install of RPiOS (Buster), headless with no GUI installed. I'm using an ASI120MC, and have tried using a Pi3 and a Pi4 with no joy either time. I loaded the ZWO SDK and compiled their demos. The demos work, so I know the camera is working and reachable by the Pi. Thanks, Mike