How an invisible whiff of H2S becomes a number in your firmware — and exactly which wire goes where on the breadboard.
Each stage does one job. Follow the whole journey of a single measurement:
| Stage | What it is | What it does |
|---|---|---|
| Sensor | Alphasense H2S-A4 electrochemical cell | Gas reacts at an electrode → produces a tiny current (nanoamps per ppm). Too small to read directly. |
| AFE | Analogue Front End board | Turns that tiny current into a clean, buffered voltage (WE + AE outputs), plus a Pt1000 temperature voltage. Needs 3.5–6.4V power. |
| ADS1220 | 24-bit ADC (the purple board) | Measures the analog voltage very precisely and turns it into a digital number. |
| Pico W | RP2040 microcontroller | Reads that number over SPI (four digital wires), runs your TinyGo firmware, later ships it over MQTT. |
Analog vs digital is the key split. Everything left of the ADS1220 is fragile analog voltage — keep those wires short and share a ground. Everything right of it is robust digital SPI. The ADS1220 is the translator between the two worlds. That's why it sits in the middle.
Drag to orbit. Use the buttons to light up just one kind of connection — start with Ground (everything shares it), then SPI, then Analog.
The Pico W is seated on a Freenove breakout board (the dark board with yellow header pins on the right). You don't jumper to the Pico directly — every GP## and power pin is fanned out to a labeled header on the breakout, so all the wires from the ADS1220 land there. Same pin names as the tables below.
Each 3D wire is one net (a bundle), not one Dupont jumper — the real build uses an individual Dupont per pin. Section 4 says how many and which gender.
Same wiring, drawn as a clean block diagram. Print this and the wiring card for the bench.
DOUT line will push 5V into the Pico and damage it. So the ADS1220
runs on 3.3V. Only the AFE gets 5V.
You only have Dupont jumpers, so two rules keep it sane.
Rule 1 — the gender you need is the opposite of what you plug into:
| Plugging into… | Use this Dupont end |
|---|---|
| Breadboard hole (female socket) | Male |
| A male header pin (ADS1220 pins, breakout pins, AFE pins) | Female |
Rule 2 — seat the ADS1220 on the breadboard, straddling the center gap. Push its male pins down into the holes so the two sides of the chip land on opposite sides of the center notch. Now each ADS1220 pin owns a 5-hole row. To connect to a pin, plug your wire into any other hole in that same row — the 5 holes on one side of the gap are one electrical node. To reach power, run a jumper from that row to the +5V, +3V3, or GND rail.
What each link needs (breadboard = female holes; ADS1220 seated):
| Connection | From → To | Dupont |
|---|---|---|
| Rails → seated ADS1220 rows (AVDD, DVDD, AGND, DGND, CLK) | hole → hole | male–male |
| SPI ×5 ADS rows → Pico breakout pins | hole → male pin | male–female |
Pico breakout 3V3 / GND pins → rails | male pin → hole | male–female |
| Analog ×4 AFE pins → ADS1220 rows | male pin → hole | male–female |
AFE VIN / GND pins → rails | male pin → hole | male–female |
Inventory check: with the ADC seated you need mostly male–male and male–female jumpers. You only need female–female if you leave the ADS1220 loose (unseated) and join its male pins straight onto AFE/breakout male pins with no breadboard in between — not the method here.
GND header — the Pico is powered over its own USB),
ADS1220 AGND+DGND, and AFE GND. No shared ground = nonsense readings.
(This is the dashed loop in the schematic and the dark wires in 3D.)AVDD→+3V3, DVDD→+3V3,
AGND/DGND→GND, CLK→GND (uses the internal
oscillator). Leave REFP0/REFN0 unconnected — we use the internal 2.048V reference.SCLK→GP18, DIN/MOSI→GP19, DOUT/MISO→GP16,
CS→GP17, DRDY→GP20. Each is a male–female Dupont: male end
into the ADS1220 pin's row, female end onto the breakout's labeled GP## header.VIN → the +5V rail
(never to the ADC), AFE GND → GND rail. The MB102 output is convenient but
electrically noisier than a lab supply — fine for bring-up; revisit supply quality later for
clean ppb-level data.WE→AIN0, AE→AIN1, Pt1000+→AIN2,
Pt1000−→AIN3. male–female Dupont: female onto the AFE output pin, male
into the same breadboard row as that ADS1220 input. Confirm which OP
pins are the populated H2S slot from the board silkscreen + calibration sheet.AVDD wire to the 5V rail while keeping DVDD/logic on
the 3.3V rail (Pico safety).AIN0–AIN1, set the PGA and 20 SPS data rate, pick the
internal 2.048V reference, then read DRDY and pull the 24-bit sample. That's your
first number. (ADR-0006 calls for exactly this driver.)
Q1. Why can't the Pico's 3.3V power the AFE directly?
▸ reveal
Q2. The ADS1220 has 4 analog inputs but the H2S sensor gives 2 outputs (WE, AE). What are AIN2 and AIN3 for?
▸ reveal
Q3. You measure AE = 4.1V. What do you do before connecting it to the ADC?
▸ reveal
next lesson for the ADS1220 driver, or quiz me to be tested
out loud on the signal chain.