Hello Robin,
With the QHY-174GPS, it is possible to set the time of the computer with the time coming from the camera GPS.
Is it possible to do the same from a script ?
My idea is to have the time set at the beginning of my script.
Regards,
Jean-Francois
Setting the computer time from a script
-
- Posts: 417
- Joined: Sun Oct 13, 2019 10:52 am
- Location: Germany
- admin
- Site Admin
- Posts: 13529
- Joined: Sat Feb 11, 2017 3:52 pm
- Location: Vale of the White Horse, UK
- Contact:
Re: Setting the computer time from a script
Hi,
it's non-trivial to try to set the system time from within SharpCap IronPython - you have to declare a class with special attributes to allow calling SetSystemTime from kernel32.dll - it's probably easier to launch a power shell script to do the same using Set-Date which is built into PowerShell.
https://learn.microsoft.com/en-us/power ... rshell-7.4
cheers,
Robin
it's non-trivial to try to set the system time from within SharpCap IronPython - you have to declare a class with special attributes to allow calling SetSystemTime from kernel32.dll - it's probably easier to launch a power shell script to do the same using Set-Date which is built into PowerShell.
https://learn.microsoft.com/en-us/power ... rshell-7.4
cheers,
Robin
-
- Posts: 417
- Joined: Sun Oct 13, 2019 10:52 am
- Location: Germany
Re: Setting the computer time from a script
Hello Robin,
OK, not so easy. I will first do it manually.
Jean-Francois
OK, not so easy. I will first do it manually.
Jean-Francois