jlecomte / ascom-telescope-cover Goto Github PK
View Code? Open in Web Editor NEWOpen Source ASCOM-Compatible Telescope Cover For Astrophotography
License: MIT License
Open Source ASCOM-Compatible Telescope Cover For Astrophotography
License: MIT License
Hi,
First, I'd like to thank you for this great project. It has been working flawlessly in my remote observatory for the past year!
I'm planning on adding a second camera with an attached telephoto lens piggyback on top of the scope I am currently using and would like to also equip it with one of your covers. Is it possible to control two covers using two instances of NINA from a single computer?
Thank you so much for your time.
Sincerely,
Arnie (OregonAstronomer)
NINA doesn't work with your ASCOM driver. It can connect and open the cover fine. But after asking NINA to open the cover, it times out, preventing me from closing the cover.
I ran the driver along with NINA in Visual Studio to investigate this and I think I know what happens. When lauching the driver, NINA has the switch defaulted to Off and the cover is closed by default of course. All is well for now. When activating the switch to open the cover, it does so and NINA starts polling the GetSwitchValue method and it expects it to return a 1 when the switch is ON ( i.e cover open). Your driver outputs the opposite. It happens here :
public double GetSwitchValue(short id)
{
Validate("GetSwitchValue", id);
tl.LogMessage("GetSwitchValue", $"GetSwitchValue({id}) - not implemented");
return QueryDeviceState() ? 1.0 : 0.0;
}
So the solution is simple :
return QueryDeviceState() ? 0.0 : 1.0;
and also
internal static string traceStateDefault = "true";
Maybe a switch driver is not the best option for this application.
Personnaly I would have used a Flatplanel template for the driver, instead of a switch. Even if you don't have an actual flat panel in the cover, the template provides the methods for the motorised part. So you can just leave the flat side in the code and just implement the motor part.
Also I already have a power box occupying the switch part of NINA, so it's not helpful to have to change driver just to move the cover.
Hello,
I've successfully prepared slightly modified flat panel and telescope cover projects which I am very thankful for. I managed to register both drivers and setup properly the flat panel in Nina. However, I cannot launch the cover in the Nina software. It says both that the switch is connected, but then also prompts that there is invalid response from the cover. Can you help me investigating this issue?
The cover properly shows up in the device manager as a com port, I can send the commands through the COM terminal so I know the cover works, but I cannot launch it with NINA. I am using the newest dll and firmware is uploaded to Arduino Nano.
Hello Julien,
Vincent from France. Many thanks for your project ! I'm currently making a cover for my remote telescope.
This is just an idea. Is it possible to control 2 servos from the Xiao at the same time instead of one ? My telescope has a diameter of 250 mm and I'm not able to make a dust cap in just one piece. I need to use 2 parts in shapes of half-circle.
Do you think it could be difficult to add this feature, by changing the Xiao firmware only ?
I think I will try for fun !
Vincent
Hello Julien,
No issue, no pull request, just a thought. My name is Jean-Francois, I live in France, and I am a (low level) astrophotographer.
I use NINA and Ascom devices. My setup is EQ6-R / Askar FRA600 /ASI2600color.
I was seeking for an automated dust cap for my telescope and I found your videos ! (Dark Sky Geek)
You did such a great job for 2 projects in which I am interested : dust cap and focuser.
I am not a developer and I discovered your channel today !
I bought hardware stepper-motors drivers called TIC from Pololu and I did a small GUI to drive manually stepper-motors.
This was easy, but to integate TIC with NINA (native or Ascom) is much to dffificult for me.
A stepper-motor and a stepper motor is much less expensive that any Zwo, Pegasus or else equipment.
If for any reason, you plan to use Pololu TIC hardware to drive stepper-motors for your new projects, please let me know.
Sincerely
Jean-Francois
[email protected]
...but i cannot regasm the assembly.
My Visual Studio 2019 refuses to install as COM the resulting dll.
"RA0000 .... is not a valid assembly."
I'm a programmer but not expert with C# and Visual studio in general. Is there something I've to change in order to compile and install the driver?
I ask to you because:
Thanks in every case for your project. I've customized the original cap/legs/base for my scope (a 20cm newton) and all went well.
Dear Julien,
Thanks for making the cover as well as flat panel available.
Converted the cad files to Fusion360 to make them fit my scope. Combined both flat panel and cover functionality.
Honesty my mistake of not having used an SAMD21 / Seeeduino XIAO before. What a powerful tiny piece of electronics.
Instead the usual servo lib I'm using one called slowServo allowing good control of the speed and it is working asynchronously and not blocking when servo moves. It therewith better follows the ASCOM specs like reporting status when moving.
The fact of fast closure move on power-up when cover is not closed I could overcome by writing either panel open, closed or moving to the Flash memory of the XIAO. Therewith current cover status remains on power up, unless the XIAO is disconnected while servo is moving. In this case the cover opens on the re-connection, as feels more save to me before moving fast into the dew shield.
3d parts are printed, cover is moving but wiring is still on a breadboard. Will assemble it next days and happily share some pictures.
Kind regards from Germany,
Alex
Hi,
First of all, be aware that I'm in no way a professional developer :)
With the driver you built, I wasn't able to get the full course of my 270deg. servo. A quick investigation revealed that the default values provided by Servo.h when attaching the servo (min pulse width = 544 and max pulse width = 2400) were not ideal for my setup. (Using the cheap servos from Amazon that you listed).
Instead of just editing the Arduino code with alternative (and fixed) values, I decided to add 'pulse min' and 'pulse max' as part of the Ascom driver profile.
While I was there, I also added the servo write "delay" as a parameter too. (the default value 30 isn't the best for my setup).
The three parameters are sent to the Arduino upon connection of the device in Nina. Please check how it's parsed on the Arduino side; it's a little dirty... (but it works :) )
I have no idea how I can properly share my code with you or if you're even interested. I'm simply attaching a ZIP below that contains both the driver and the Arduino file. Let me know if there is a better method.
Motorized_cover_guillaume.zip
Comments/critics very welcome!
-Guillaume
PS: Awesome job you did there! I already built two motorized covers, including one for my C11 and, despite the large size, it works perfectly.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.