EMBEDDED HARDWARE · ELECTROMECHANICAL DESIGN · CNL

Sample Subway – Nuclear Pressure Tube Sampling System

An embedded remote-controlled device engineered for Canadian Nuclear Laboratories (CNL) to retrieve and weigh 30–80 mg metal samples within 4-inch internal diameter, 15-foot nuclear pressure tubes.

// TEAM & ACADEMIC CONTEXT

Developed alongside Isaac Pinarski (Civil Eng Student), Radhe Pandey (Civil Eng Student), and Eden Irwin (Chem Eng) in Professor David Knox’s class. I functioned as group lead, but we rotated responsibilities on the project.

ASSEMBLING SYSTEM...

01 // SYSTEM OVERVIEW & SPECIFICATIONS

// PROJECT SCOPE & CLIENT VISION

Electromechanical remote sampling tool engineered for Canadian Nuclear Laboratories (CNL) to collect [ 30–80 mg ] metal samples from 4-inch ID, 15-foot nuclear pressure tubes for hydrogen embrittlement destructive testing. The lead engineer from Canadian Nuclear Laboratories emphasized a strong interest in seeing unique, innovative, and fully developed solutions rather than standard off-the-shelf concepts.

// DESIGN CONSTRAINTS & BOUNDARIES

Strict $100 CAD total project budget, complete setup and handling by a single operator with zero radiation exposure, dual-orientation travel (horizontal/vertical), 100% failsafe retrievability, self-contained onboard power, and cycle completion within a 10-minute operational window.

Sample Subway CAD Render
CAD rendering of the complete Sample Subway electromechanical assembly.

// SYSTEM ARCHITECTURE BREAKDOWN

Processing & Logic

ESP32-WROOM-C3 Microcontroller (C++ / Arduino IDE Firmware)

Movement & Recovery

Dual 12V N20 200 RPM Gearmotors (Drive Motors) + Custom Winch Spool & Paracord Tether (Vertical Recovery)

Actuation & Scraping

JGB37-520 12V 7RPM High-Torque Gearmotor + BTS7960 43A High-Power H-Bridge Driver + MGEHR1212 Lathe Tooling

Sensor & ADC Circuitry

100g Strain-Gauge Load Cell + HX711 24-bit Differential ADC Module

Power System & Regulators

Custom 3S1P Li-Ion Battery Pack (3x Molicel 21700 P42A Cells, 11.1V Nominal, 4500mAh) + 3S 40A BMS Board + LM2596 Buck Regulator (5V/3.3V Logic)

Communications

ESP32 Bluetooth + WiFi Telemetry + Mobile Operator UI/UX Tablet Application

02 // ENGINEERING METHODOLOGY & TARGET SPECIFICATIONS

USER REQUIREMENTS

Needs Analysis & Prioritization

Transformed CNL client statements into prioritized engineering design criteria:

  1. Safety & Exposure Limitation: Self-sealing sample containment & zero direct radioactive contact.
  2. Single-Operator Handling: Fully deployable, operable, and retrievable by 1 technician without secondary assistance.
  3. Budgetary Ceiling ($100): Total prototype procurement and BOM strictly capped under [ $100 CAD ].
  4. Unique & Fully Developed Solution: Novel electromechanical architecture fulfilling CNL lead engineer's mandate for distinctive solutions.
  5. Complete Removability: Winch tether emergency recovery failsafe for 100% retrieval guarantee.
  6. Payload Precision: Target sample extraction of [ 30–80 mg ].
  7. Data Feedback: Prototype mass verification via onboard ESP32 Bluetooth + WiFi to avoid umbilical cable complexity.
  8. Modularity & Envelope: Length < 4 ft, diameter < 4 in.
  9. Self-Contained Power: Onboard high-current Li-ion battery pack.
  10. Operational Speed: Cycle completion within < 10 minutes.
DESIGN ENVELOPE & BOUNDARIES

Functional Limits & Constraints

Target engineering performance envelope, cost ceiling, and boundary constraints:

Functional Requirements

  • Single-Operator Usability: Solo deployment, guidance, and recovery
  • Mass Collection: [ 30–80 mg ] (verified via scale feedback)
  • Complete Removability: 100% retrieval guarantee with tether backup
  • Enclosed Sample: Self-sealing spring-loaded lid
  • Distance Traveled: [ 15 ft ] inside pressure tube
  • Cycle Time: [ < 10 min ] total deployment

