commands.h 881 B

123456789101112131415161718192021222324
  1. /**********************************************************************
  2. Copyright: 2016-2019 ROS小课堂 www.corvin.cn
  3. Author: corvin
  4. Description:
  5. Define single-letter commands that will be sent by the PC over the
  6. serial link.
  7. History:
  8. 20181128: initial this comment.
  9. 20181130: 新增了d,e命令,分别可以禁用、使能指定舵机,v获取代码版本号。
  10. 20181203: 删除了d命令,使用e命令的第2个参数来表示使能或禁用指定舵机。
  11. 20181204: 新增用户获取所有舵机使能状态命令s和所有舵机当前角度p。
  12. */
  13. #ifndef _COMMANDS_H_
  14. #define _COMMANDS_H_
  15. #define GET_CONNECT_BAUDRATE 'b'
  16. #define SET_ONE_SERVO_ENABLE 'e'
  17. #define SET_ONE_SERVO_POS 'w'
  18. #define GET_ONE_SERVO_POS 'r'
  19. #define GET_ALL_SERVOS_POS 'p'
  20. #define GET_ALL_SERVOS_ENABLE 's'
  21. #define GET_FIRMWARE_VERSION 'v'
  22. #endif