Close
0%
0%

fNIR Brain Imager

Measure brain activity with light

Similar projects worth following
An inexpensive & lightweight brain imaging device using near infrared spectroscopy of brain tissue; for use in video gaming, virtual reality and navigation.

To put it shortly, blood absorbs different frequencies of near infrared light depending on how much oxygen is being carried by its hemoglobin. Human bones are nearly transparent at these frequencies, so a head mounted device can measure the reflectivity of the outer layers of the brain right through the skull. The system can determine neural activity levels indirectly based off oxygen concentration, sort of like an fMRI.


The system is designed to shine one of two different infrared LEDs into the skull and measure the intensity of the reflected light. The two frequencies (730nm & 850nm) will be absorbed by hemoglobin with and without oxygen respectively. The reflected light will be captured by photodiodes, amplified, filtered and digitized with the ADC chip. The Atmega microcontroller will report results back to a host computer via USB. With 4 pairs of LEDs and 10 photodiodes clustered around them the system effectively has 16 measurement channels with 16 bits of resolution.

My project is released under GPLv3 and the LUFA library is provided under the LUFA license; both are available with my sourcecode in the github repository.

  • 10 × Photodiode Receives reflected light from brain
  • 4 × 730nm LED Illuminates non oxygen carrying hemoglobin
  • 4 × 850nm LED Illuminates oxygen carrying hemoglobin
  • 1 × Atmega8U2 Microprocessors, Microcontrollers, DSPs / ARM, RISC-Based Microcontrollers
  • 1 × LTC2494 Data Converters / Analog to Digital Converter ICs (ADCs)

  • Brief update on project status

    Jeremy Ruhland09/29/2014 at 03:12 0 comments

    Unfortunately, I've been rather busy with housework and job hunting this month and I haven't finished nearly enough of the FNIR system. I still intend to complete the project and will be posting to the project log as I do so, but I regret to say that I will not be qualifying for quarterfinals in the hackaday prize.

    Good luck to all the qualifying contenstents!

  • Intro Video Posted

    Jeremy Ruhland08/21/2014 at 06:24 0 comments

    Here's an introductory video I just posted to youtube, explaining my initial goals for the project:

  • A Question Of Microcontrollers

    Jeremy Ruhland08/21/2014 at 04:22 0 comments

    I've tended to shy away from simply throwing arduinos at my projects, especially if I don't intend to disassemble them once they're complete. Arduino's a great prototyping platform but I find custom designing a PCB gives me much more flexibility in layout, size and most importantly microcontroller selection.

    My experience with ARM microcontrollers from STM and Freescale have strongly dragged me in their direction, however AVR remains the most hobbyist friendly solution. The scope of my project doesn't require too much out of my microcontroller, so I settled on the Atmega16u2 which is very similar to the 8u2 which modern arduinos use to provide a USB-serial bridge. The extra 8k of program memory eliminates the need for an additional microcontroller like the atmega328, significantly reducing the cost of the board at volume.

  • Parts have arrived!

    Jeremy Ruhland08/20/2014 at 23:28 0 comments

    Thank you digikey!

  • PCBs have arrived!

    Jeremy Ruhland08/19/2014 at 02:12 0 comments

    After designing my circuit in Eagle CAD I ordered a small batch of PCBs from ITEAD studio. Shipping took quite a while, I send out the order for these at the end of july and they just arrived the other day. Luckily they were very cheap at around $15 for a batch of 10.

    The 2-layer PCB is about the size of a business card. Unfortunately the text size I chose for the silk screen was one size too small for ITEAD to print, most of it is a series of small dots and too blurred to read. This won't cause any problem during assembly but it just doesn't have the same sexy look without a good silkscreen.

    I ordered the parts from a mixture of ebay and digikey and they should arrive over the next couple days.

  • LUFA for the atmega16u2

    Jeremy Ruhland08/19/2014 at 02:01 0 comments

    To simplifly communication, the fNIR scanner uses a USB connection similar to an arduino. The circuit will enumerate as a USB serial device and spit out measurements in CSV format. This seems like a more simple way to go than something like a HID and is more suited to collecting raw data. Raw data will probably be useful in experimental or research situations, rather than just returning a limited amount of HID information.

    The LUFA project is a set of drivers for AVR processors that handles many parts of the USB protocol. My code is based off the USB-serial examples contained in the LUFA documentation. Upon startup it attempts to connect to a host device (your computer) and once connected it creates a stream using a function provide by the LUFA code. This stream can then be used by the fprintf function just like in normal *nix c programming.

    Atmel's usb enabled microcontrollers come with a built in DFU bootloader, so no special programming devices are needed. The board is always programmable over the same USB connection, again similar to an arduino which allows for rapid firmware development.

    In the next few built logs I will go over my firmware and hardware design and the basic theory of operation of an fNIR device.

View all 6 project logs

Enjoy this project?

Share

Discussions

stimo93 wrote 01/17/2022 at 21:40 point

I have seen a similar product program on multiple project-sharing platforms. I mostly like the tischsets product.

  Are you sure? yes | no

scott Elliott wrote 01/21/2016 at 00:58 point

Jeremy, Great Project.  Have you had a chance to bring the system up?  What layout did you use of your LEDs/Diodes?

  Are you sure? yes | no

c.lamport wrote 05/04/2015 at 16:10 point

Definitely interested in this, I've been looking into building one for myself. Very interested to see the effect of Nootropics and my tDCS machine.

  Are you sure? yes | no

