The Arduino Focuser is an effort to make a computer controlled focuser using an Arduino, a Motor Shield and a bipolar stepper motor. The project consists of the Arduino code for the firmware and also an ASCOM driver to control the focuser from any ASCOM compliant software such as MaxIm DL.
- Download an install the ASCOM driver from the downloads page.
- Download and install the Arduino IDE.
- Download the source code.
- Connect your Arduino to your computer and compile and upload the firmware within the "firmware" directory in the source code.
The driver installer will fail if you have ASCOM 6 installed. You can use the workaround detailed at http://ascom-standards.org/FAQs/Platform5.5only.htm to get around this.
Since the Arduino Focuser is based on the Arduino board, the focuser is controlled through the COM port created by the Arduino. This is accomplished by parsing serial commands sent from the ASCOM Driver. When a command is received in the : command <arg> #
format, the Messenger object is passed to the Focuser::interpretCommand()
function, which looks at the command
and acts accordingly.
The following commands are currently available:
-
: M <position> #
Moves the focuser toposition
. -
: L #
Issues a motor.release(). Some steppers get pretty hot when the coils are not released. -
: R <0-1> #
Reverses motor direction. 0=false, 1=true. -
: P <position> #
Sets the current position toposition
. Note, this does not issue a move, it just tells the focuser that it's at said position. -
: G #
Prints out the current position to the serial port. Useful for syncing. -
: H #
Doesn't really do anything since anything in the serial buffer will halt the motor. Just prettier. -
Uses the AFMotor library and a modified Messenger library.
-
Code is for the motor shield from adafruit industries.