Author Topic: INDIClient caused PixInsight crash  (Read 2209 times)

Offline wimvb

  • PixInsight Enthusiast
  • **
  • Posts: 91
    • Wims place
INDIClient caused PixInsight crash
« on: 2016 November 20 12:52:31 »
This is a FYI, rather than a plea for help.
Yesterday I used the INDIClient (CCD and device controller) when I lost my network connection. This caused a crash
My setup is:
Indiserver running on a Raspberry Pi connecting to my home network (Wifi)
INDIClient running on windows 8 on my Acer laptop.
The wifi adapter of my laptop has a very short range, and apparently I moved outside this. This caused me to lose connection to the indi server and PixInsight to freeze.
On another occasion the same night, the CCD client lost contact with the server and didn't disconnect properly. Closing the device controller in INDIClient, caused an error and crash.
I think that the error is caused by the CCD client trying to communicate with a device that isn't there anymore. I would expect the client to exit gracefully when losing network connection, or to simply time out with a notification.


Cheers,

Wim
Wim

AZ EQ6 GT + EQ3 PRO, SW 150P-DS, SW MN190, ZWO ASI174MM-Cool, Pentax K20D (retired),
SW ST80 + ZWO ASI120MM + Lin_guider

Offline Juan Conejero

  • PTeam Member
  • PixInsight Jedi Grand Master
  • ********
  • Posts: 7111
    • http://pixinsight.com/
Re: INDIClient caused PixInsight crash
« Reply #1 on: 2016 November 23 16:09:55 »
Hi Wim,

Quote
Yesterday I used the INDIClient (CCD and device controller) when I lost my network connection. This caused a crash

I'm not sure if solving these issues is within our reach. Currently network connections are managed internally by INDI, not by our module. The client/server communication code we use is part of the INDI SDK, and it certainly can be greatly improved. We'll eventually rewrite it completely, and then the INDI module will be much more robust for sure. Sorry for the trouble.
Juan Conejero
PixInsight Development Team
http://pixinsight.com/

Offline kkretzsch

  • PTeam Member
  • PixInsight Addict
  • ***
  • Posts: 217
Re: INDIClient caused PixInsight crash
« Reply #2 on: 2016 November 24 01:42:56 »
The wifi adapter of my laptop has a very short range, and apparently I moved outside this.
I know the problem of running INDI in a weak network, I also use indiserver on a raspberrypi connected with WIFI to my home network. This sometimes causes network stalls which of course the INDIClient should handle properly. I use PI running on a Linux Laptop and don't see those crashes at least there.
Quote
I would expect the client to exit gracefully when losing network connection, or to simply time out with a notification.
I agree. As Juan wrote we use the network connection API provided by the indiclient. However, the code which ports this part to windows was actually done by me. So I'll look into it. Does this crash happens often? Is it reproducible?

Thanks for reporting the issue.
Klaus

Offline wimvb

  • PixInsight Enthusiast
  • **
  • Posts: 91
    • Wims place
Re: INDIClient caused PixInsight crash
« Reply #3 on: 2016 November 28 04:39:18 »
Thanks for the replies, Juan and Klaus.
The post was more of a heads up than a bug report, and I understand that some software issues are out of your control. That's the way it is with collaborated software.
Klaus, the network loss happened on several occasions during one imaging night. But each time it was related to my moving the client computer. Since then I haven't used the INDI software, mainly because of the bad weather we've had since then. (Another issue that is not under your control :D )
On the night in question, it was my laptop (ACER) which runs the INDI client, that lost its network connection. This happens intermittantly, and is probably due to a low quality network card. I've lost network connections from this computer on several occasions, completely unrelated to INDI. But I would very much appreciate that the INDI software doesn't crash when the network is lost. My concern is mainly for the future development of this software. At some time in the future, I guess, the INDI client will have a pointing model stored, and I wouldn't want to lose that kind of information during an imaging session. Or what would happen when the INDI client loses connection during a slew?

Thank you both for your work with this great software package.

Wim
Wim

AZ EQ6 GT + EQ3 PRO, SW 150P-DS, SW MN190, ZWO ASI174MM-Cool, Pentax K20D (retired),
SW ST80 + ZWO ASI120MM + Lin_guider

Offline kkretzsch

  • PTeam Member
  • PixInsight Addict
  • ***
  • Posts: 217
Re: INDIClient caused PixInsight crash
« Reply #4 on: 2016 November 30 11:58:24 »
Hi Wim,
thanks for providing the details. I tried to reproduce the issue on my Windows desktop but didnt't succed so far. But I found that  error handling can indeed be much improved  ;)
Quote
At some time in the future, I guess, the INDI client will have a pointing model stored
Yes I am currently working on creating and applying telescope pointing models to improve the pointing accuracy. I already have a prototype which works quite well and yes it is possible to store the parameters of the model in a file. The long-term goal is a fully automated acquisition process, and an accurate pointing model is one of the prerequisites.
Quote
Or what would happen when the INDI client loses connection during a slew?
A GOTOis completely controlled by the indiserver on the remote host. The client only sends the GOTO command and waits until the command has finished. So when the network is lost the GOTO will finish without problems. A SLEW command, however,  indeed is more problematic, since the user/client sends the start-slew and the stop-slew command. So indeed if you start the slew, and the network is lost it will not finish until you have reconnected.

Reconnecting  with the Linux/Mac client works without problems, I'll continue to investigate the issues on the windows client ...

Thanks,
Klaus

Offline wimvb

  • PixInsight Enthusiast
  • **
  • Posts: 91
    • Wims place
Re: INDIClient caused PixInsight crash
« Reply #5 on: 2016 November 30 15:27:25 »
Hi Klaus,

thanks for your update. At the moment I don't use the INDI client. My camera is only used stand alone (faulty usb on my old DSLR), so there is no immediate need for me to use the INDI client. But I'll keep an eye on things, and when I get the error again, I'll try to gather as much information as possible, and report back to you.

Regards,

Wim
Wim

AZ EQ6 GT + EQ3 PRO, SW 150P-DS, SW MN190, ZWO ASI174MM-Cool, Pentax K20D (retired),
SW ST80 + ZWO ASI120MM + Lin_guider