This little beast is a highly featured piece of kit. It's not the cheapest servo money can buy, but it is certainly very versatile, and delivers a serious bang for your buck.


Public Member Functions |
|
| AX12 (PinName tx, PinName rx, int ID, int baud=1000000) | |
|
Create an
AX12
servo object connected to the specified serial port, with the specified ID.
|
|
| int | SetMode (int mode) |
|
Set the mode of the servo.
|
|
| int | SetBaud (int baud) |
|
Set baud rate of all attached servos.
|
|
| int | SetGoal (int degrees, int flags=0) |
|
Set goal angle in integer degrees, in positional mode.
|
|
| int | SetCRSpeed (float speed) |
|
Set the speed of the servo in continuous rotation mode.
|
|
| int | SetCWLimit (int degrees) |
|
Set the clockwise limit of the servo.
|
|
| int | SetCCWLimit (int degrees) |
|
Set the counter-clockwise limit of the servo.
|
|
| int | SetID (int CurrentID, int NewID) |
|
Change the ID of a servo.
|
|
| int | isMoving (void) |
|
Poll to see if the servo is moving.
|
|
| void | trigger (void) |
|
Send the broadcast "trigger" command, to activate any outstanding registered commands.
|
|
| float | GetPosition () |
|
Read the current angle of the servo.
|
|
| float | GetTemp (void) |
|
Read the temperature of the servo.
|
|
| float | GetVolts (void) |
|
Read the supply voltage of the servo.
|
|
The headline features of the AX12 are:
It is really mechanically sound too, and comes with a mounting plate, a bracket to fit to the spindle and plenty of nuts and bolts to bolt it all together. It has been designed so that one servo canbe mounted on the spindle of another so you can do multple degrees of freedom just by mounting them on eachother.
If you want to read more details about the development of this library, the full write-up can be found at :
Please login to post comments.
I've tried the library and 'Hello World' out on my AX12+ and I'm having some issues getting it going. It's powered up with a separate 9v supply and wired as above, however, all I'm getting is a 'click' and the LED on the back flashing once (at the same time). I've tried two different servos and on different serial pins but I'm getting the same issues on all of them.
I'll have a more detailed look myself when I get the chance, just wondering if you had any insights for a possible cause.
Joe