Dragonframe stop motion software
Buy Dragonframe stop motion softwareFree Dragonframe Trial


Arduino Example #2 - Triggering a Stereo Slider

Example #2: Moves a stereo slider when Dragonframe switches between left-eye and right-eye positions. This would work with the Mark Roberts S3 Stereoscopic Stepper, for example.

 * Dragonframe stereo slider example for Arduino.

// output pin wired to stereo slider

// track the stereo position
char stereoPosition = 'L';

// Create global object to communicate with Dragonframe
DFRemote df_remote = DFRemote();

 * Arduino calls this function once, at the start of your program.
void setup()
  // set up serial port to 57600 kbps
   * Configure output pin for triggering stereo slider.
  digitalWrite(STEREO_TRIGGER_PIN, LOW);

 * Arduino calls this function repeatedly as the main program loop.
void loop()
  // tell df to check for inputs and send messages to Dragonframe if needed
  // read serial messages from Dragonframe
  int cmd = df_remote.processSerial();

/** * Send pulse to stereo slider based on exposure name. * This example sets a digital I/O pin high for 0.5 seconds. */ if (cmd == DF_POSITION_MSG) { if (df_remote.commandExposureName[0] != stereoPosition) { digitalWrite(STEREO_TRIGGER_PIN, HIGH); delay(500); digitalWrite(STEREO_TRIGGER_PIN, LOW); stereoPosition = df_remote.commandExposureName[0]; } }
Our Products
our company
help and support
Stay Connected
DZED Systems LLC Logo