Where can I find more detailed descriptions of the LSS.cpp library functions?

There’s a lot of interesting functions in the library that I’d like to try, but I can’t find any further info other than some sparse commenting. Does anyone know where I can find more information on the LSS library functions?


  1. What is the T parameter in the LSS::moveT() function? (there’s a “T” keyword in LSS.h related to “ActionParameterTime”)
  2. What is the CH parameter in the LSS::moveCH() function? (possibly related to “ActionParameterCurrentHold”? Maybe this moves the servo towards a desired position as far as a set motor current will allow?)
  3. In the advanced config section, there’s a function called setAngularAcceleration(int16_t value, LSS_SetType setType). Is that first argument supposed to be an integer value, in units of rad/s^2?

There’s a lot of other functions in this library that would be so useful if I could figure out exactly what kind of arguments they expect. If anyone could point me to further documentation that would be very appreciated.

1 Like

Hello @Cucumber_Harvester,

I think this is what you did but for other users that might have the same question, you can simply check the header file, there you can find an overview of what the keywords stand for.

You can find more information about these commands in the LSS Wiki, specifically in the Communication Protocol Wiki:

Here are the links for the commands you had questions about:

  1. Timed move ( T ) modifier
  2. Current Halt & Hold ( CH ) modifier
  3. Angular Acceleration ( AA )

Let us know if you have any other doubts :grin:

1 Like

@geraldinebc15 Great answer! :slight_smile:

Just go ahead and try them! :slight_smile:
More seriously, the LSS have built-in protections for over voltage, over temperature and over current so just go wild. Worse case your LSS ends up in safe mode and you need to either power cycle it or send a #[id]RESET\r command to it.

Everyone of those functions in the library are just a specific implementation of a generic #[id][cmd][value][param][paramValue]\r command format, where [value] and [param][paramValue] are optional or not needed (depends on the command used).

As @geraldinebc15 explained, you can look up in the header file the meaning of specific things, such as LSS_ActionParameterTime which is simply the letter “T”.

The T parameter is an amount of ms over which the move will happen. In the case of moveT, the function is declared as:

bool LSS::moveT(int16_t value, int16_t t_value)

This indicates you can need two signed values, one for the desired position (the “D” part in 1/10°) and the other signed value for the desired duration (the “T” part, in ms).
So, a typical command such as #1D900T2500\r would become something like myLSS.moveT(900, 2500);.

If you follow @geraldinebc15 link here, you’ll learn that the moveCH() allows you to provide a position (again in 1/10°) and a current limit (in mA). When sent, the LSS will either complete the move as requested or if it ever exceeds the current limit set, stop the motion and hold there, slightly pushing against the object. This is very helpful for a gripper, for example, where you want the gripper to close and hold an object but a normal move() (“D” command) would cause the gripper to go into safe mode if it moved into an object (stalled!).

Again, @geraldinebc15 provided some good links. I suggest you read the protocol page as a whole. It is full of useful information about the LSS and how to use them. Of course, feel free to ask any other questions you may have! :slight_smile:

I hope this helps!


1 Like

Thank you both for the great explanation! That protocol page has all the answers I’m looking for.

Have a great weekend.


No problem! :slight_smile:

Glad to hear! Feel free to report anything that is unclear (or, you know, flat out wrong :stuck_out_tongue: ) and the Lynxmotion team will be happy to improve/fix it quickly once they know about it!

Same to you! :slight_smile: