Academic
1-Wire digital thermometer in VHDL on FPGA
Complete VHDL synchronous system on Nexys A7 FPGA (Artix-7). 6 FSMs for 1-Wire communication with DS18S20. 7-segment display, 0.5°C precision, validated on oscilloscope.
- 6
- FSMs designed
- 0.5°C
- Precision
- 480 µs
- 1-Wire reset
01Context
Two-person lab project at ENSEEIHT: a low-level serial protocol where every timing is a matter of microseconds.
02Technical pipeline
- FSM Init (480 µs reset)
- FSM Write0/Write1
- FSM Write8b (ROM/RAM)
- FSM Read (15 µs)
- Master Protocol
- Double Dabble → 7-seg
03What I did
Clock edge synchronization buffer (INPUT_SYNC, RST_SYNC) and centralized system timer management (start/end vectors, clk_1s pulse).
FSM Init: 1-Wire reset sequence (480 µs pull-down, DS18S20 presence detection).
FSM Write0/Write1: 1-bit write on 1-Wire bus with precise timings (1 µs / 60 µs).
FSM Write8b: 8-bit command transmission (Skip ROM 0xCC, Convert T 0x44, Read Scratchpad 0xBE).
FSM Read: 1-bit read from DS18S20 (1 µs pull-down, sampling at 15 µs).
FSM Master Protocol: full orchestration (Init → ROM → RAM → 9-bit temperature reading).
Display: Double Dabble (BCD), negative handling (two’s complement), 7-segment multiplexing.
Timing and 1-Wire sequence validation on Keysight oscilloscope.
04Measured results
- 6
- FSMs implemented
- 0.5°C
- Display precision
- 480 µs
- 1-Wire reset
- 1 µs
- Write bit timing
- 15 µs
- Read sampling
05Challenges
- Critical 1-Wire timings (µs precision) on Artix-7 FPGA
- Indexing bug in the Write8b FSM (index incremented before the bit is sent), identified while validating the master protocol
- Async/sync reset synchronization: async stop, restart on clock edge
Want to talk it through?
Happy to go into the technical choices, the measurements and what I would do differently.