SUMMARY KStars running on RPi4 (Stellarmate) seems to crash 3-4 images into an imaging sequence with this large-format camera. A single image shows memory use climb from 33 to 66%, but as KStars continues to image, this climbs to 100%. Then CPU pegs at 100% as well. At this point either KStars crashes, or it does not crash and the entire machine locks up and must be power-cycled. STEPS TO REPRODUCE 1. Connect ASI6200MC-P. Monitor CPU/memory via VNC or Stellarmate app. 2. Configure capture module to take 100 frames binned 1x1. 3. 3-4 frames in, KStars will fail. OBSERVED RESULT KStars crashes or machine hangs. EXPECTED RESULT SOFTWARE/OS VERSIONS Windows: macOS: Linux/KDE Plasma: Stellarmate 1.5.5 (available in About System) KDE Plasma Version: KDE Frameworks Version: Qt Version: ADDITIONAL INFORMATION I wonder if RPi4 is just not powerful enough (especially the 4GB memory limit) for these huge images. However, is there a way to turn off the FITS viewer to avoid that memory overhead? Hopefully there's no memory leak there, but I did notice that after each frame, the %memory increased higher than the previous frame.
Note: RPi4 was not overheating. It has a cooling fan, and it is in a refrigerator at 34°F (I'm taking darks for this new camera). Also, this crash/hang seems to happen even if I am just looping images. Also, adding a delay of 5 seconds between exposures didn't seem to help (I was thinking capturing one image while trying to load another into FITS Viewer was just too much). These are 113 MByte image files, but RPi 4 has 3GB free memory when I start. I'm confused why this is causing a problem.
I was able to capture successfully using KStars on macOS Big Sur running on a Mac mini with 16GB RAM. However, that is undesired because it is not as stable as Linux (6 crashes last night) and I'm not crazy about strapping a $1000 Mac mini to my pier at a remote site. QUESTION 1: Is this a software bug that might be fixed, or do I really need more than 4GB RAM for these 13MB images? QUESTION 2: If I connect to RPI4 via KStars/Ekos running on my laptop (connecting to Indi Server on the RPI4), would it consume less memory/CPU? I can't try this as we're clouded over. QUESTION 3: Do you think an RPI4 board with 8GB RAM would help, or would we still have a high CPU utilization problem? Note, I did not enable features that consume more memory/CPU. I try to keep the config as default as possible for troubleshooting purposes. I am ready to buy an 8GB RPi4 if you think it will help. Alternatively, I might opt for a more powerful Mini PC running Linux, but I prefer StellarMate's pre-configured design.
Unfortunately the 8GB version of the RPi4 did not resolve this issue. While I never saw memory climb much above 3.3GB according to the task manager, KStars continued to crash after 3-5 frames. I am attaching the logs. Note, after several attempts I could not get any exposures from the camera until I rebooted the RPi. On the Mac Mini, I was able to capture almost 3000 exposures (building libraries for the new camera) with no crashes. Until this is resolved, I think you need to put a warning on the KStars/Stellarmate FAQs so people know this camera (or perhaps all high-megapixel cameras) might not be reliable. I would also warn them that buying a RPi 8GB won't necessarily help. I learned that $95 lesson the hard way. :-)
Created attachment 134107 [details] Crash log
Thank you for the update, the log shows it stops when reading the file. It would be better to arrange for teamviewer session to debug the rpi4 in more detail. Once teamviewer is installed, please share the details privately to my email or send me private message on INDI forum.
Just a note for the ticket, Jasem was able to connect and noted that as soon as KStars approached 2GB RAM, it crashed. It should be able to use 3GB in this x86 kernel, so it's a mystery that he is researching. +1 for full 64-bit support! :-)
Btw, I'm still checking why we can't use the supposedly 3GB limit for App. 3GB would be more than enough.
Another full-frame camera has graced my doorstep, so this issue will now affect both my RPis. Hopefully we can find a solution for this mystery.
I started investigating this issue in depth now.
I believe this just happened with my new ASI294MM-Pro in 1x1 binning mode. I'll try to reproduce again, but I'm not sure I'll be using this camera tonight.
Please check against KStars 3.6.1 and report back.
Unfortunately I don't believe I'll be able to conveniently test this, but in the more than year and a half since reporting the issue I'm sure others have had some experience with the issue. Please close.