×
INDI Library v1.8.1 Released (09 Sep 2019)

Monthly maintenance release INDI v1.8.1

Moonlite-like focuser

3 months 2 weeks ago 3 months 2 weeks ago by patdut.
patdut
Platinum Boarder
Platinum Boarder
Posts: 349
Karma: 1
More
Topic Author
Moonlite-like focuser #40690
Hello all ,
I am recompiling an old program for arduino that use <strong>moonlite protocol</strong> without temperature driving.
Without any mods the program don't works anymore. I use AccelStepper as lib. And the position is coded on long word.
I can connect the arduino to Ekos without problem.
The problem occurs when I try to move to an absolute position greater 65536 or when going back to 0. When I try to go to 6553<strong>7</strong> the counter in Ekos is reset to 0 reaching 65536 and on the decreasing direction the counter is reset to 65536 reaching 0. Looks like if the counter is a short integer (16bits).
I must mention that this program worked fine in the past.
I use for those tests the nightly build of Ekos.

Please Log in or Create an account to join the conversation.

3 months 2 weeks ago
ChrisRowland
Gold Boarder
Gold Boarder
Posts: 193
Karma: 5
More
Moonlite-like focuser #40692
The Moonlite focuser only uses 16 bit numbers so you can't have a value of 65537, the maximum range is 0 to 65535.

Please Log in or Create an account to join the conversation.

3 months 2 weeks ago
patdut
Platinum Boarder
Platinum Boarder
Posts: 349
Karma: 1
More
Topic Author
Moonlite-like focuser #40693
Well that is the answer. Unfortunately my moonlite-like is based on a sketch that worked fine in the past with the moonlite driver of Ekos. So it didn't include this limitation.
Would be nice to have an open driver which use moonlite protocol and would be parametrized on number of steps to avoid such limitations.

Please Log in or Create an account to join the conversation.

3 months 2 weeks ago
ChrisRowland
Gold Boarder
Gold Boarder
Posts: 193
Karma: 5
More
Moonlite-like focuser #40694
If you want to use a driver that's designed for other hardware then you have to make your hardware compatible with the hardware for which the driver is designed.

Changing the driver to suit your incompatible hardware could easily break it for the correct hardware.

Please Log in or Create an account to join the conversation.

3 months 2 weeks ago
patdut
Platinum Boarder
Platinum Boarder
Posts: 349
Karma: 1
More
Topic Author
Moonlite-like focuser #40696
You are right. I will rewrite a specific driver for my setup.

Please Log in or Create an account to join the conversation.

Time to create page: 0.370 seconds