Circuit review & bench-test guide
AXS-040 — Capacitive soil-moisture carrier PMOD module
Document purpose#
This document explains the axs-040-soil prototype at component level and turns the design evidence into a practical manual-review and bench-test plan. It is based on the generated schematic (generate_design.py), the project README, the TI ADS7042 documentation, and public documentation for the common "Capacitive Soil Moisture Sensor v1.2"-style probe.
The board is a design-stage prototype. Repository status is schematic generated, ERC clean, PCB layout not started, not released. There is no fabricated board and no assembled first article. Every voltage, code, and timing figure below is a design target or a vendor-typical figure to verify on real hardware, not proof that an assembled module works. The capacitive probe is a hobby-grade part with weak, inconsistent, and sometimes wrong documentation; its figures are marked vendor-typical throughout. The ADS7042, by contrast, is a fully specified TI part.
1. What the board does#
The board is a PMOD Type 2 (SPI, read-only) carrier that digitizes the slow analog output of a 3.3 V capacitive soil-moisture probe (v1.2-style breakout) with an on-carrier ADS7042 12-bit SAR ADC. The probe is a 555-timer astable oscillator driving a coplanar-trace capacitor; soil moisture changes the probe capacitance, which changes the rectified/filtered DC level on its AOUT pin. The carrier RC-filters AOUT (R1 1 kΩ + C3 10 nF) into the ADC's AINP, ties AINM to GND (single-ended), and uses AVDD = 3.3 V as the conversion reference, so full scale = 3.3 V. The ADS7042 has no configuration registers: drop ~CS, clock 16 SCLKs, and read 12 bits left-aligned after two leading zeros.
Higher moisture means higher probe capacitance means lower AOUT voltage: in-air reads highest, submerged-in-water reads lowest.
Functional block diagram#
PMOD host (3.3 V) J1 probe socket J2
pin 6/12 3V3 ──┬── C1 100n ─ C2 1u (at U1) ──┬─────────> J2.1 VCC
│ └ C4 100n, C5 10u (at J2)
pin 1 ADC_CS_N ────────> ~CS ┌──────────┐
pin 4 SCK ─────────────> SCLK │ U1 │ SOIL_FILT SOIL_AOUT
pin 3 MISO <── R2 100R ── SDO │ ADS7042 │ AINP <── C3 ─┬── R1 1k ──< J2.3 AOUT
│ 12b SAR │ AINM ── GND │(10n to GND)
pin 5/11 GND ────────────────>└──────────┘ <────────────┴──────────> J2.2 GND
2. Safety and scope boundaries#
- Verify the probe pinout with a DMM before ever plugging it into J2 (procedure in section 9.B). Three-pin probe breakouts genuinely differ between clones (VCC/GND/AOUT vs GND/VCC/AOUT and others), and the carrier order is fixed at 1 VCC, 2 GND, 3 AOUT. A VCC/GND swap reverse-biases the probe's 555/regulator and can destroy the probe; AOUT swapped onto VCC back-drives the probe's output filter and gives meaningless readings.
- Use a 3.3 V-capable probe. Many v1.2 clones ship with an NE555 (minimum supply 4.5 V) despite advertising 3.3–5.5 V; at 3.3 V these misbehave or stick. This is a documented, widespread known issue — see section 6.
- Do not submerge the probe above its marked line. The SMD area (555, regulator, filter) is not waterproof; typical listings mark a maximum immersion line on the PCB. Water on the electronics corrupts readings immediately and corrodes the probe permanently.
- Never feed 5 V into the PMOD connector or J2: J2 VCC is hard-wired to the PMOD 3V3 rail, and the ADS7042 absolute maximum AVDD/DVDD region is 3.6 V class — a 5 V probe supply experiment must be done entirely off-board.
- Keep the carrier and host dry; only the probe blade goes into soil or water, with a cable drip loop.
- A calibrated dry/wet mapping is probe-specific and drifts with temperature, soil type, insertion depth, and probe aging. Do not treat the output as an absolute volumetric-water-content instrument; it is a relative indicator unless calibrated against gravimetric samples.
3. Power and signal sequence#
- The host (or bench supply) applies 3.3 V. C1/C2 decouple the ADS7042 AVDD/DVDD at the pins; C4/C5 hold the probe socket rail stiff against cable inductance and the probe's oscillator switching (probe draw is ~5 mA vendor-typical).
- The probe's 555 astable runs (order of 1.5 MHz on v1.2-style boards); its on-probe diode/RC network converts the moisture-dependent capacitance into a DC level on AOUT. Power-on settling is of the order of 1 s, and moisture-step settling can be tens of seconds on defective clones missing the output bleed resistor.
- R1 + C3 (1 kΩ + 10 nF, fc ≈ 16 kHz) low-pass the already-slow AOUT and double as the SAR charge bucket: C3 supplies the ADC's sample-capacitor inrush so R1's source impedance does not distort acquisition.
- The host runs the fixed ADS7042 frame: ~CS falling edge samples AINP, 16 SCLKs shift out two leading zeros then 12 data bits, ~CS high ends the frame. Code = AINP / 3.3 V × 4095 (AVDD is the reference).
- The host averages many samples (the probe is noisy and slow — a moving average is part of the intended lesson) and maps codes to moisture using the per-probe air/water calibration of section 9.E.
4. Interfaces and pin maps#
| PMOD pin (J1) | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Net | ADC_CS_N | NC (no MOSI) | MISO | SCK | GND | 3V3 | NC | NC | NC | NC | GND | 3V3 |
| J2 pin | Net | Role |
|---|---|---|
| 1 | 3V3 | Probe supply |
| 2 | GND | Return |
| 3 | SOIL_AOUT | Probe analog output into R1/C3 filter |
Note the J2 order differs from the flow carrier (AXS-039 uses VCC/SIGNAL/GND; this board uses VCC/GND/AOUT). Never assume a pigtail made for one carrier fits the other. #FLG01/#FLG02 are ERC power-flag symbols only, not physical parts.
Two usage contexts#
| Context | Power | Readout |
|---|---|---|
| (a) PMOD host | ULX3S-class ECP5 board, 3.3 V PMOD | HDL SPI master: ~CS + 16 SCLKs, unpack 12 bits, moving average |
| (b) Standalone bench | Bench supply 3.3 V to pins 6/12, GND to 5/11, current limit 50 mA | Lab MCU/logic analyzer drives SPI; independently, a DMM on SOIL_AOUT/SOIL_FILT verifies the analog chain without any SPI at all |
5. Component-by-component review#
| Ref. | Part / value | Function and why needed | If absent/open | If shorted, wrong, or misassembled |
|---|---|---|---|---|
| J1 | PMOD 12-pin plug, Type 2 SPI (read-only) | Host interface: 3V3/GND, ~CS, SCK in, MISO out | No power/communication | Mis-keyed insertion swaps power and signal rows; inspect keying every plug-in |
| U1 | TI ADS7042IDCUR, 12-bit 1 MSPS SAR ADC, VSSOP-8 | Digitizes SOIL_FILT; AVDD (= 3.3 V) is the reference, so full scale tracks the rail; no registers to configure | No digital output at all | Rotated package swaps supply onto SDO/SCLK and can destroy the part; poor VSSOP soldering gives stuck or noisy codes; AINM must be at GND or readings offset |
| J2 | Generic 1×3 pin socket, 2.54 mm (MPN TBD) | Probe connection, order 1 VCC / 2 GND / 3 AOUT | Probe cannot be connected | Wrong probe pin order: VCC/GND swap can destroy the probe; AOUT on pin 1 back-drives the probe output from the 3V3 rail through the probe's own ~10 kΩ filter (roughly sub-mA, misreading more likely than damage — but do not rely on that) |
| R1 | 1 kΩ 0603, Yageo RC0603FR-071KL | RC anti-alias / charge-bucket source resistor from SOIL_AOUT into the SAR input | ADC input floats: codes drift/read rail-ish garbage | Much larger value starves the SAR acquisition and adds gain error; short removes filtering (probe output is already RC-filtered on-probe, so this degrades, not destroys) |
| C3 | 10 nF 50 V C0G 0603, Murata GRM1885C1H103JA01D | Filter pole with R1 (fc ≈ 16 kHz) and charge reservoir for the ADC sample capacitor | Sampling glitches load R1 directly; codes noisier and rate-dependent | Short grounds the ADC input (codes near 0); X7R substitution here is acceptable electrically but C0G is specified for stability |
| R2 | 100 Ω 0603, Yageo RC0603FR-07100RL | Series protection/damping on the ADC-driven SDO→MISO line | Host pin sees the SDO driver directly; less protection on plug-in faults | Open floats MISO (host reads all-0/all-1 or noise); large wrong value slows edges at high SCLK |
| C1 | 100 nF 16 V X7R 0603, Murata GRM188R71C104KA01D | ADS7042 AVDD/DVDD decoupling, placed at the pins | Conversion noise, reference bounce — codes jitter, since AVDD is the reference | Short drags down 3V3; layout rule (at the pins) is a release checklist item |
| C2 | 1 µF 16 V X5R 0603, Murata GRM188R61C105KA93D | ADS7042 reference/bulk decoupling | Reference droop during bursts of conversions; gain wander | Short drags down 3V3 |
| C4 | 100 nF 16 V X7R 0603, Murata GRM188R71C104KA01D | Probe socket high-frequency decoupling | Probe's 555 switching couples onto the rail | Short drags down 3V3 |
| C5 | 10 µF 10 V X5R 0805, Murata GRM21BR61A106KE19L | Probe socket bulk reservoir (cable inductance + ~5 mA oscillator load) | Rail droop at the probe, noisier AOUT | Short drags down 3V3 |
| #FLG01, #FLG02 | ERC power flags | Schematic bookkeeping | ERC noise only | Not physical parts |
External (not on the BOM, but part of the system under test):
| Item | Part | Review point |
|---|---|---|
| Soil probe | "Capacitive Soil Moisture Sensor v1.2"-style, 3.3 V-capable | Must contain a TLC555 (or otherwise be verified at 3.3 V); pin order must be verified per unit; README lists "verify probe VCC/GND/AOUT order against a purchased probe" as an open release item |
6. Datasheet summary and design interpretation#
| Source | Key facts used here | Board-specific interpretation |
|---|---|---|
| TI ADS7042 product page / datasheet | 12-bit, up to 1 MSPS; AVDD 1.65–3.6 V used as reference; independent DVDD 1.65–3.6 V; SPI to 16 MHz; sampling on ~CS falling edge; INL/DNL ±1 LSB max; ~690 µW at 1 MSPS/3 V | Both supplies tied to 3V3 is in range; full scale = 3.3 V exactly as the design states. The soil signal is quasi-DC, so run far below 1 MSPS and spend the headroom on averaging. Because AVDD is the reference, rail noise is gain error — C1/C2 placement matters |
| TI TLC555 product page / datasheet | CMOS timer, single-supply 2–15 V, ~0.18 mA quiescent, 2.1 MHz capable, functionally interchangeable with NE555 | A genuine TLC555 probe is comfortable at 3.3 V. The NE555 it replaces needs ≥4.5 V — the root of the v1.2 3.3 V problem below |
| Cave Pearl Project: hacking the v1.2 capacitive probe | v1.2 topology: 555 astable ~1.5 MHz; on-probe 10 kΩ/1 µF output filter; vendors advertise TLC555 but ship NE555 units that do not run at 3.3 V; the on-board 662K 3.3 V regulator is below spec if supply <~3.4 V; some clones omit the 1 MΩ output bleed (R4), giving >35 s water→air response; at 3.3 V roughly ~3.0 V in air and ~1.5 V submerged (about 85 % / 35 % of supply with R4 fitted); ~1 s power-on settling; sensing field only ~3–6 mm from the probe surface; ~5 mA class draw | This is the most honest documentation that exists for these probes — a reverse-engineering blog, because vendor docs are unreliable. Every review point in section 9.B/9.D traces to it: chip marking check, bleed-resistor response check, air/water endpoints, insertion-depth sensitivity |
| DFRobot SEN0193 wiki (best-documented commercial variant) | Operating 3.3–5.5 V; output 0–3.0 V; ~5 mA; per-probe air/water two-point calibration is the vendor-recommended method | Confirms the supply/current budget and the calibration approach. Note its 0–3.0 V output span is for its board; generic clones differ. All probe voltage figures in this guide are vendor-typical, not guaranteed |
| Yageo RC-series thick-film resistors | General-purpose 1 % thick film | R1/R2 values are non-critical at these speeds |
Honesty note: there is no authoritative datasheet for "Capacitive Soil Moisture Sensor v1.2". It is an open hardware design cloned by many factories with silent substitutions (NE555 for TLC555, missing bleed resistor, altered filter values). The TI documents above are authoritative for the chips; the probe-level numbers are community-measured typicals.
7. Expected values before bench testing#
| Quantity | Design target / vendor-typical value | What to measure |
|---|---|---|
| Module current, probe unplugged | well under 1 mA (ADS7042 is µW-class) | Bench supply readout |
| Module current, probe plugged | ≈5–6 mA (probe ~5 mA vendor-typical) | Bench supply readout |
| SOIL_AOUT in air (driest) | ≈2.6–3.0 V at 3.3 V supply (≈80–95 % of rail; probe-dependent) | DMM at J2.3 / SOIL_FILT |
| SOIL_AOUT in dry soil | between air and moist readings; probe-specific | DMM + logged codes |
| SOIL_AOUT submerged to line (wettest) | ≈1.2–1.5 V at 3.3 V supply (≈35–45 % of rail; probe-dependent) | DMM at SOIL_FILT |
| Corresponding ADC codes (FS = 3.3 V) | air ≈3200–3720; water ≈1490–1860 (derived from the voltages above; typical, not guaranteed) | Host/MCU readout, averaged |
| ADC code with AINP shorted to GND (probe out, jumper) | 0–a few LSB | SPI readout |
| RC filter cutoff | ≈15.9 kHz (1 kΩ + 10 nF) | Design value; verify parts only |
| Power-on settling | ≈1 s (probe) | Log first seconds after power |
| Water→air response | seconds with bleed resistor fitted; >35 s on clones missing it | Timed step test, section 9.D |
| SPI frame | ~CS low, 16 SCLKs, 2 leading zeros + 12 data bits | Logic analyzer capture |
| SCLK rate | ≤16 MHz per datasheet; run ≤ a few MHz over PMOD wiring | Scope edge quality at MISO |
8. Manual schematic and assembly review checklist#
- Confirm J1 pinout against PMOD Type 2: ~CS pin 1, MISO pin 3, SCK pin 4, pin 2 deliberately NC (no MOSI), GND 5/11, 3V3 6/12.
- Confirm U1 pin-1 orientation on the VSSOP-8 and that the assembly used ADS7042IDCUR (not a pin-different ADS7040/ADS7041 variant).
- Verify AINM (U1 pin 5) is at GND and AINP (pin 6) connects through R1 to J2.3 — a swap reads inverted/zero.
- Verify R1 = 1 kΩ, R2 = 100 Ω, C3 = 10 nF C0G in-circuit before power.
- When layout exists: C1/C2 at U1's pins, C4/C5 at J2, RC filter adjacent to AINP (this is an explicit README release item).
- Confirm J2 silkscreen marks 1 VCC / 2 GND / 3 AOUT unambiguously, and that it visibly differs from the AXS-039 carrier's VCC/SIGNAL/GND order.
- Inspect the probe: read the 555 marking under magnification. "TLC555" (or other CMOS 555) is acceptable for 3.3 V; "NE555" is a known-bad clone at 3.3 V — reject or replace the chip. Check the bleed resistor position is populated (clone-dependent; compare against the Cave Pearl writeup).
- Confirm the probe's maximum-immersion line is marked; if not, mark one yourself below the SMD area.
9. Ordered bench-test procedure#
Stop at the first abnormal result. Record board serial, probe identity (a photo of both probe faces is the practical "serial number" for clones), equipment IDs, ambient temperature, and operator for every run.
A. Unpowered inspection and resistance tests#
- No probe, no host. Inspect solder under magnification; complete the section 8 checklist.
- Measure 3V3-to-GND resistance at J1 in both meter polarities; investigate any hard short before power (bulk-cap charging gives a rising reading).
- Measure J2.3 to U1 AINP: ≈1 kΩ (R1). Measure J1.3 (MISO) to U1 SDO: ≈100 Ω (R2).
B. Probe pin-order verification (before the probe ever touches J2)#
- Find GND by continuity. Meter in continuity mode from each connector pin to the probe's exposed ground pour / mounting-hole ring / 555 pin 1 region. Exactly one connector pin should beep. Mark it.
- Find VCC by current draw. Bench supply at 3.3 V with a 20 mA current limit, negative lead to the identified GND pin. Touch the positive lead to each remaining pin in turn: the VCC pin draws roughly 5 mA and the probe's oscillator starts; the AOUT pin draws almost nothing.
- Confirm AOUT by DC level. With VCC and GND correctly powered, the remaining pin shows a stable DC level of roughly 1–3 V that rises when you pull the probe out of your hand's grip and falls when you grip the blade (your hand is "moisture").
- Only now build/verify the pigtail so probe VCC→J2.1, GND→J2.2, AOUT→J2.3. Label the pigtail with the probe it was verified against.
- Consequences of skipping this: VCC/GND reversal reverse-biases the probe's 555 and regulator (destructive); AOUT on the VCC pin means the probe is unpowered and the carrier rail back-drives its output network (misreads, possible stress); GND/AOUT swap grounds the output (reads 0) and floats the probe return through the signal path (garbage).
C. First power and SPI bring-up, standalone context#
- Bench supply 3.3 V, 50 mA limit, to J1 pins 6/12 and 5/11. No probe. Current should be well under 1 mA.
- Temporarily jumper J2.3 to GND. Drive SPI from a lab MCU or logic analyzer with pattern generator: ~CS low, 16 SCLK cycles (start at ≤1 MHz), ~CS high. Expect two leading zeros then 12 bits reading 0 ± a few LSB. Remove the jumper; the input now floats and codes will drift — that is expected, not a fault.
- Optional midscale check: a bench divider (e.g. two 10 kΩ from 3V3 to GND) into J2.3 should read ≈2048 ± tolerance of the divider.
- Capture one full frame on a logic analyzer and archive it: this is the golden reference for the HDL testbench.
D. Probe attach and dry/wet/water staircase#
- Power off, plug in the verified probe, power on. Current rises to ≈5–6 mA. Log SOIL_FILT with a DMM and ADC codes simultaneously — the DMM validates the analog chain independently of SPI.
- Wait ≥5 s after power-on before trusting readings (vendor-typical settling ≈1 s; margin costs nothing).
- In air: expect the highest reading, vendor-typical ≈2.6–3.0 V (≈3200–3720 counts). Record the exact value — this is calibration endpoint A.
- Submerged in water to the marked line, never above it: expect the lowest reading, vendor-typical ≈1.2–1.5 V (≈1490–1860 counts). Record — endpoint W. If the reading takes tens of seconds to move, suspect a missing bleed resistor on the clone (known issue).
- Dry soil, then progressively moistened soil: readings must fall monotonically from near-A toward W as water is added. Absolute values are soil- and packing-dependent; only monotonicity and repeatability are pass criteria at this stage.
- Repeat the air/water endpoints in the PMOD host context (ULX3S-class host, SPI master HDL, moving-average filter) and confirm host codes match the standalone MCU codes within noise.
E. Per-probe calibration and sensitivity characterization#
- For each probe (calibration is per probe, not per design): record A (air) and W (water-at-line) as averaged codes at a noted temperature.
- Map linearly: moisture % = 100 × (A − code) / (A − W), clamped to 0–100. This is a relative scale, not volumetric water content.
- Characterize insertion depth: readings depend strongly on how much blade is buried (sensing field reaches only ~3–6 mm from the surface). Fix an insertion mark and always insert to it.
- Characterize temperature: log a probe in stable moist soil across the room's day/night swing; expect visible drift. Note it in the record rather than pretending it away.
- Repeatability: remove/reinsert the probe 5× at the mark in the same pot; the spread bounds the honest resolution of the measurement.
- Release-only items (out of bench scope): waterproofing/conformal coating of the probe SMD area for field use, long-term corrosion, gravimetric soil calibration if absolute readings are ever claimed.
10. Troubleshooting map#
| Symptom | First measurements | Likely areas |
|---|---|---|
| All-zero SPI reads | MISO level, frame capture, AINP jumper test | R2/MISO open, U1 unpowered/rotated, ~CS-SCLK swapped, AINP shorted to GND |
| All-ones / rail-ish codes | SOIL_FILT voltage vs code | AINP floating (probe unplugged/AOUT open), R1 open, AINM not at GND |
| Codes jitter badly | C1/C2 presence, AVDD ripple on scope | Decoupling missing/far from pins (AVDD is the reference), SCLK too fast over PMOD wiring, missing averaging |
| Reading stuck near rail with probe wet | 555 marking, probe supply voltage | NE555 clone not oscillating at 3.3 V — the documented known issue; replace probe or fit a TLC555 |
| Water→air response takes >30 s | Timed step test | Clone missing the output bleed resistor (known issue); add ~1 MΩ across probe output or replace probe |
| Air and water read nearly the same | Endpoints A/W, probe immersion depth | Damaged/corroded probe, water above the line (electronics wet), v2.0-style clone with mismatched filter |
| DMM voltage right, codes wrong | Golden frame vs current capture | Bit unpack error (2 leading zeros!), CPOL/CPHA, counting 12 vs 16 clocks |
| Current far above ~6 mA | Probe unplugged retest | Reversed probe pinout (stop immediately), C4/C5 short, damaged probe |
| Works standalone, fails on host | Pin constraints, frame on analyzer | PMOD pin mapping, I/O standard, SCLK gating glitches in HDL |
11. Bench record template#
| Field | Record |
|---|---|
| Board revision / serial | |
| Probe identity (photos both faces), 555 marking, bleed resistor present | |
| Probe pin-order verification result (GND/VCC/AOUT map) | |
| Module current: no probe / with probe | |
| AINP-grounded and midscale SPI results | |
| Golden SPI frame capture (file path) | |
| Endpoint A (air): code, voltage, temperature | |
| Endpoint W (water at line): code, voltage, temperature | |
| Water→air response time | |
| Soil staircase monotonicity result | |
| Insertion-depth and reinsertion spread | |
| Host-vs-standalone code agreement | |
| Deviations, photos, raw-file paths | |
| Reviewer / date / disposition |
12. Review conclusion#
The carrier design is sound and appropriately conservative: a fully specified TI ADC with supply-as-reference, an RC filter that doubles as the SAR charge bucket, series protection on the one module-driven line, and generous decoupling at both the ADC and the probe socket. Every significant risk lives in the probe, not the carrier: unverified clone pin order (the single most likely way to destroy hardware on first plug-in), NE555 clones that silently fail at 3.3 V, missing bleed resistors that make response times absurd, and the complete absence of guaranteed specifications for the probe class. The bench plan therefore front-loads probe verification (section 9.B) before the probe ever touches the carrier, and treats the per-probe two-point air/water calibration — not any vendor number — as the authoritative transfer function. PCB layout, the HDL SPI master, and a purchased-probe pin-order confirmation remain open README items before any release claim.