ANZAC Day
Go Back   IceInSpace > Equipment > Software and Computers
Register FAQ Calendar Today's Posts Search

Reply
 
Thread Tools Rate Thread
  #1  
Old 10-07-2017, 10:23 PM
alocky's Avatar
alocky (Andrew lockwood)
PI popular people's front

alocky is offline
 
Join Date: Aug 2010
Location: perth australia
Posts: 1,291
Anyone here written an ASCOM driver for a focuser?

Hi - wondering if any of the programmers on here could help out an old fortran programmer with some of the mysteries of ASCOM programming? I'm trying to write a focus driver that acts as a wrapper for an exisiting one so I can correct some 'bad behaviour' in the output.
I've got it all set up in C# and even built the standard ASCOM driver, but now have some very stupid questions!
cheers,
Andrew.
Reply With Quote
  #2  
Old 11-07-2017, 09:32 AM
trent_julie's Avatar
trent_julie
Registered User

trent_julie is offline
 
Join Date: Nov 2008
Location: Canberra
Posts: 581
Hi Andrew,
I have written an ASCOM safety monitor driver before. Also written control software for ASCOM focussers previously I would be happy to have a chat to see if I can help.

Kind Regards,

Trent
Reply With Quote
  #3  
Old 11-07-2017, 10:44 AM
alocky's Avatar
alocky (Andrew lockwood)
PI popular people's front

alocky is offline
 
Join Date: Aug 2010
Location: perth australia
Posts: 1,291
Thanks Trent! I'll pm you when I'm back home.
Cheers
Andrew.
Reply With Quote
  #4  
Old 12-07-2017, 10:12 PM
luka's Avatar
luka
Unregistered User

luka is offline
 
Join Date: Apr 2007
Location: Perth, Australia
Posts: 1,164
If you need more help I wrote ASCOM drivers for a camera and Observing Conditions before. Not for a focuser though.
Reply With Quote
  #5  
Old 14-07-2017, 09:56 AM
alocky's Avatar
alocky (Andrew lockwood)
PI popular people's front

alocky is offline
 
Join Date: Aug 2010
Location: perth australia
Posts: 1,291
Quote:
Originally Posted by luka View Post
If you need more help I wrote ASCOM drivers for a camera and Observing Conditions before. Not for a focuser though.
Hi Luka - I'd certainly appreciate a bit of help! The problem is that my new focuser has an absolute position encoder that reports it's position in microns. This number is not stable, and the last digit typically switches back and forwards by a micron every second or two.
The software I'm using to control all of this (Sequence Generator) is expecting the reported focuser position to be exactly what it requested, so during a focus run it will ultimately give up and report that the focuser did not reach the requested position.
What I want to do is write another driver to act as an intermediary- and either filter the position being reported, or return a focus position identical to the last request providing it is within tolerance.
If you've got time to catch up over a coffee or beer to give me some direction I'd be very grateful!
Cheers
Andrew.
Reply With Quote
  #6  
Old 15-07-2017, 10:16 PM
luka's Avatar
luka
Unregistered User

luka is offline
 
Join Date: Apr 2007
Location: Perth, Australia
Posts: 1,164
Hi Andrew, coffee would be great but I am stretched very thin until the middle of the week after next so probably can't make it before then.


Two ways you can approach the problem:
1. Write the intermediary driver - take the ASCOM template for focuser and then pass all the calls to the DLL of the original driver. Then you only need to modify the position reading to include the tolerance.
2. If you have the focuser commands, you can probably use an existing ASCOM focuser source code (there are few on the net) as a starting point and then just re-implement the commands.

Just wondering, is this a problem with your focuser or with the model? If latter the manufacturer should be fixing the issue?
Reply With Quote
  #7  
Old 16-07-2017, 12:46 PM
alocky's Avatar
alocky (Andrew lockwood)
PI popular people's front

alocky is offline
 
Join Date: Aug 2010
Location: perth australia
Posts: 1,291
Thanks Luka,
I'll take you up on that in week or so then.
The focuser position change seems to be common to all of these new ASA focuser, but the manufacturer seems to think it's a feature rather than a bug, and since the way it works is by constantly adjusting the focuser to maintain the measured position the reported position probably does change by a micron. In Practice, the critical focus zone for this scope is 30 microns so a 1 micron change is insignificant- and focusmax, ASA's own sequence software have no trouble with this.
Unfortunately, I'm trying to use SGPro for observatory control, as so far it's my preference. But I can see the path of least resistance is going to be getting another sequence program to do the work.
Anyway - figured it's about time I grew up and learnt to code in C#...

Quote:
Originally Posted by luka View Post
Hi Andrew, coffee would be great but I am stretched very thin until the middle of the week after next so probably can't make it before then.


Two ways you can approach the problem:
1. Write the intermediary driver - take the ASCOM template for focuser and then pass all the calls to the DLL of the original driver. Then you only need to modify the position reading to include the tolerance.
2. If you have the focuser commands, you can probably use an existing ASCOM focuser source code (there are few on the net) as a starting point and then just re-implement the commands.

Just wondering, is this a problem with your focuser or with the model? If latter the manufacturer should be fixing the issue?
Reply With Quote
Reply

Bookmarks


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +10. The time is now 11:57 PM.

Powered by vBulletin Version 3.8.7 | Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Advertisement
Bintel
Advertisement
Testar
Advertisement