Physical & Budgetary Constraints

  • Total Project Budget: [ $100 CAD ] strict financial limit
  • Operator Footprint: [ 1 Operator ] single-person handling
  • Outer Diameter: [ < 4.0 in ] envelope
  • Total Tool Length: [ < 4.0 ft ]
  • Total Tool Mass: [ < 5.0 kg ] man-portable
  • Operator Contact: Zero manual touch on radiation tooling
CONCEPT COMPARISON

Trade-off Analysis & Architecture Selection

Evaluated 4 global concepts (Sample Subway, Pipe Worm, Pneumatically Deployable Tool, and Flywheel Flinger) against weighted client criteria, target engineering specifications, and manufacturing feasibility.

// TABLE 01: CONCEPT SUBSYSTEM ARCHITECTURE

Concept Movement Sampling Tool Containment Emergency Failsafe Evaluation & Trade-offs
Sample Subway
SELECTED
Modular Drive Wheels (Dual 12V N20 Motors) Lathe Tool Bit Scraping Profile Spring-Loaded Sliding Lid / Retention Lip Paracord Tether & Winch Spool Superior traction in dual orientations; predictable cutting depth without stalling; failsafe mechanical tether ensures 100% recovery.
The Pipe Worm Pneumatic Inchworm (Inflatable Caps + Actuator) Abrasive Rotary Sanding Pad Suction Vacuum Chamber Negative Pressure Vacuum Pull Slow multi-step peristaltic movement; abrasive sanding dust created high residue contamination risks in tube.
Pneumatic Tool Telescoping Inflatable Segmented Tube Articulated Arm / Multi-Tool Head Pneumatic Clamshell Vessel Deflate & Reverse Tension Pull Compact storage, but managing external high-pressure pneumatic lines added operational complexity and puncture risk.
Flywheel Flinger High-Speed Dual Flywheel Launcher Dynamic Flap Friction Scraper Spring-Loaded Flap Closure Tensioned Recovery Line & Spool High initial velocity, but uncontrolled ballistic impacts risked tube wall damage and loss of sample capture.

// TABLE 02: CONCEPT EVALUATION & FEASIBILITY WEIGHTING

Scoring Scale: 1 = Poor / High Risk · 2 = Moderate / Acceptable · 3 = Superior / Optimal

Evaluation Criteria Sample Subway (C1) The Pipe Worm (C2) Pneumatic Tool (C3) Flywheel Flinger (C4)
Radiation Containment & Operator Safety 3 1 3 1
100% Removability & Emergency Tether 2 1 3 1
Modular & Lightweight Packaging 2 2 3 2
Novelty & Creative Solution 1 3 3 3
Operational Speed & Cycle Time 3 1 3 3
Packaging & 4.05" Pipe Bore Clearance 2 1 3 3
Mechanical Complexity & Execution 3 2 1 2
Raw Concept Score (out of 21) 16 / 21 11 / 21 19 / 21 15 / 21
Overall Feasibility Weighting Factor 1.00x 0.65x 0.60x 0.75x
Final Feasibility-Adjusted Score 16.0 SELECTED 7.2 11.4 HIGH RISK 11.3
// Selection Justification & Feasibility Trade-offs: In the initial unweighted concept evaluation, the Pneumatically Deployable Tool (Concept 3) scored the highest raw score (19 / 21) due to its high architectural novelty, compact storage, and rapid theoretical inflation. However, due to its low rating for manufacturing feasibility (requiring custom airtight segmented bladders, multi-port pneumatic valves, and complex micro-rotary joints), the team could not envision fabricating and delivering this design within the strict $100 CAD budget ceiling and semester deadline. Applying an overall feasibility weight factor to account for timeline and budgetary constraints, the Sample Subway (Concept 1) emerged as the winning design with an adjusted score of 16.0. It achieved a 1.00x feasibility rating, reliable traction in dual orientations, a foolproof mechanical tether failsafe, and predictable lathe-bit cutting geometry, allowing the group to successfully build, test, and validate a physical prototype under budget ($96.19 actual BOM).

