![]() |
MercurySDK
Software development kit for Mercury digital servos
|
#include <stdlib.h>#include <stdio.h>#include <iostream>#include <string>#include "../../include/mercury_sdk/mercury_sdk.h"Go to the source code of this file.
Macros | |
| #define | ADDR_MCY_TORQUE_ENABLE 0x30 |
| #define | ADDR_MCY_GOAL_POSITION 0x4e |
| #define | ADDR_MCY_PRESENT_POSITION 0x5a |
| #define | LEN_MCY_GOAL_POSITION 4 |
| #define | LEN_MCY_PRESENT_POSITION 4 |
| #define | BAUDRATE 1000000 |
| #define | DEVICENAME "/dev/ttyACM1" |
| #define | TORQUE_ENABLE 1 |
| #define | TORQUE_DISABLE 0 |
| #define | MCY_MINIMUM_POSITION_VALUE -2000 |
| #define | MCY_MAXIMUM_POSITION_VALUE 2000 |
| #define | MCY_MOVING_STATUS_THRESHOLD 20 |
| #define | ESC_ASCII_VALUE 0x1b |
Functions | |
| int | getch () |
| int | kbhit (void) |
| int | main () |
| #define ADDR_MCY_GOAL_POSITION 0x4e |
Definition at line 47 of file sync_read_write.cpp.
| #define ADDR_MCY_PRESENT_POSITION 0x5a |
Definition at line 48 of file sync_read_write.cpp.
| #define ADDR_MCY_TORQUE_ENABLE 0x30 |
Definition at line 46 of file sync_read_write.cpp.
| #define BAUDRATE 1000000 |
Definition at line 55 of file sync_read_write.cpp.
| #define DEVICENAME "/dev/ttyACM1" |
Definition at line 56 of file sync_read_write.cpp.
| #define ESC_ASCII_VALUE 0x1b |
Definition at line 65 of file sync_read_write.cpp.
| #define LEN_MCY_GOAL_POSITION 4 |
Definition at line 51 of file sync_read_write.cpp.
| #define LEN_MCY_PRESENT_POSITION 4 |
Definition at line 52 of file sync_read_write.cpp.
| #define MCY_MAXIMUM_POSITION_VALUE 2000 |
Definition at line 62 of file sync_read_write.cpp.
| #define MCY_MINIMUM_POSITION_VALUE -2000 |
Definition at line 61 of file sync_read_write.cpp.
| #define MCY_MOVING_STATUS_THRESHOLD 20 |
Definition at line 63 of file sync_read_write.cpp.
| #define TORQUE_DISABLE 0 |
Definition at line 60 of file sync_read_write.cpp.
| #define TORQUE_ENABLE 1 |
Definition at line 59 of file sync_read_write.cpp.
| int getch | ( | ) |
Definition at line 67 of file sync_read_write.cpp.
| int kbhit | ( | void | ) |
Definition at line 84 of file sync_read_write.cpp.
| int main | ( | ) |
Definition at line 115 of file sync_read_write.cpp.