Projekt

Splošno

Profil

Protocol » Zgodovina » Verzija 2

Aleksandar Todorovic, 03.03.2013 19:10

1 1 Aleksandar Todorovic
h1. Protocol
2 1 Aleksandar Todorovic
3 2 Aleksandar Todorovic
MOVE <motor [LEFT|RIGHT|BOTH] default:BOTH> <direction [FORWARD|BACKWARD]> <unsigned int amount> <unit [MM|CM|M|STEPS] defaults:STEPS>  
4 1 Aleksandar Todorovic
5 2 Aleksandar Todorovic
description:
6 1 Aleksandar Todorovic
7 2 Aleksandar Todorovic
Moves the selected motor in the desired direction by a desired amount.
8 1 Aleksandar Todorovic
9 2 Aleksandar Todorovic
example:
10 1 Aleksandar Todorovic
11 2 Aleksandar Todorovic
MOVE LEFT FORWARD 100
12 2 Aleksandar Todorovic
Moves the left motor for 100 steps.
13 2 Aleksandar Todorovic
MOVE RIGHT FORWARD 15 CM
14 2 Aleksandar Todorovic
Moves the right motor for 15 cm.
15 2 Aleksandar Todorovic
MOVE BACKWARD 1 M
16 2 Aleksandar Todorovic
Moves both motors 1 m backward.
17 1 Aleksandar Todorovic
18 1 Aleksandar Todorovic
	--------------------------------------------------------------------------------------------------------------------------------------
19 1 Aleksandar Todorovic
20 1 Aleksandar Todorovic
	SET ACCELERATION_MODE <motor [LEFT|RIGHT|BOTH] default:BOTH> <acceleration mode [CONSTANT|LINEAR] default:LINEAR>
21 1 Aleksandar Todorovic
22 1 Aleksandar Todorovic
		description:
23 1 Aleksandar Todorovic
24 1 Aleksandar Todorovic
			Sets the acceleration method of the selected motor.
25 1 Aleksandar Todorovic
26 1 Aleksandar Todorovic
		example:
27 1 Aleksandar Todorovic
			
28 1 Aleksandar Todorovic
			SET ACCELERATION_MODE LINEAR
29 1 Aleksandar Todorovic
30 1 Aleksandar Todorovic
	--------------------------------------------------------------------------------------------------------------------------------------
31 1 Aleksandar Todorovic
32 1 Aleksandar Todorovic
	SET MOTOR_MODE <motor [LEFT|RIGHT|BOTH] default:BOTH> <motor mode [INTERLEAVE|MICROSTEP|SINGLE|DOUBLE] default:double>
33 1 Aleksandar Todorovic
34 1 Aleksandar Todorovic
		description:
35 1 Aleksandar Todorovic
36 1 Aleksandar Todorovic
			Sets the motor mode of the selected motor.
37 1 Aleksandar Todorovic
38 1 Aleksandar Todorovic
		SET MOTOR_MODE INTERLEAVE
39 1 Aleksandar Todorovic
40 1 Aleksandar Todorovic
	--------------------------------------------------------------------------------------------------------------------------------------
41 1 Aleksandar Todorovic
42 1 Aleksandar Todorovic
	SET MAX_SPEED <motor [LEFT|RIGHT|BOTH] default:BOTH> <unsigned int (capped with motor constraints)>
43 1 Aleksandar Todorovic
44 1 Aleksandar Todorovic
		description:
45 1 Aleksandar Todorovic
46 1 Aleksandar Todorovic
			Sets the max motor speed of the selected motor.
47 1 Aleksandar Todorovic
48 1 Aleksandar Todorovic
		example:
49 1 Aleksandar Todorovic
50 1 Aleksandar Todorovic
			SET MAX_SPEED BOTH 40
51 1 Aleksandar Todorovic
52 1 Aleksandar Todorovic
	--------------------------------------------------------------------------------------------------------------------------------------
53 1 Aleksandar Todorovic
54 1 Aleksandar Todorovic
	SET ACC_SPEED <motor [LEFT|RIGHT|BOTH] default:BOTH> <unsigned int>
55 1 Aleksandar Todorovic
56 1 Aleksandar Todorovic
		description:
57 1 Aleksandar Todorovic
58 1 Aleksandar Todorovic
			Sets the acceleration speed of the selected motor.
59 1 Aleksandar Todorovic
60 1 Aleksandar Todorovic
		example:
61 1 Aleksandar Todorovic
62 1 Aleksandar Todorovic
			SET ACC_SPEED RIGHT 10
63 1 Aleksandar Todorovic
64 1 Aleksandar Todorovic
	--------------------------------------------------------------------------------------------------------------------------------------
65 1 Aleksandar Todorovic
	######################################################################################################################################
66 1 Aleksandar Todorovic
	######################################################################################################################################
67 1 Aleksandar Todorovic
	--------------------------------------------------------------------------------------------------------------------------------------
68 1 Aleksandar Todorovic
69 1 Aleksandar Todorovic
	GET ACCELERATION_MODE <motor [LEFT|RIGHT|BOTH] default:BOTH>
70 1 Aleksandar Todorovic
71 1 Aleksandar Todorovic
		description:
72 1 Aleksandar Todorovic
73 1 Aleksandar Todorovic
			Returns the current acceleration mode.
74 1 Aleksandar Todorovic
75 1 Aleksandar Todorovic
		example:
76 1 Aleksandar Todorovic
77 1 Aleksandar Todorovic
			GET ACCELERATION_MODE BOTH
