Sam's Wiki

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
notes:taking-a-picture [2026/11/30 06:30] – [Taking a Picture] samnotes:taking-a-picture [2026/11/30 07:35] (current) – [Improvements for Version 2] sam
Line 13: Line 13:
 In fact, you don't need a special camera to create a strip photograph. I produced the following image by taking a video with my cell-phone camera and using a Python script to overlap the video frames such that each frame has been shifted by the speed of the train divided by the frame rate. In fact, you don't need a special camera to create a strip photograph. I produced the following image by taking a video with my cell-phone camera and using a Python script to overlap the video frames such that each frame has been shifted by the speed of the train divided by the frame rate.
  
-{{taking-a-picture:metra.jpg}}+{{notes:taking-a-picture:metra.jpg}}
  
 There's also a similar technique used in some panoramic cameras where the camera or optic rotates, so that each subsequent "slice" captures a different angle of the scene. I decided to try and capture a picture using this second technique, with the idea that it would be easy to produce a strip photograph by not rotating the optic during the course of the capture. There's also a similar technique used in some panoramic cameras where the camera or optic rotates, so that each subsequent "slice" captures a different angle of the scene. I decided to try and capture a picture using this second technique, with the idea that it would be easy to produce a strip photograph by not rotating the optic during the course of the capture.
Line 19: Line 19:
 To keep things as simple as possible, I decided to use a pinhole to project the image onto the image sensor. A motor will be used to rotate the image sensor and the pinhole through the scene while the image sensor continuously captures pictures. Once the capture is complete, the individual columns can be concatenated to form the final image. To keep things as simple as possible, I decided to use a pinhole to project the image onto the image sensor. A motor will be used to rotate the image sensor and the pinhole through the scene while the image sensor continuously captures pictures. Once the capture is complete, the individual columns can be concatenated to form the final image.
  
-{{taking-a-picture:theory-of-operation.png}}+{{notes:taking-a-picture:theory-of-operation.png}}
  
 <WRAP lo> <WRAP lo>
Line 33: Line 33:
 The EPC901 can be configured both by pull-up/down resistors and by I2C. I followed the data sheet's recommended settings, but enabled the sensor's differential output since the analog signal must be routed through an unshielded FFC cable to the main sensor board. The microcontroller's ADC can also be configured as a differential input, so there's no additional circuitry required to connect the image sensor and microcontroller. The EPC901 can be configured both by pull-up/down resistors and by I2C. I followed the data sheet's recommended settings, but enabled the sensor's differential output since the analog signal must be routed through an unshielded FFC cable to the main sensor board. The microcontroller's ADC can also be configured as a differential input, so there's no additional circuitry required to connect the image sensor and microcontroller.
  
-{{taking-a-picture:block-diagram.png}}+{{notes:taking-a-picture:block-diagram.png}}
  
 <WRAP lo> <WRAP lo>
Line 45: Line 45:
 The time to read an image is limited by the microcontroller's ADC, which can sample at a maximum of around 500k samples per second. This turned out to be a significant issue – the slower images are captured, the slower the motor has to move in order to capture a wide swath of the scene. The time to read an image is limited by the microcontroller's ADC, which can sample at a maximum of around 500k samples per second. This turned out to be a significant issue – the slower images are captured, the slower the motor has to move in order to capture a wide swath of the scene.
  
-{{taking-a-picture:sensor-board.jpg}}+{{notes:taking-a-picture:sensor-board.jpg}}
  
 <WRAP lo> <WRAP lo>
Line 63: Line 63:
 The 5-way button pad is used to adjust the camera's exposure duration and to trigger a capture. The 5-way button pad is used to adjust the camera's exposure duration and to trigger a capture.
  
-{{taking-a-picture:main-board.jpg}}+{{notes:taking-a-picture:main-board.jpg}}
  
 <WRAP lo> <WRAP lo>
Line 124: Line 124:
 The below is the most successful image I acquired with the line camera: The below is the most successful image I acquired with the line camera:
  
-{{taking-a-picture:capture-edited.png?500}}+{{notes:taking-a-picture:capture-edited.png?500}}
  
 <WRAP lo> <WRAP lo>
Line 136: Line 136:
 ==== A Motor Issue ==== ==== A Motor Issue ====
  
-{{taking-a-picture:motor-controller.jpg?300}}+{{notes:taking-a-picture:motor-controller.jpg?300}}
  
 <WRAP lo> <WRAP lo>
Line 155: Line 155:
  
   * The motor issue could be solved by sampling faster. The SAMD21 is a little under-powered for the task of sampling from the EPC901. A better design might include a stand-alone ADC with faster sample rate, and a microcontroller which can handle the increased data rate. Of course, there is a limit to how much faster we can sample, because we still need to allow time to expose the image sensor on each frame.   * The motor issue could be solved by sampling faster. The SAMD21 is a little under-powered for the task of sampling from the EPC901. A better design might include a stand-alone ADC with faster sample rate, and a microcontroller which can handle the increased data rate. Of course, there is a limit to how much faster we can sample, because we still need to allow time to expose the image sensor on each frame.
-  * The motor issue could also be solved by choosing a more appropriate motor, or by doing away the motor altogether. One attractive solution is to use a purely mechanical system – probably involving a spring and a damper – to rotate the sensor, and potentially an encoder to compensate for any nonlinearities in the motion. The motor and its controller are the most power hungry components of the system, and big contributors to noise, and so removing them would certainly benefit other electronics which aren't directly related to sensor motion control.+  * The motor issue could also be solved by choosing a more appropriate motor, or by doing away the motor altogether. One solution is to use a purely mechanical system, probably involving a spring and a damper, to rotate the sensor, and potentially an encoder to compensate for any nonlinearities in the motion. The motor and its controller are the most power hungry components of the system, and big contributors to noise, so removing them would simplify things.
  
-Secondly, the user interface could be somewhat improved. Mainly, I'm referring to the old Nokia 6100 display which I recycled to use on this project. There are very cheap displays to be found with better color rendering, and without the need to generate 7 volts for the backlight.+Secondly, the user interface could be improved. I'm mainly referring to the old Nokia 6100 display which I recycled to use on this project. There are very cheap displays to be found with better color rendering, and without the need to generate 7 volts for the backlight.
  
notes/taking-a-picture.1796020226.txt.gz · Last modified: by sam