A Compact VIS–NIR Spectroscopy Development Board powered by ESP32-C3 and AS7263
SpectrumLab V1 is a compact VIS–NIR spectroscopy development board built around the ESP32-C3 and the AMS AS7263 spectral sensor.
Most spectrometers are big lab instruments. I wanted to see how small and practical a spectral sensing system could be if everything was integrated onto a single embedded board.
This project is my attempt to make near-infrared sensing more accessible, portable, and easier to experiment with (and honestly, just more fun to build!) (•‿•)
- Compact form factor
- USB powered
- No moving optics
- Wireless capable
- Built for experimentation
Traditional NIR spectrometers rely on diffraction gratings and mechanical scanning. They are precise, but they are also expensive and not exactly friendly for embedded projects.
I wanted something that:
- Fits in your hand
- Has no moving parts
- Can stream data over WiFi
- Is easy to integrate into custom hardware projects
SpectrumLab is meant to be both a learning platform and a base for portable sensing ideas such as fruit analysis, material comparison, and reflectance experiments.
SpectrumLab measures reflected light intensity at specific wavelengths in the visible to near-infrared range.
- ESP32-C3-WROOM-2 — Handles processing, USB communication, WiFi and BLE
- AMS AS7263 — 6-channel VIS–NIR spectral sensor
- 128×64 I2C OLED — Displays live spectral data
- 610 nm
- 680 nm
- 730 nm
- 760 nm
- 810 nm
- 860 nm
Each channel has about 20 nm bandwidth (FWHM). This does not give a continuous spectrum, but it provides discrete calibrated intensity points that are very useful for classification and trend analysis.
- The sample is illuminated.
- Reflected light enters the AS7263.
- The sensor outputs calibrated intensity values.
- The ESP32 processes, displays, or streams the data.
Simple, solid-state, and no mechanical scanning ( ̄▽ ̄)b
Instead of using a diffraction grating and scanning optics, this board uses a filter-based solid-state spectral sensor.
The AS7263 integrates:
- Optical filters
- On-chip ADC
- Digitally calibrated outputs
Because of that, the system:
- Has no moving parts
- Is physically small
- Consumes less power
- Is much easier to embed into custom hardware
It is not a lab-grade continuous spectrometer. It is a compact, embedded-friendly spectral measurement platform designed for experimentation and real-world integration.
Design goals:
- 2-layer compact PCB
- Fully surface-mount
- USB-C powered (5V to 3.3V regulation)
- Dedicated I2C breakout pins
- Debug jumper bridges
#include <Wire.h>
#include <Adafruit_SSD1306.h>
#include "AS726X.h"
#define SDA_PIN 8
#define SCL_PIN 9
#define SCREEN_WIDTH 128
#define SCREEN_HEIGHT 64
Adafruit_SSD1306 display(SCREEN_WIDTH, SCREEN_HEIGHT, &Wire, -1);
AS726X sensor;
void setup() {
Serial.begin(115200);
Wire.begin(SDA_PIN, SCL_PIN);
if (!display.begin(SSD1306_SWITCHCAPVCC, 0x3C)) {
while (1);
}
if (!sensor.begin()) {
while (1);
}
sensor.setGain(AS726X_GAIN_16X);
sensor.setIntegrationTime(50);
sensor.enableBulb(AS726X_LED_IR);
}
void loop() {
sensor.takeMeasurements();
delay(500);
}
- ESP32-C3-WROOM-2 with WiFi and BLE
- 610 nm to 860 nm spectral coverage
- ~20 nm channel bandwidth
- USB-C connectivity
- External I2C header
- Compact and portable
- Fruit ripeness estimation
- Material comparison
- Reflectance experiments
- Educational spectroscopy demos
- Embedded ML classification
- KiCad (Schematics & PCB)
- Fusion 360 (STEP modeling)
- Blender (3D render)
MIT License
Support this project on Hack Club:
https://blueprint.hackclub.com/projects/12271