03 // SAMPLE SUBWAY SUBSYSTEM BREAKDOWN

SUBSYSTEM 01 // SAMPLING & SCRAPING TOOLING

Lathe Tool Bit & Scraping Profile

Integrates a high-torque JGB37-520 12V 7 RPM DC gearmotor driving an industrial MGEHR1212 lathe tool bit through a high-power BTS7960 H-bridge driver. We performed geometric cross-sectional modeling in OnShape of the 4.05-inch pipe wall and crawler chassis radius to calculate the cutting trajectory. By optimizing motor placement and cutting radius, the tool extracts an estimated target mass of [ 65 mg ] (within the client's [ 30–80 mg ] spec window) without cutting too deep, preventing motor stalls or excessive tube wall damage.

SUBSYSTEM 02 // SAMPLE CONTAINMENT

Spring-Loaded Self-Sealing Vessel

Custom 3D-printed containment container featuring an automated spring-loaded sliding lid. Upon insertion into the Subway's tool head, a mechanical retention lip catches the container's edge to hold the sliding door open directly beneath the cutting bit during active scraping; upon removal, dual internal compression springs automatically force the lid shut, securely isolating the sample so the operator is shielded from radioactive exposure.

SUBSYSTEM 03 // LOCOMOTION & TRACTION

Bi-Directional Drive & Friction Interface

Driven by dual 12V N20 200 RPM micro-metal gearmotors powering modular drive wheel assemblies. Tested multiple wheel surface interfaces—progressing from raw 608 steel bearings (high slip) to 3D-printed TPU sleeves, and finally compressible rubber traction bands to maintain necessary normal wall force and prevent chassis rotation under scraping counter-torque across both horizontal and vertical pipe runs.

SUBSYSTEM 04 // EMERGENCY FAILSAFE & RECOVERY

High-Tensile Tether & Winch Recovery

Independent mechanical recovery failsafe featuring a 550 Paracord tether line anchored to a reinforced structural chassis tow-eyelet and spooled onto a manual/motorized retrieval winch. Guarantees 100% physical retrieval of the crawler and contained sample in the event of battery exhaustion, motor stall, or signal loss inside the 15-foot pressure tube.

// DESIGN CONCEPTS & CAD SCHEMATICS

04 // PROJECT EXECUTION & PROTOTYPING TEST PLAN

Structured engineering development framework tracking progressive milestone tasks, risk mitigation, and staged subsystem prototyping plans from initial concept validation through final client delivery for Canadian Nuclear Laboratories.

// 01. PROJECT SCHEDULE & MILESTONE TASK PLAN

Phased development plan executed across the 13-week engineering lifecycle, tracking critical deliverables, software modeling, and hardware fabrication tasks managed via Trello and Gantt scheduling:

Phase / Milestone Timeline Key Objectives & Engineering Deliverables Tooling & Platform Status
Phase 01: Needs & Requirements Weeks 1–3 Client interviews, interpreted needs hierarchy, target specification definitions (30–80 mg payload window, <$100 budget ceiling), and technical benchmarking. Google Docs, Sheets DONE
Phase 02: Conceptual Ideation Weeks 4–6 Developed 4 global architectures across 4 subsystems (Movement, Sampling, Containment, Failsafe); evaluated trade-offs via quantitative decision matrix and feasibility weighting. OnShape, Miro DONE
Phase 03: CAD & Schematic Design Weeks 7–8 Parametric 3D chassis modeling, lathe bit cross-sectional geometric scraping analysis, circuit schematic capture, and dual-voltage power tree routing. OnShape, KiCad DONE
Phase 04: Progressive Subsystem Builds Weeks 9–11 Iterative fabrication of 5 focused Lo-Fi/Hi-Fi prototypes: load cell flexure & DSP filtering, lathe bit cutting armature, spring-loaded containment, and drive locomotion. Bambu A1, Arduino IDE DONE
Phase 05: Integration & Validation Weeks 12–13 Comprehensive electromechanical integration, 15 ft pipe run testing, Bluetooth telemetry data logging, Figma tablet operator UI, and final CNL client design day presentation. Keyshot, Figma, Serial API DONE

// 02. STAGED PROTOTYPE TEST PLAN & STOPPING CRITERIA

Iterative test matrix guiding subsystem validation, quantitative metrics, and stopping criteria across 5 staged prototypes:

Prototype Stage Target Subsystem Fidelity & Scope Evaluation Metrics & Stopping Criteria Test Results & Key Design Iterations
Prototype I Instrumentation & Measurement Focused Hi-Fi
100g Load Cell + HX711 ADC
Stable mass detection with ±1 mg resolution; noise floor <10 mg over 5 consecutive test runs. Raw noise (±100 mg) was stabilized down to ±9.5 mg via recursive moving average and dynamic zero-tracking creep compensation.
Prototype II Sampling & Tooling Focused Hi-Fi
JGB37 Motor + MGEHR1212 Lathe Bit
Successful material extraction yielding 30–80 mg shavings without stalling motor or binding in tube. Validated OnShape geometric cutting arc. Scraping rotation extracted ~65 mg target yield while maintaining safe motor current limits.
Prototype III Sample Containment Focused Hi-Fi
Spring-Loaded Sliding Vessel
Zero manual touch on radiation payload; 100% automated lid closure upon chassis extraction over 5 cycles. Eliminated magnetic latching due to ADC interference; engineered 3-spring dual rail mechanism for positive mechanical closure.
Prototype IV Locomotion & Traction Focused Lo-Fi
Dual N20 Motors + Wheel Mounts
Traverse 15 ft pipe in <2 min; maintain traction under scraping counter-torque across horizontal/vertical runs. Tested progression: 608 steel bearings (slipped) ➔ TPU printed sleeves (insufficient grip) ➔ high-friction compressible rubber tires (passed).
Prototype V Comprehensive System & UX Comprehensive System
Chassis + Electronics + Figma UI
Full mission cycle <10 min; live Bluetooth wireless telemetry; successful tether recovery failsafe. Integrated complete electromechanical package under $100 budget ($96.19 actual); verified live mass telemetry and operator workflow.

// 03. PROTOTYPING EQUIPMENT & SOFTWARE STACK

HARDWARE TOOLCHAIN

Fabrication & Assembly Equipment

  • Bambu Lab A1 3D Printer: Additive rapid prototyping of PETG/PLA chassis, wheel mounts, and containment slider.
  • Soldering & Fume Station: High-current wiring harness, BTS7960 motor driver, and ESP32 power rails.
  • Spot Welder & Heat Gun: Custom 3S1P Molicel 21700 cell pack spot-welding and insulated conduit heat shrinking.
  • Digital Multimeter: Voltage drop profiling, load-cell excitation calibration, and current draw analysis.
SOFTWARE TOOLCHAIN

CAD, Firmware & UI Platforms

  • Onshape (Parametric CAD): 3D geometry modeling, chassis assembly fit, and cross-sectional cutting arc simulation.
  • KiCad (Electronic EDA): Power delivery tree schematic capture, buck converter routing, and noise rejection layout.
  • Arduino IDE (Embedded C++): Real-time ESP32 firmware, moving-average DSP filtering, and Bluetooth telemetry streaming.
  • Figma & Keyshot: Interactive mobile operator UI/UX wireframing and high-fidelity photorealistic CAD rendering.

05 // HARDWARE & SENSOR CIRCUITRY

VOLTAGE REGULATION

Dual-Voltage Power Tree

Unregulated 12V bus powering the BTS7960 and N20 motor drivers. Stepped down via LM2596 buck converter to 5V VIN for the ESP32, which supplies 3.3V logic rails.

[ 3S1P Li-Ion Pack: 11.1V / 4500mAh ]
├── Unregulated 12V Bus ➔ BTS7960 & N20 Motors
└── LM2596 Buck Regulator ➔ 5V VIN ➔ ESP32 ➔ 3.3V Logic Rails
ANALOG INSTRUMENTATION

Strain-Gauge Flexure & 24-Bit ADC

Wheatstone bridge load cell interfaced with the HX711 24-bit ADC. Implemented twisted-pair wiring to reduce electrical noise from adjacent DC motors inside the chassis.

[ 100g Strain Gauge Wheatstone Bridge ]
└── Twisted-Pair Differential Wiring (Noise Rejection)
└── HX711 24-bit ADC Module ➔ ESP32 GPIO

06 // EMBEDDED C++ FIRMWARE & COMMUNICATION STRATEGY

Custom C++ firmware and Python ground station toolchain developed for load cell acquisition, BTS7960 high-current scraping actuation, dual N20 locomotion, digital filtering, and Bluetooth telemetry data logging. Bluetooth communication was an internal engineering decision adopted to eliminate the cost, weight, and failure modes of wired slip rings or umbilical cables. Because the low-cost ESP32 development board featured integrated Bluetooth hardware, it drastically reduced project spending while allowing the team to concentrate resources on the primary mechanical scraping, traction, and containment subsystems.

MODULE 01 // DSP FILTER

100-Sample Moving Average Filter

Reduces raw load cell fluctuation from [ ±100 mg ] down to an acceptable noise floor of [ ±9.5 mg ] for accurate sample mass determination.

float applyMovingAverage(float sample) {
  sum -= samples[index];
  samples[index] = sample;
  sum += sample;
  index = (index + 1) % 100;
  return sum / 100.0f; // ±9.5mg noise
}
MODULE 02 // CALIBRATION

Dynamic Creep Drift Auto-Tare

Monitors 30-second thermal and physical sensor drift. If variance stays below [ 10 mg ], the routine auto-tares the scale to eliminate baseline creep.

long correctCreep(long weight_mg) {
  unsigned long curr = millis();
  if (curr - lastCreep >= 30000) {
    float offset = weight_mg - prevWt;
    if (abs(offset) < 10.0f) {
      scale.tare(); // Auto-tare drift
      prevWt = 0; return 0;
    }
    prevWt = weight_mg; lastCreep = curr;
  }
  return weight_mg;
}
MODULE 03 // MOTOR ACTUATION

BTS7960 PWM Scraping Control

Drives the JGB37-520 12V high-torque motor with controlled PWM duty cycles (50% forward cutting, 75% clearing reverse) to prevent high-current BMS cutoffs.

void executeScrapingCycle() {
  digitalWrite(REN, HIGH); digitalWrite(LEN, HIGH);
  analogWrite(RPWM, 127); // 50% cutting torque
  analogWrite(LPWM, 0);
  delay(3000);            // 3-second cutting arc
  analogWrite(RPWM, 0);   // Spindle halt
  delay(1000);
  analogWrite(LPWM, 191); // 75% reverse clear
  delay(3000);
  analogWrite(LPWM, 0);
}
MODULE 04 // LOCOMOTION

Dual N20 Directional Drive

Controls dual 12V 200 RPM drive motors through timed directional pulses and PWM enable staging for navigating 15-foot horizontal pipe sections.

void traversePipe(int direction, int durationMs) {
  analogWrite(ENA, 255); // 100% drive duty
  if (direction == 1) {  // Forward locomotion
    digitalWrite(IN1, HIGH); digitalWrite(IN2, LOW);
  } else {               // Reverse locomotion
    digitalWrite(IN1, LOW);  digitalWrite(IN2, HIGH);
  }
  delay(durationMs);
  digitalWrite(IN1, LOW);  digitalWrite(IN2, LOW);
}
MODULE 05 // TELEMETRY

Secure Bluetooth Serial (RFCOMM)

Streams paired 9600-baud CSV packets (Timestamp, Raw Mass, Filtered Mass) to ground monitoring devices without requiring wired umbilical slip rings.

void setupTelemetry() {
  SerialBT.begin("ESP32_BT_Logger", true);
  SerialBT.setPin("1234"); // Secure PIN pair
  SerialBT.println("START");
}

void broadcastSample(unsigned long t, long mg) {
  SerialBT.printf("DATA,%lu,%ld\n", t, mg);
  Serial.printf("%lu,%ld\n", t, mg);
}
MODULE 06 // GROUND STATION

Python Real-Time CSV Data Logger

Ground monitoring script featuring automated COM-port reconnection, safe UTF-8 byte stream decoding, and continuous append logging to scale_data.csv.

import serial, time

ser = serial.Serial("COM9", 9600, timeout=5)
with open("scale_data.csv", "w") as f:
    f.write("Time(ms),Weight(mg)\n")
    while True:
        line = ser.readline().decode("utf-8", errors="ignore").strip()
        if line.startswith("DATA,"):
            data = line.replace("DATA,", "")
            f.write(data + "\n")
            print(f"Logged: {data}")

07 // UI/UX & SYSTEM INTEGRATION

Mobile Operator Interface

Mobile app interface enabling safe remote operation outside vault radiation zones.

Interface Features

[✓]
Technician Authentication: Secure role-based login protocol for operators.
[✓]
Fuel Channel Grid Selection: Spatial reactor core fuel tube channel map.
[✓]
Dual-Orientation Switching: Instant switching between horizontal and vertical profiles.
[✓]
Target Mass Configuration: Configurable setpoint ([ 65 mg ] target within [ 30–80 mg ] spec).
[✓]
Live 4-Stage Lifecycle Tracking: Stage state machine (DeploymentSamplingContainedRetracted).
[✓]
Automated CSV Data Logging: Automatic CSV export for lab testing records.

// STAGE TRACKING LIFECYCLE

01
Deployment: Drive motors / winch navigate tool to target pressure tube zone.
02
Sampling: JGB37-520 actuates lathe bit; HX711 measures mass accumulation.
03
Contained: Container disengages retention lip; internal compression springs automatically seal [ 65 mg ] radioactive sample vessel.
04
Retracted: Winch/tether extracts tool back to channel access breach safely.

08 // POST-MORTEM & FUTURE ROADMAP

01

Root Cause Failure Analysis

High scraping torque during pipe engagement induced motor stalls. Peak stall current spikes exceeded the 3S BMS threshold, tripping overcurrent protection and cutting system power.

02

Custom PCB Design Roadmap

Transitioning from discrete breakout modules and point-to-point breadboard wiring to a unified 2-layer custom PCB with dedicated power planes and high-current traces.

03

Mechanical Safety Integration

Engineering a calibrated shear notch on the lathe bit holder. Under binding torque, the bit holder snaps safely, preventing motor stall current spikes and ensuring smooth recovery via winch failsafe.

09 // COMPLETE BILL OF MATERIALS & HARDWARE STANDARDIZATION

Full prototype component bill of materials breakdown totaling CAD $96.19. We developed this structured naming scheme (e.g., PD for Power Delivery, CL for Control Logic, SC for Structural Components) so the multidisciplinary group could more easily compartmentalize the workload. This allowed team members to clearly describe and reference the specific subsystem they were working on without confusing others with changing model numbers, manufacturer brand names, or vendor codes.

To streamline assembly and rapid prototyping, we actively standardized components wherever possible, utilizing M3 and M4 nuts and bolts exclusively alongside heat-set brass threaded inserts. Through strategic vendor selection and precise sizing, we were able to deliver a fully functional, fully integrated prototype for $96.19—staying under the client's $100 CAD project budget with materials to spare.

Item Code Part Description Vendor Qty Cost (CAD)
// POWER DELIVERY
PD0122 AWG Hookup WireAmazon1$0.80
PD02XT60 Battery ConnectorsAliExpress1$1.60
PD0316 AWG Power WireAmazon1$0.80
PD04Molicel 21700 P42A Li-Ion Cells18650 Battery3$15.00
PD053S 40A BMS BoardAliExpress1$2.94
PD07LM2596 DC-DC Buck ConverterAliExpress1$0.45
// CONTROL LOGIC
CL01ESP32-WROOM-C3 BoardElegoo1$9.99
CL02BTS7960 43A Motor DriverAliExpress1$7.41
CL03HX711 24-Bit ADC ModuleAliExpress1$1.80
// MEASUREMENT
M01100g Micro Load CellAliExpress1$4.93
// STRUCTURAL
SC01PETG / PLA Filament (~0.7kg)Bambu Lab1$16.99
SC02M3 Brass Threaded InsertsAliExpress1$0.80
SC03M3/M4 Fasteners AssortmentAliExpress24$1.00
// TOOLING
ST01MGEHR1212 Lathe Bit & HolderAliExpress1$3.25
ST02JGB37-520 12V 7RPM MotorAliExpress1$11.28
// MOVEMENT
MV01608ZZ Ball BearingsAliExpress8$4.69
MV02N20 12V 200RPM Drive MotorsAliExpress2$10.78
MV03High-Friction Rubber BandsAmazon8$1.68
TOTAL COST: $96.19