Panoramic Motion Control

This page describes the ongoing saga of retrofitting a commercial Panormama Head(in this case a Nodal Ninja 5) with stepper motor controlled positioning for automated large panorama captures.

The first field tested code is available here: stepcontrol3.asm

Photos of the actual use of this code are at:My Gallery

Really boring video of the system:Panomc on Youtube

This code has no warranty and will probably explode if you look at it funny, in addition it's probably a horrible implementation.

It expects 9600 8-N-1 serial input and outputs step and direction outputs for 2 motors. It can also send a power down signal and 2 general output pins.

All commands are terminated with ',' 0x0d or 0x0a, the following is the list of commands. 'm' in the below is the actual motor x or y in lower case, all commands are all lower case, numbers are in decimal.

This code is under the Modified BSD license.

Below this line is the original C code, here for reference only.


At present all I have is a first draft of some code for a stepper motor controller controller, which takes serial input and outputs Step, Direction and Power pins for a stepper board like the PICList Linear Stepper Controller

Source Code

The code compiles under SDCC for the PIC 16F628, and probably the 16F628A, I just don't have one. For the 628 I use an external oscillator since the internal RC clock isn't accurate enough for serial. The 628A may solve this. Serial input/output is on the standard 628 USART pins at 9600-8-n-1. Commands are of the form: motor letter direction number of steps terminator. Motors are x and y, y is not yet implemented, direction is + -, and number of steps is decimal up to 65535, the terminator is comma(,) linefeed(10) or carriage return(13). So, sending x+10, will step motor x 10 steps in the positive direction. Direction can also be a b c or d to change various parameters in the code, these are not saved across reset, this is mostly for testing and then once you find good values then hard code them and recompile. On motor start the code sends 'xgo' or 'ygo' and on end of motion sends 'xok' or 'yok'.

Stepper Controller Controller stepcontrol_001.c