|
7 | 7 | // |
8 | 8 | // Serial support |
9 | 9 | // |
10 | | -// The Serial protocol implemented her is the Meade protocol with some extensions. |
| 10 | +// The Serial protocol implemented here is the Meade LX200 Classic protocol with some extensions. |
11 | 11 | // The Meade protocol commands start with a colon and end with a hash. |
12 | 12 | // The first letter determines the family of functions (G for Get, S for Set, M for Movement, etc.) |
13 | 13 | // |
|
181 | 181 | // :Rs# |
182 | 182 | // Set Slew rate |
183 | 183 | // Where s is one of 'S', 'M', 'C', or 'G' in order of decreasing speed |
184 | | -// CURRENTLY IGNORED |
185 | 184 | // Returns: nothing |
186 | 185 | //------------------------------------------------------------------ |
187 | 186 | // MOVEMENT FAMILY |
|
308 | 307 | // |
309 | 308 | // :XSRn# |
310 | 309 | // Set RA steps |
311 | | -// Set the number of steps the RA stepper motor needs to take to rotate by one degree |
| 310 | +// Set the number of steps the RA stepper motor needs to take to rotate by one degree. |
312 | 311 | // Where n is the number of steps |
313 | 312 | // Returns: nothing |
314 | 313 | // |
315 | 314 | // :XSDn# |
316 | 315 | // Set DEC steps |
317 | | -// Set the number of steps the DEC stepper motor needs to take to rotate by one degree |
| 316 | +// Set the number of steps the DEC stepper motor needs to take to rotate by one degree. |
318 | 317 | // Where n is the number of steps |
319 | 318 | // Returns: nothing |
320 | 319 | // |
321 | | -// :XSSn.n# |
| 320 | +// :XSSn.nnn# |
322 | 321 | // Set Tracking speed adjustment |
323 | 322 | // Set the adjustment factor used to speed up (>1.0) or slow down (<1.0) the tracking speed of the mount. |
| 323 | +// Where n.nnn is the factor to multiply the theoretical speed by. |
324 | 324 | // Returns: nothing |
325 | 325 | // |
326 | 326 | // :XSMn# |
|
331 | 331 | // |
332 | 332 | // :XSXn.nnn# |
333 | 333 | // Set RA manual slewing speed |
334 | | -// Set the speed of the RA motor, immediately. Must be in manual slewing mode |
| 334 | +// Set the speed of the RA motor, immediately. Must be in manual slewing mode. |
335 | 335 | // Returns: nothing |
336 | 336 | // |
337 | 337 | // :XSYn.nnn# |
338 | 338 | // Set DEC manual slewing speed |
339 | | -// Set the speed of the DEC motor, immediately. |
| 339 | +// Set the speed of the DEC motor, immediately. Must be in manual slewing mode. |
340 | 340 | // Returns: nothing |
341 | 341 | // |
342 | 342 | ///////////////////////////////////////////////////////////////////////////////////////// |
@@ -799,7 +799,16 @@ String MeadeCommandProcessor::handleMeadeSetSlewRate(String inCmd) { |
799 | 799 |
|
800 | 800 | String MeadeCommandProcessor::processCommand(String inCmd) { |
801 | 801 | if (inCmd[0] == ':') { |
| 802 | + |
802 | 803 | LOGV2(DEBUG_MEADE, "MEADE: Received command '%s'", inCmd.c_str()); |
| 804 | + |
| 805 | + // Apparently some LX200 implementations put spaces in their commands..... remove them with impunity. |
| 806 | + int spacePos; |
| 807 | + while ((spacePos = inCmd.indexOf(' ')) != -1) { |
| 808 | + inCmd.remove(spacePos, 1); |
| 809 | + } |
| 810 | + |
| 811 | + LOGV2(DEBUG_MEADE, "MEADE: Processing command '%s'", inCmd.c_str()); |
803 | 812 | char command = inCmd[1]; |
804 | 813 | inCmd = inCmd.substring(2); |
805 | 814 | switch (command) { |
|
0 commit comments