iHarmony™ Glucose Lab Presenter guide

Presenter Guide (CGM and insulin pump with automated insulin delivery)

Glucose Lab

A 20-25 minute demo of iHarmony™'s connected-device testing for a medical-device, digital-health or diabetes-tech audience, then a proposed pilot. Every claim below is backed by something that runs on the laptop.

Positioning: the dose decision - suspend, reduce, increase, correct, and why - is software, and software can be tested before it reaches a patient: across patients, meals, exercise, sensor faults and pump faults, on purpose, repeatably, with evidence.

Say early, and mean it: this is a lab for testing device software. The patients are synthetic, the physiology and the algorithm are deliberately simple, and nothing here is clinical advice or a medical algorithm.

0Before the meeting (T-1 day and T-30 min)

scripts\run_device_studio.bat          # the Studio: http://127.0.0.1:8790/  (device group Glucose)
pytest demo/glucose_lab -o addopts= -q     # the glucose lab suite on its own (~15 s): must pass
powershell
  • Open the Studio, set Device group to Glucose, open the Glucose scene. Glucose clock 120x (a day in 12 minutes; one reading every 2.5 seconds).
  • Keep a second tab on the Test Explorer (http://127.0.0.1:8790/explorer, device group Glucose).
  • For the evidence step, run the day test once with evidence on, and keep the folder open: $env:GLUCOSE_LAB_EVIDENCE="reports/glucose_lab"; pytest demo/glucose_lab/test_05_patient_day.py -o addopts= -q
  • Dry-run section 2 once the same day. Before the audience arrives, click Back to normal for each patient you changed.

1Run sheet

MinShowcase pointShowSay
0-2FramingGlucose scene"Three virtual patients with type 1 diabetes - an adult, an adolescent, a child - each wearing a continuous glucose monitor and an insulin pump with automated insulin delivery. All digital twins, over Bluetooth Low Energy."
2-51. The loopa patient card"Every 5 minutes the sensor measures, the reading reaches the pump, and the pump decides - and says why: 'in range', 'high: basal 2.00 U/h', 'predicted low: suspend'."
5-92. A meal, with and without a bolusEat + bolus, then Eat, forget the bolus"With a bolus the rise is small. Forget it, and the loop raises basal and gives automatic corrections - at most one an hour, within a hard limit on insulin on board."
9-123. LowsExercise, the child"Exercise drives glucose down. The pump predicts 30 minutes ahead and suspends insulin before the low, not after."
12-164. FaultsLies on the sensor, Block the infusion line"Lying on the sensor reads 48 while the patient is at 120: the pump trusts the sensor and suspends - a known gap, and a test documents it. A blocked line: nothing reaches the body, pressure builds, the pump stops and alarms."
16-195. Tests and evidenceTest Explorer, then the day test"One-behaviour tests, pass - fail - recover. And a whole day per patient: time in range, no time below 54, and the pump's safety rules checked over every one of its 288 decisions, written as CSV."
19-25Boundary and pilotsection 4Closing statement, then the pilot proposal.

2Glucose scene walkthrough (8-10 minutes)

Start with all three patients in range at 120x. Each card shows the latest CGM reading with its trend arrow, the patient's real blood glucose beside it, the last 6 hours, the pump's mode, basal rate, insulin on board and reservoir, and the pump's last decision with its reason.

StepDoSay
1. OrientPoint at a card"Green is 70-180 mg/dL, amber is outside, red is below 54 or above 250. The small 'real' number is what a lab would measure: the sensor reads tissue fluid, a few minutes behind and with noise."
2. A meal with a bolusPatient Adult, 60 g, Eat + bolus"The pump's calculator: 60 g at 1 unit per 10 g, plus a correction to target, minus what is still on board. The log says exactly that."
3. A forgotten bolusPatient Adolescent, 75 g, Eat, forget the bolus"Glucose climbs. Watch the decisions: 'high: basal ... U/h' (at most double), then above 180 'auto-correction ... U'. One correction an hour at most, never past the insulin-on-board limit."
4. ExercisePatient Child, Exercise 45 min"Glucose falls. 'Trending low: half basal' and, if it keeps falling, 'predicted low: suspend' - before the low, because the pump looks 30 minutes ahead."
5. A false lowPatient Child, Lies on the sensor"The sensor reads 48 for 20 minutes; the patient is fine. The pump suspends and raises an urgent-low alarm. That is the right reaction to the data and the wrong reaction to the patient - which is why a test pins this behaviour down."
6. A blocked linePatient Adult, Block the infusion line"The motor keeps pushing, nothing reaches the body. After about one unit the pressure trips the occlusion alarm and delivery stops." Then Back to normal.

Reset after the demo: Back to normal for each patient you changed.

So nothing surprises you:

  • Right after the Studio starts, give it 10 seconds: the first reading takes a moment, and until the trend has 10 minutes of history the pump predicts from the reading alone.
  • Readings arrive every 5 device minutes (2.5 s at 120x); a decision follows within the next 5 minutes.
  • A blocked line takes about an hour of device time to detect (30 s at 120x): pressure builds slowly at basal rates. That is realistic; say so while you wait, or switch to 600x.
  • The rule order is fixed: lost CGM, low, predicted low, trending low, insulin-on-board limit, correction, high, in range. A low always wins over a high prediction.

3Test Explorer walkthrough (5 minutes)

Device group Glucose: a Glucose monitor and an Insulin pump tab per patient (adult-01, adolescent-01, child-01), with the same cases each.

StepDoSay
1. HealthyRun all tests on the pump"Real pytest tests against a live pump over Bluetooth LE. All pass."
2. SuspendedPump suspended by the user, run "Automated delivery on": FAIL with the mode; Back to normal: PASS"Pass, fail with the reason, recover."
3. AlarmNearly empty reservoir (5 U), run "No pump alarms": FAIL naming the alarm"Alarms are part of the contract a test checks."
4. SensorMonitor tab: Sensor removed (session stopped), run "Sensor session running": FAIL"The CGM speaks the standard Bluetooth CGM service: the same test runs against any sensor that does."

Then show the evidence: reports/glucose_lab/adult-01_decisions.csv (every decision with its reason) and adult-01_summary.json (time in range, lows, corrections, insulin).

4The boundary - say it plainly

These twins test device software and its integrations: the Bluetooth protocols, the pump's decisions and alarms, the faults and the evidence. The patients are synthetic and the physiology is simple - basal need, an insulin-action curve, meals and exercise. The algorithm is illustrative. We are not claiming clinical accuracy, and nothing here is a medical algorithm or dosing advice. Clinical validity is the job of validated simulators and clinical studies; this is how the software around them is tested, every build.

What the twins are, honestly:

TwinModelsDoes not model
Glucose monitorthe Bluetooth SIG CGM service (measurement, status, session run time, ops control point), readings every 5 minutes with trend and warnings, 2-hour warm-up, calibration, battery; sensor faults (signal loss, drift, stuck, noise spikes, compression low)a vendor's proprietary or encrypted protocol, sensor chemistry, E2E-CRC
The patient (inside the CGM twin)basal need, an exponential insulin-action curve, carbohydrate absorption, exercise, about 8 minutes of sensor laghormones, illness, stress, dawn phenomenon, validated physiology (e.g. accepted clinical simulators)
Insulin pumpbasal and bolus delivery, bolus calculator, automated insulin delivery every 5 minutes with its reason, limits (maximum bolus, automatic correction, insulin on board), occlusion, reservoir and battery alarms, power lossthe full Bluetooth Insulin Delivery Service, a commercial algorithm, cartridge mechanics

5Proposed pilot

  1. Pick one device - a CGM, a pump, or the app between them - and the protocol it speaks (standard Bluetooth services or the vendor's own).
  2. Obtain its protocol specification, its requirements (the rules the dose logic must follow) and a set of recorded sessions from a bench.
  3. Swap the generic twin for an adapter to that device (the tests use device objects, so they do not change) and replay the recorded sessions against it.
  4. Write the requirements as tests with traceability (requirement id per test) and run them on every build, in simulation and on a hardware bench.
  5. Agree the evidence a verification report needs (IEC 62304 software verification) and generate it from the runs.

Closing statement

"Today you saw dose decisions tested the way software should be: across patients, meals, exercise, sensor and pump faults, automatically and repeatably, with evidence for every decision. We propose a pilot with one of your devices and its protocol, to show the same tests against your real hardware."

6Likely questions

QuestionAnswer
Is this a Dexcom, Libre or Omnipod?No: generic twins. The CGM speaks the standard Bluetooth CGM service; commercial sensors often use proprietary, encrypted protocols. An adapter for a specific device is pilot scope; the tests do not change.
Is the algorithm real?No: an illustrative rule-based loop, written to be explainable. A pilot tests your algorithm, as the device under test.
Is the physiology validated?No: a simple model for exercising device software. Validated simulators (for example accepted in-silico populations) can drive the same twins.
Real protocols?Bluetooth Low Energy GATT through iHarmony's BLE transport; in simulation the radio is replaced by an in-process link, on a bench by a real adapter.
How fast is it?Simulated time: a whole day per patient runs in a few seconds in a test, 12 minutes in the Studio at 120x.
Regulated development?The suite produces the evidence a verification activity needs: requirement-named tests, every decision logged with its reason, CSV and JSON per run. The process (IEC 62304, ISO 14971) stays yours.

7Glossary

TermMeaning
CGMContinuous glucose monitor: a sensor under the skin that reads glucose every few minutes.
mg/dLMilligrams per decilitre, the glucose unit used here (divide by 18 for mmol/L).
Time in rangeShare of readings between 70 and 180 mg/dL.
BasalBackground insulin, delivered continuously (units per hour).
BolusA dose for a meal or a correction.
Insulin on board (IOB)Insulin delivered but not yet acting; here net of the programmed basal, so negative while basal is reduced.
ISFInsulin sensitivity factor: mg/dL one unit lowers glucose.
Carb ratioGrams of carbohydrate one unit covers.
Automated insulin delivery (AID)A pump that adjusts insulin from CGM readings by itself (a "closed loop").
OcclusionA blocked infusion line: insulin cannot reach the body.
Compression lowA false low reading caused by pressure on the sensor, often while sleeping.
SFLOATThe 16-bit number format of the Bluetooth glucose services.