a Low-Cost IoT Gamma-Ray Spectrometer with the Easy-F407V-ETH (W5500) Board
A low-cost IoT gamma-ray spectrometer built with STM32F407 and WIZnet W5500, streaming real-time radiation spectra to a PC.
The W5500's role is transformative: It converts a standalone analyzer into a networked IoT instrument—opening applications in remote monitoring, distributed sensor networks, and cloud-based radiation surveillance systems.
- STM32F407: High-speed ADC + DMA for gamma pulse measurement
- W5500 Ethernet: Real-time spectrum streaming to PC
This combination enables real-time analysis of hundreds to thousands of radiation events, displaying live gamma spectra on a PC screen.
1. System Concept – How a Gamma Spectrometer Works
Gamma rays are invisible, so they must be converted into energy values through the following stages:
① Scintillator — Gamma → Light
When gamma rays enter a crystal such as NaI(Tl), a brief light flash occurs. The brightness of the flash corresponds to the gamma-ray energy.
② PMT (Photomultiplier Tube) — Light → Voltage
Amplifies faint light by millions of times, resulting in an electrical pulse of several volts. Requires high voltage (500-1000V).
③ Analog Conditioning — Clean Pulse
Preamplifier + shaping amplifier refine the signal into a clean Gaussian pulse that the STM32 can read effectively.
Result: Each gamma-ray event is represented as a single pulse, where the peak height equals the gamma-ray energy.
2. STM32F407 – Ultra-Fast Pulse Processing Core
The performance of this project is determined by the STM32F4's 12-bit ADC + DMA + EXTI combination.
High-Speed Capture Pipeline
Amplifier Output → ADC (PA0) → DMA Circular Buffer → EXTI Trigger →
Pulse Peak Detection → Histogram BinningTechnical Core: NDTR-Based Buffer Indexing Algorithm
The key challenge is locating where a newly arrived pulse resides in the DMA circular buffer. Using NDTR (Number of Data Transfer Remaining), the system:
- Immediately calculates pulse position
- Averages surrounding samples
- Accurately detects peaks
Before algorithm optimization: Spectrum peaks were blurred
After optimization: Very sharp energy peaks (experimentally validated)
Processing Speed: ~8 µs per event analysis
3. W5500 Ethernet – Turning It into an IoT Scientific Instrument
This spectrometer transcends a simple MCU project, expanding into a network-based real-time measurement device.
W5500's Role
- TCP/IP Offload: Minimizes MCU load
- Stable Streaming: Handles thousands of events per second
- Immediate PC Plotting: Ensures transmission speed for real-time visualization
- IoT Measurement: Enables networked instrumentation without OS or Linux
With W5500, the system becomes a complete Real-Time Radiation Spectrum Monitoring Device.
4. Real Measured Spectra (Actual Results)
Am-241 (Americium) – 59.5 keV Peak
- Two distinct low-energy peaks
- Exact match with theoretical values
- Validates proper MCA functionality
Lu₂O₃ (Natural Lutetium)
- Expected peaks: 202 keV, 307 keV
- Measured: Strong peak at ~200, secondary peak near ~300, similar 509 keV composite peak structure
- Matches characteristic pattern of natural lutetium samples
Uranyl Nitrate (Uranium Compound)
- Characteristics: Sharp peak in low-energy region, gradual distribution in mid-energy range, long tail structure
- Highly similar to typical spectrum of natural uranium compounds
Unknown "Anion Powder" Sample
- Results: Clear low-energy peak, multiple mid-range bumps, continuous tail
- Confirms presence of natural radioactivity
- Not a single isotope, but sufficient for "radioactive material presence detection"
5. Easy-F407V-ETH Board – Custom Hardware Design
| Component | Role |
|---|---|
| STM32F407VET6 | High-speed ADC + pulse processing |
| W5500 | Hardware TCP/IP Ethernet |
| Clean analog routing | Prevents PMT/AMP signal degradation |
| Compact board | Optimized for lab/field testing |
The board is not just a development platform but a carefully designed experimental measurement instrument platform that harmonizes analog signal processing, high-speed MCU, and networking.
Why This Project Is Important
This project is a rare case that fuses two domains:
1) Professional-Grade Physics Experimental Equipment (Gamma-Ray Spectrometer)
- Actual isotope identification capability
- Real-time energy histogram generation
2) IoT-Based Real-Time Measurement (Streaming MCA)
- Networked instrumentation using W5500
- Remote monitoring and data collection capability
- Low-cost educational and research equipment fabrication
Conclusion
This project demonstrates the following:
✔ STM32F4's DMA + high-speed ADC alone can implement a professional MCA (spectrometer)
✔ Combined with W5500 Ethernet, it achieves functionality comparable to Networked Radiation Monitoring Devices used in research institutions
✔ Even with low-cost open hardware, it achieves scientific precision capable of properly distinguishing spectra of Am-241, Lu₂O₃, Uranium, and more
Final Summary
- IoT radiation analysis equipment ready for immediate use in education, research, and scientific experiments
- Validated project with clearly detected actual isotope spectra
- Engineering completeness with high-speed DMA + NDTR algorithm implementation
- Complete IoT measurement platform with W5500-based real-time streaming
- Rare-quality project that is low-cost DIY yet possesses professional functionality

