Linux Serial Port and Roboteq Library

14 years 1 week ago #12996139 by Camel85kv
Linux Serial Port and Roboteq Library was created by Camel85kv
I've used the AX3500 for a couple different Linux-based robotics projects, such as and and I have quite a bit of serial port code I'm willing to release. It's on my personal website as a part of my Open Source Robot Controls libraries. I have written the shell of a fully-featured Roboteq library.

I think this is a necessary extension to the Roboteq product should help others use it in a Linux environment. To use my code, you need these files (available at in the "src" and "include" folders):


Then, using the motor controller is as simple as putting the following lines in your C++ file and compiling it using GCC or something similar:

#include "../include/roboteq.h"

void main() {
Roboteq ax3500; // Creates an instance of the Roboteq class = "/dev/ttyS0"; // Name of serial port used
ax3500.connect(); // Connects to the Roboteq
ax3500.setSpeed(1, DIRECTION_FORWARD, 50); // Go FORWARD at speed 50

This was a quick example, but there is more documentation at (Click on "Class List", then "Serial" or "Roboteq") There are also a few applications I've written that use the Roboteq and a sample makefile in the code folder listed above that may be useful. Note: Not all functions listed in the documentation are implemented yet, but it should be trivial to fill in the functions that I haven't written.

The Serial class can be used by itself, and is much more complete than the Roboteq class. If you have trouble with the Roboteq class, just use the Serial class and write your own wrapper for the Roboteq. Please send me an email if you found this to be useful!

Kyle Vogt

*** EDIT: Added a page dedicated to this library at ***

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

Moderators: tonysantoni
Time to create page: 0.145 seconds