naroom wrote 10/13/2014 at 02:40 point
Infrared isn't just for measurement, it can also excite neurons. Neuroscientists use this to make a specific neuron start spiking.

Reference:
http://arxiv.org/ftp/arxiv/papers/1201/1201.4617.pdf

So, be careful with the amount of IR power you're shooting into your skull. Depending on how much power you're pumping in, you may do more than just measure activity -- you might start causing it too.

  Are you sure? yes | no

AAYOTEE wrote 09/01/2014 at 15:24 point
Like Kerem I also have experience working with NIRS (and fMRI for that matter), this time as a researcher at University College London. IMO the electronics are perhaps the most trivial part of this project - the critical areas will be light transmission and detection through the skull, holding the optodes static to prevent motion artefacts, and also the actual analysis (there's a fNIR package for SPM which is where I would start http://www.fil.ion.ucl.ac.uk/spm/). Bearing in mind that the signal changes due to functional hyperaemia in the cortex are quite small, you're going to have to have to figure out a way of actually measuring these changes above the noise threshold (hint: block design of tasks and rests).

  Are you sure? yes | no

dao888 wrote 09/01/2014 at 06:53 point
Kudos man! Great project!! In my spare time when i'm not hacking i work as an MD specializing in neuroimaging [eg CT, MR] and of course have access to that equipment. Let me know if i can help you in any way with your project- i can't wait to see how it works for you!!

  Are you sure? yes | no

RuwaTech wrote 08/31/2014 at 12:43 point
Awesome !! defa a catch for hackaday prize !!! congrats bro !

  Are you sure? yes | no

bijtaj wrote 08/21/2014 at 03:50 point
One more log, a 2 minute video, and a system design document left for the Hackaday Prize! Good job! Can't wait to see how you do!

  Are you sure? yes | no

Kerem wrote 08/19/2014 at 11:04 point
Cool project. We had built a single channel version of this for our Bachelor's degree thesis, it was also a battery operated, wireless system which allowed the subject to move during the measurements/experiments. The major problems with these systems are that the motion artefacts have a big influence and the absorption by the hair on the skin surface is high. The head probe moves around when the subject moves his/her head, this has to be taken care of in detail. The problem is the crooked surface of the human head, even when the probe is mounted on the head firmly, small movements are unavoidable and these small motions translate to high signal changes. The latter problem is the bigger disadvantage of NIR systems. The hair roots on the skin absorb a high portion of the light at these wavelengths, thus the energy cannot penetrate deep enough. Combined withthe motion artefacts, the SNR is reduced significantly. We had to use our system only on the forehead, left and right frontal lobes, which is a good place as one can reach the cognitive brain function, such as the dorsolateral cortex region etc... I have not seen any studies where they could use it on the areas with hair such as the motor cortex etc. I had seen a study on auditory cortexes of babies, but they have less hair...
Another optimization problem would be the placement of the source/detector pairs. The distance between the source and detector pair has to be optimized as well as the distances between the pairs for the multi channel system. But multiplexing in time should reduce cross-talk artefacts. There were also literature on this optimization.
What kind of photodiodes do you use? You have probably seen them but OPT101s are pretty cool for these applications. Also, if you can find them, there are multiple wavelength LEDs you can use to save space and complexity of circuitry. But they are quite expensive.
I hope you a good time with the project, it was really fun for us and it is very cool when you can see your own brain activation in the end by the device of your own design.

  Are you sure? yes | no

bijtaj wrote 08/12/2014 at 04:56 point
Why don't you use Arduino? I bet there will be some great libraries to help you!

  Are you sure? yes | no

Jeremy Ruhland wrote 08/19/2014 at 01:44 point
I'm using an atmega16u2, so its very similar to the chip modern arduinos use for usb/serial conversion. Since this chip alone can take care of everything I need I decided to lower costs by removing a prototyping board like the arduino from the project entirely.

  Are you sure? yes | no

bijtaj wrote 08/12/2014 at 02:59 point
So, technically, the hardware of your project is based on that of simple pulse oximeters and photoplethysmographs... correct?

  Are you sure? yes | no

Jeremy Ruhland wrote 08/12/2014 at 03:05 point
Yep, its basically identical to a pulse oximeter, only multi-channel.

  Are you sure? yes | no

J Groff wrote 08/01/2014 at 18:32 point
AKA pulse oximeter

  Are you sure? yes | no

jlbrian7 wrote 07/31/2014 at 22:55 point
ok, I think it can be done and it is great that you are trying. Here is what I read on it...
http://www.ncbi.nlm.nih.gov/pmc/articles/PMC196871/?iframe=true&width=100%25&height=100%25

The paper is old, and I am sure that advancements have been made, but my initial reaction was that the main pic was a little misleading.

  Are you sure? yes | no

Jeremy Ruhland wrote 07/31/2014 at 23:10 point
Yeah, the system won't generate data like the grayscale background image, just the data represented by the colored patches. With most functional brain imaging techniques a separate initial scanning method (such as CAT) is used to generate a map and data from the functional tests are used to fill it in, a bit like a coloring book.

  Are you sure? yes | no

jlbrian7 wrote 07/31/2014 at 22:42 point
have you tested this?

  Are you sure? yes | no

Jeremy Ruhland wrote 07/31/2014 at 22:45 point
Nope, its all based off a few papers I read. Expensive professional versions are used in the medical industry and the same technology is used in photoplethysmographs that you can buy off the shelf.

  Are you sure? yes | no

Does this project spark your interest?

Become a member to follow this project and never miss any updates