Mechanical System
The purpose of the mechanical system was to convert continuous rotational motion from a DC motor to continuous translational movement of a grating housing. A precision ball screw with supports and a ball rail were chosen to facilitate the uniaxial movement of a grating housing. A DC motor was attached to the lead screw with a coupler designed to correct for any misalignment between the motor shaft and ball screw and drove the rotation of the ball screw and the movement of the grating housing. Furthermore, a stainless steel flywheel was implemented to increase the rotational inertia of the system, mounting on the ball screw. It was made with stainless steel to add as much rotational inertia as possible. It was meant to counteract any disturbances in velocity when the setpoint velocity was reached.
Mechanical System
Flywheel
Motor and Coupler
Controls System
The purpose of the control system was to ensure and maintain the grating’s position as it was being imaged such that the deviation from the position setpoint and actual position was as low and consistent as possible. The controls system attempted to write to the quadrature encoder counter register whenever the counter passed a discrete step size, however was unsuccessful due to not being able to write to these registers fast enough. The components of the control system were as such:
Arduino Due
Incremental optical encoder
Light Source
PID controls were utilized to ensure accurate positioning of the grating as it traveled. A linear encoder was utilized to obtain precise position measurements as the grating traveled.
Control System Diagram
Electrical System
The electrical system contained the following components:
Arduino Due
L298N motor driver
932-MIKROE-1917 quadrature counter
LS7366R quadrature counter chip
TXS0108E Bi-Directional Logic Converter
Renishaw VIONiC linear encoder (and its breakout board for wiring)
Pololu 12V DC motor
Phantom v7.3 High speed camera
Light source
12V, 10A power supply
The Arduino was the main communicator between all of the components. The purpose of the L298N motor driver was to be able to send 12V pulse width modulation (PWM) signals, as opposed to the maximum of 3.3V signals from the Arduino, and the TXS0108E logic converter was used to send the correct signals, whether 3.3V or 5V, to the correct devices. The linear encoder was used to obtain position measurements of the grating as it traveled, and the 932-MIKROE-1917 allowed for all the counts from the encoder to be recorded as well as sending signals to the light to pulse when each step was reached.
System Circuit Diagram
Base Plate
The structure of the device consists of an aluminum baseplate. The top of the plate had holes to allow the mechanical system to be mounted with screws and nuts. It was chosen to be fly cut on the top and bottom of the plate to ensure linearity for accurate linear encoder measurements.
Base Plate
Grating Housing
The purpose of the grating housing was to hold the gratings securely in place with negligible unwanted displacement throughout the duration of experiments. Furthermore, being able to easily swap out gratings was also a requirement which was achieved through the design of a secondary component which held a grating in place by two pieces screwed together that could slide into the housing. This design allowed the user to easily swap out gratings as needed with little effort. The grating was also required to be in the frame of the camera for the entire duration of the recordings, which are to be at least 5 seconds long. For the higher end step size of 20 mm/s, a total grating distance of at least 200 mm was required to account for any settling time within the controls. Therefore, the grating holder and housing was designed to have a 225 mm grating viewing window for extra leeway.
Grating Housing
Secondary Grating Housing Component
MATLAB GUI
A GUI was developed in MATLAB to make it easy and simple for the user to specify various variables in the Arduino and start and stop the system.
The GUI contained:
Sliders and text entry
Kp, Ki, and Kd PID control values
Frame rate
Step size values
Buttons
Start and stop grating movement
Save the current PID control values
Clear accompanying MATLAB graphs, save the current PID control values, and
Toggles
Direction of the system
Whether trials are saved in MATLAB
Text
Displays current direction, step size, frame rate, control constants, save status
Variables were communicated to the Arduino through serial communication.
MATLAB GUI
Performance and Final Results
Overall, the system was able to control the position deviation from setpoint to < ± step size/2 boundaries, achieving an impressive < ±2.5 µm at a step size of 5 µm. The system provided imaging time over 5 seconds for step sizes up to 15 µm, with step sizes closer and at 20 µm slightly below the desired 5 seconds of imaging time. The system was unable to send a signal every step size increment to trigger camera imaging or illuminate a light source. See the figure below for a graphical representation of the position deviation from setpoint.
Position deviation from position setpoint with 5-20 µm step sizes at 1000 Hz with ± (step size)/2 boundaries. Settling time for each step size shown in dashed vertical lines with their according color. PID constants used: KP=50,000, KI=20,000, KD=1,100.
Each trial in the figure met the required deviation boundaries. All trials besides the 20 µm trial met the required imaging and settling time of 5 seconds, where the 20 µm trial only allowed for 4.316 s of imaging. A summary of the these results is given in the table below
Aggregated trial data with step sizes from 5-20 μm and 1000 Hz frame rate.
For > 98.95% of the time, the position deviation from the setpoint is within the required boundaries. For step sizes < 15 μm, the imaging time is > 5 seconds, with the trial at 20 μm step size only slightly under 5 seconds. This can still be used for imaging. Overall, the mechanism provides the functionality necessary to use subpixel resolution enhancement techniques with high-speed imaging, only requiring a revision to the electrical system to fully function as necessary.