78 1 Aleksandar Todorovic
79 1 Aleksandar Todorovic
	--------------------------------------------------------------------------------------------------------------------------------------
80 1 Aleksandar Todorovic
81 1 Aleksandar Todorovic
	GET MOTOR_MODE <motor [LEFT|RIGHT|BOTH] default:BOTH>
82 1 Aleksandar Todorovic
83 1 Aleksandar Todorovic
		description:
84 1 Aleksandar Todorovic
85 1 Aleksandar Todorovic
			Returns the current motor mode.
86 1 Aleksandar Todorovic
87 1 Aleksandar Todorovic
		example:
88 1 Aleksandar Todorovic
89 1 Aleksandar Todorovic
			GET MOTOR_MODE
90 1 Aleksandar Todorovic
91 1 Aleksandar Todorovic
	--------------------------------------------------------------------------------------------------------------------------------------
92 1 Aleksandar Todorovic
93 1 Aleksandar Todorovic
	GET MAX_SPEED <motor [LEFT|RIGHT|BOTH] default:BOTH>
94 1 Aleksandar Todorovic
95 1 Aleksandar Todorovic
		description:
96 1 Aleksandar Todorovic
97 1 Aleksandar Todorovic
			Returns the current max motor speed.
98 1 Aleksandar Todorovic
99 1 Aleksandar Todorovic
		example:
100 1 Aleksandar Todorovic
101 1 Aleksandar Todorovic
			GET MAX_SPEED BOTH
102 1 Aleksandar Todorovic
103 1 Aleksandar Todorovic
	--------------------------------------------------------------------------------------------------------------------------------------
104 1 Aleksandar Todorovic
105 1 Aleksandar Todorovic
	GET ACC_SPEED <motor [LEFT|RIGHT|BOTH] default:BOTH>
106 1 Aleksandar Todorovic
107 1 Aleksandar Todorovic
		description:
108 1 Aleksandar Todorovic
109 1 Aleksandar Todorovic
			Returns the current acceleration speed.
110 1 Aleksandar Todorovic
111 1 Aleksandar Todorovic
		example:
112 1 Aleksandar Todorovic
113 1 Aleksandar Todorovic
			GET ACC_SPEED
114 1 Aleksandar Todorovic
115 1 Aleksandar Todorovic
	--------------------------------------------------------------------------------------------------------------------------------------
116 1 Aleksandar Todorovic
117 1 Aleksandar Todorovic
	GET CONTROLLER_MAX_SPEED <motor [LEFT|RIGHT|BOTH] default:BOTH>
118 1 Aleksandar Todorovic
119 1 Aleksandar Todorovic
		description:
120 1 Aleksandar Todorovic
121 1 Aleksandar Todorovic
			Returns the max controller speed
122 1 Aleksandar Todorovic
123 1 Aleksandar Todorovic
		example:
124 1 Aleksandar Todorovic
125 1 Aleksandar Todorovic
			GET CONTROLLER_MAX_SPEED RIGHT
126 1 Aleksandar Todorovic
127 1 Aleksandar Todorovic
	--------------------------------------------------------------------------------------------------------------------------------------
128 1 Aleksandar Todorovic
	######################################################################################################################################
129 1 Aleksandar Todorovic
	######################################################################################################################################
130 1 Aleksandar Todorovic
	--------------------------------------------------------------------------------------------------------------------------------------
131 1 Aleksandar Todorovic
132 1 Aleksandar Todorovic
	RELEASE <motor [LEFT|RIGHT|BOTH] default:BOTH>
133 1 Aleksandar Todorovic
134 1 Aleksandar Todorovic
		description:
135 1 Aleksandar Todorovic
136 1 Aleksandar Todorovic
			Releases the motor coils.
137 1 Aleksandar Todorovic
138 1 Aleksandar Todorovic
		example:
139 1 Aleksandar Todorovic
140 1 Aleksandar Todorovic
			RELEASE RIGHT
141 1 Aleksandar Todorovic
142 1 Aleksandar Todorovic
	--------------------------------------------------------------------------------------------------------------------------------------
143 1 Aleksandar Todorovic
144 1 Aleksandar Todorovic
	CLEAR <motor [LEFT|RIGHT|BOTH] default:BOTH>
145 1 Aleksandar Todorovic
146 1 Aleksandar Todorovic
		description:
147 1 Aleksandar Todorovic
148 1 Aleksandar Todorovic
			Clears selected motors order queue. The currently executing order is not affected.
149 1 Aleksandar Todorovic
150 1 Aleksandar Todorovic
		example:
151 1 Aleksandar Todorovic
152 1 Aleksandar Todorovic
			CLEAR
153 1 Aleksandar Todorovic
154 1 Aleksandar Todorovic
	--------------------------------------------------------------------------------------------------------------------------------------	
155 1 Aleksandar Todorovic
156 1 Aleksandar Todorovic
	STOP <motor [LEFT|RIGHT|BOTH] default:BOTH>
157 1 Aleksandar Todorovic
158 1 Aleksandar Todorovic
		description:
159 1 Aleksandar Todorovic
160 1 Aleksandar Todorovic
			Immediately stops the selected motors and clears their order queue.
161 1 Aleksandar Todorovic
162 1 Aleksandar Todorovic
		example:
163 1 Aleksandar Todorovic
164 1 Aleksandar Todorovic
			STOP LEFT
165 1 Aleksandar Todorovic
166 1 Aleksandar Todorovic
	--------------------------------------------------------------------------------------------------------------------------------------