Monday, May 30, 2016

Bare Metal C with the Raspberry Pi 3 and Sony 8mp NoIR camera

780nm IR Laser Diode pulsed at ~20.2Hz
Sony NoIR 8mp Camera Module for Raspberry Pi 3
Pulsing a laser diode at a frequency over 38 to 40 megahertz from bare metal necessitates an FPGA, microcontroller board with an RTOS running on it, or a dedicated circuit.  Some of the laser diodes that were tested required a simple voltage divider circuit. Others stayed well under 5v and 20ma.

Several different methods of pulsing the GPIO pins were tested; memory mapped IO where the physical ARM peripheral base addresses were mapped into Linux user space via virtual addressing, C and python user space programs that link against user space dynamically linked libraries which in turn read and write the ARM peripheral address space to toggle the GPIO pins, a device driver that disables interrupts and writes to the underlying ARM peripheral address space after being called from a syscall in user space, and bare metal C code that directly writes to the ARM peripheral address space.
780nm IR Laser Diode pulsed at ~20.2Hz
 Sony NoIR 8mp Camera Module

These images were shot using the Sony NoIR 8mp Camera module for the Raspberry Pi 3.

850nm IR Laser Continuous Wave
Sony NoIR 8mp Camera Module





No comments:

Post a Comment