Project tutorial
Heatblock for COVID-19 Testing

Heatblock for COVID-19 Testing © MIT

A flexible, extensible platform for COVID-19 testing - quick and easy detection and tracing in the developing world using CRISPR tests.

  • 2,244 views
  • 1 comment
  • 2 respects

Components and supplies

Screenshot 2019 06 14 15 28 58 udl6wzcwho
Arduino Nano Every
Can be any Arduino, or a custom PC board.
×1
SparkFun LED RGB - Generic
×2
SparkFun SPST mini pushbutton
Any SPST pushbutton will do
×2
TDK Corporation NTC Themistor
10K at 25C
×2
Delete me piezo speaker
Any generic piezo speaker
×1
ICStation Heater strip
×2
Power supply 12V 2A
Optional generic 12V power supply (can just run from a car battery instead...)
×1
Custom enclosure
Literally any enclosure - the submission uses a custom 3D printed enclosure (with .STL file provided), but a sardine can would do.
×1
Heater controllers
LED controllers were used in the submission (because they are cheap), but all that is needed is a simple MOSFET if a custom board is being created.
×1

Necessary tools and machines

3drag
3D Printer (generic)
09507 01
Soldering iron (generic)
70y8518 40
Drill / Driver, Cordless

Apps and online services

About this project

Epidemiologists tell us that ubiquitous testing is the key to detecting and containing pandemic outbreaks, such as COVID-19. The next generation of cheap, accurate tests are built around CRISPR ( and also), with the use of isothermal amplification.

Testing is hard enough in the developed world, where medical facilities are well stocked and well staffed. The developing world needs a more flexible solution - one that can adapt to the constrained resources of a remote setting while providing life saving test information to the larger data effort.

This project focuses on the needs in that remote setting:

  • Provide the fundamental piece of equipment (an accurate heatblock) to quickly and accurately detect the presence of COVID-19 (or any other) virus using CRISPR point of care diagnostics
  • Be able to operate "off the grid", while storing results for eventual integration with the bigger picture when communication is available
  • No reliance on refrigeration, the availability of AC power, cellular connectivity, or sanitary conditions
  • Reliable, fault-free operation - as far as possible, make it impossible to use the platform incorrectly or misread test results.
  • Accommodate a range of viral test devices, that may have differing test requirements
  • Adaptable to test for "the next" pathogen - useful in pandemics to come

The CRISPR diagnostics depend on two separate reactions that occur at separate elevated temperatures. First an isothermal amplification reaction takes about 20 minutes to amplify cDNA from COVID-19, if it is present in the sample. Then a CRISPR reaction cleaves the amplified DNA and signals presence of COVID with a stripe on a paper strip (lateral flow device). Each reaction requires a separate, steady temperature for the test to be accurate.

The device consists of two aluminum heatblocks, one for each reaction, with polyimide heaters. The temperature of the heatblocks is sensed by thermistors, and an inexpensive Arduino computer controls the heaters to be sure the blocks stay at the needed temperatures. There are colored LEDs that indicate when the heatblocks are in the right temperature range, and timers that can be used to time the amplification and CRISPR reactions. All of this runs off any 12VDC supply that can deliver at least 2A (wall bug, car battery, lantern batery, solar panel...).

The device is designed to be foolproof. Once plugged in, it heats the heatblocks, the LEDs indicating when the right temperatures are achieved. The LEDs blink "blue" until the blocks are at temperature, then the LEDs turn "green". If the blocks should go over temperature, the LEDs turn red. There are pushbuttons that activate audible timers for each of the reactions. For the uploaded code, the timers and temperatures are set as described for the SHERLOCK Covid-19 tests (https://www.broadinstitute.org/files/publications/special/COVID-19%20detection%20(updated).pdf)

The physical configuration of the device can be easily changed to accommodate different diagnostic requirements. The submitted example has holes shaped to accept standard laboratory reaction tubes. The blocks were created using ordinary hand tools (saw, drill), and the configuration might be different - the basic design is the same. Similarly, different CRISPR diagnostic protocols may require different temperature settings, and these can all be easily changed by editing the included Arduino program and reloading the program in the Arduino. The Arduino runs two precision PID control loops to guarantee that the chosen temperatures are achieved and maintained.

Here are the results achieved with the given heatblocks and the uploaded Arduino code:

Building the Device

Building the device starts with creating the actual blocks that will be heated. For the demo device, I used hand tools and aluminum bar stock to create blocks suitable for use with standard.5ml centrifuge tubes. These fit a wide range of tests, but one could also create heatblocks suited for lateral flow (paper) tests, and they might need a different geometry. These blocks have small holes drilled to accept the thermistors that measure their temperature.

Once the heatblocks are made, the heater strips can be added. These are very inexpensive polyimide resistance heaters, readily available on Amazon or eBay. They are adhesive backed, and can simply be wrapped around the heatblocks:

With the heaters attached, the thermistors can be inserted and secured, and the heatblocks are ready to use:

The only other custom part of the design is the case. We created a custom 3D printed case (STL file attached), but really anything could be used, as long as it provides room for the components and access for the heatblocks and the 12V jack.

The rest of the parts are all standard electronic components. To keep costs down, MOSFET controllers intended to control LED light strings are used to control the heaters. The heaters draw 1A, which is well within the power range of the MOSFETs.

There is nothing special about the rest of the assembly. The parts are wired together as shown on the schematic and assembled into the custom enclosure.

Operation

In normal use only the 12V power jack is used - the Arduino USB jack is only used to reprogram the Arduino, should it be necessary to change the heatblock temperatures or the timer durations. When the unit it connected to 12V, the two LEDs start to blink blue - indicating that the heatblocks are currently below their target temperatures. The blink rate of the LEDs is proportional to how close the temperature is to the setpoint - shorter "off" times as the setpoint is approached. When the temperature gets within 4 degrees of the setpoint for a block, the related LED turns solid green. It will stay green as long as the block stays within 4 degrees of the setpoint. Should the temperature drift more than 4 degrees above the setpoint, the related LED will blink red. As shown in the graph above, the demo unit comes to temperature in about 5 minutes, and reliably stays there. The heaters are controlled with precision PID control loops implemented in the Arduino, which assure steady temperatures.

A user would place a test reaction first in the RT-LAMP block, and then press the associated timer pushbutton. The speaker starts beeping once a second, and when the timer is up, is gives one long beep. Similarly, after the RT-LAMP reaction is complete, the user moves the reaction to the CRISPR block and pushed that pushbutton to restart the timer. Again the timer beeps once a second, and when done, gives a long beep (with a tone different from that of the RT-LAMP timer).

Once both reactions are finished, the results can be read. This varies with the specific test, but is usually a set of lines on a lateral flow device (paper strip like a home pregnancy test). The published protocols require about an hour for a test from start to finish.

The submitted device is a crucial piece of equpment to enable very quick, accurate, inexpensive testing for Covid-19 and other viruses, using the CRISPR based diagnostic tests. The device is flexible enough to use with a variety of test protocols, accurate enough to give reliable results, and simple enough to be made quickly and cheaply for use anywhere in the world.

Code

Covid-19 Precision Heatblock for CRISPR Diagnostic TestingArduino
Arduino code to implement a precision dual heatblock for use with CRISPR based Covid-19 point of care tests.
// Heatblock sketch
// 
// Used to heat and hold temperature of two custom heatblocks.
// Temperatures are set as TempRT and TempCR.
// Timer values are TimeRT and TimeCR

// Author: Rick Rogers
// 
//Copyright (c) 2020 Rick Rogers
//
//Permission is hereby granted, free of charge, to any person obtaining a copy
//of this software and associated documentation files (the "Software"), to deal
//in the Software without restriction, including without limitation the rights
//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
//copies of the Software, and to permit persons to whom the Software is
//furnished to do so, subject to the following conditions:
//
//The above copyright notice and this permission notice shall be included in all
//copies or substantial portions of the Software.
//
//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
//IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
//FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
//AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
//LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
//OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
//SOFTWARE.


#include <PID_v1.h>
#include <NTC_Thermistor.h>
#include <Thermistor.h>
#include <SmoothThermistor.h>
#include <jled.h>



// pin assignments
#define HeatRTpin 9 // heater for RT block (thru MOSFET)
#define HeatCRpin 10 // heater for CRISPR block (thru MOSFET)

#define RedRTpin 14 // Red LED for RT
#define GrnRTpin 8  // Green LED for RT
#define BluRTpin 7  // Blue LED for RT

#define RedCRpin 15  // Red LED for CRISPR
#define GrnCRpin 6  // Green LED for CRISPR
#define BluCRpin 5  // Blue LED for CRISPR

#define TempRTpin A3  // Temperature of RT
#define TempCRpin A4  // Temperature of CRISPR
#define tempScale 1 // Temperature scaling - temp to analog value

#define SwTimerRTpin 19 // Timer pushbutton for RT
#define SwTimerCRpin 20 // Timer pushbutton for CRISPR

#define SPKRpin 21 // Piezo speaker

// PID variables
double TempSPRT = 37.0; // Setpoint temperature for RT-LAMP reaction in degrees C
double TempSPCR = 42.0; // Setpoint temperature for CRISPR reaction om degrees C
double TempRT, TempCR, OutRT, OutCR;

// Timer constants
long TimeRTDur = 60*25; // seconds - RT timer duration
long TimeCRDur = 60*30; // seconds - CRISPR timer duration
bool TimeRTRun = false;
bool TimeCRRun = false;
long TimeRTBase;
long TimeCRBase;

// Initialize PID controllers
double Kp = 10.0;
double Ki = 0.25;
double Kd = 0;
PID RTPID(&TempRT, &OutRT, &TempSPRT, Kp,Ki,Kd, DIRECT);
PID CRPID(&TempCR, &OutCR, &TempSPCR, Kp,Ki,Kd, DIRECT);

// Initialize thermistor inputs
Thermistor* thermistorRT = new SmoothThermistor(
  new NTC_Thermistor(
    TempRTpin, 10000, 10000, 25.0, 3988), 5);
Thermistor* thermistorCR = new SmoothThermistor(
  new NTC_Thermistor(
    TempCRpin, 10000, 10000, 25.0, 3988), 5);

JLed LedRedRT = JLed(RedRTpin).Off();
JLed LedRedCR = JLed(RedCRpin).Off();
JLed LedBlueRT = JLed(BluRTpin).On();
JLed LedBlueCR = JLed(BluCRpin).On();
JLed LedGreenRT = JLed(GrnRTpin).Off();
JLed LedGreenCR = JLed(GrnCRpin).Off();

void setup() {
  Serial.begin(9600); // open the serial port at 9600 bps:
  
  // setup pin uses
  pinMode(HeatRTpin, OUTPUT);
  pinMode(HeatCRpin, OUTPUT);
  pinMode(RedRTpin, OUTPUT);
 // pinMode(GrnRTpin, OUTPUT);
 // pinMode(BluRTpin, OUTPUT);
  pinMode(RedCRpin, OUTPUT);
  //pinMode(GrnCRpin, OUTPUT);
  //pinMode(BluCRpin, OUTPUT);
  pinMode(SwTimerRTpin, INPUT_PULLUP);
  pinMode(SwTimerCRpin, INPUT_PULLUP);
  pinMode(SPKRpin, OUTPUT);

  // Start the PID loops
  TempRT = analogRead(TempRTpin);
  TempCR = analogRead(TempCRpin);

  RTPID.SetMode(AUTOMATIC);
  CRPID.SetMode(AUTOMATIC);

  TimeCRBase = millis()/1000.0;
  Serial.print("Kp="); Serial.print(Kp);
  Serial.print(" Ki="); Serial.print(Ki);
  Serial.print(" Kd="); Serial.print(Kd);
  Serial.print(" TempScale="); Serial.println(tempScale);
  Serial.println("Sec,TempRT,TempCR,OutRT,OutCR");

}

void loop() {
  // PID loops
  TempRT = thermistorRT->readCelsius();
  TempCR = thermistorCR->readCelsius();
  if (millis()%1000 < 3){
    Serial.print(millis()/1000 - TimeCRBase);
    Serial.print(",");
    Serial.print(TempRT);
    Serial.print(",");
    Serial.print(TempCR);
    Serial.print(",");
    Serial.print(OutRT);
    Serial.print(",");
    Serial.println(OutCR);
  }
  
  if (millis()%5000 < 3){
    // Once every 5 seconds, reset LED blink rates
    SetLEDColor(LedRedRT, LedBlueRT, LedGreenRT, TempRT, TempSPRT, 25.0);
    SetLEDColor(LedRedCR, LedBlueCR, LedGreenCR, TempCR, TempSPCR, 25.0);
  }
  // Update LEDs
  LedRedRT.Update();
  LedBlueRT.Update();
  LedGreenRT.Update();
  LedRedCR.Update();
  LedBlueCR.Update();
  LedGreenCR.Update();

  // Update PID loops
  CRPID.Compute();
  RTPID.Compute();
  analogWrite(HeatRTpin, (int)OutRT/tempScale);
  analogWrite(HeatCRpin, (int)OutCR/tempScale);

  
  // Timers
  // If a timer is running, increment time and see if time's up
  if (TimeRTRun) {
    // RT timer is running
    // Tick once a second
    if (millis()%1000 < 5){
      tone(SPKRpin, 500,50);
    }
    float TimeRTVal = millis()/1000.0;
    if (TimeRTVal > TimeRTBase+TimeRTDur) {
      // Time's up - sound beeper and clear timer
      tone(SPKRpin, 1000, 2000);
      TimeRTRun = false;
    }
  } else {
    // RT timer is not running - see if user wants to start
    if (!digitalRead(SwTimerRTpin)) {
      TimeRTRun = true;
      TimeRTBase = millis()/1000.0;
    }  
  }
  
  if (TimeCRRun) {
    // Tick once a second
    // CR Timer is running
    if (millis()%1000 < 5){
      tone(SPKRpin, 500,50);
    }
    float TimeCRVal = millis()/1000.0;
    if (TimeCRVal > TimeCRBase+TimeCRDur) {
      // Time's up - sound beeper and clear timer
      tone(SPKRpin, 500, 2000);
      TimeCRRun = false;
    }
  } else {
    // CR timer is not running - see if user wants to start
    if (!digitalRead(SwTimerCRpin)) {
      TimeCRRun = true;
      TimeCRBase = millis()/1000.0;
    }  
  }

}

void SetLEDColor(JLed &LedRed, JLed &LedBlue, JLed &LedGreen, double Temp, double TempSP, double TempRoom){
  double TempDiff = TempSP - Temp;
  if (abs(TempDiff) < double(4.0)){
    LedGreen.On();
    LedRed.Off();
    LedBlue.Off();
  }
  if (TempDiff > double(4.0)){
    LedBlue.Blink(500,500*(TempSP-Temp)/(TempSP-TempRoom)).Forever();
    LedRed.Off();
    LedGreen.Off();
  }
  if (TempDiff < double (-4.0)){
    LedRed.Blink(500,500*(TempSP-Temp)/(TempSP-TempRoom)).Forever();
    LedBlue.Off();
    LedGreen.Off();
  }
  LedRed.Update();
  LedBlue.Update();
  LedGreen.Update();
}

Custom parts and enclosures

Covid-19 Precision Heatblock for CRISPR Diagnostic Testing
An STL file for a custom enclosure for a dual precision heatblock. The enclosure can be 3D printed, and provides mounting for an Arduino Nano and power MOSFET controllers. It also has appropriate openings for a 12V power connector and the Arduino microUSB.
Lid for Heatblock Custom Enclosure
An STL file for a lid for the custom enclosure that includes holes for heatblocks, LEDs, switches and a piezo speaker.
Faceplate Artwork for Covid-19 Precision Heatblock
An SVG file (created with Affinity Designer) for the faceplate of the heatblock. It includes appropriate labels and a guide to the meaning of the LED colors. In practice it would be easy to change languages, for example, or change the layout for heatblocks with a different geometry.
Crispr0703 eib2bgvzwv
Faceplate Artwork as Affinity Designer file
Same as the other faceplate file, but the Affinity Designer version, for easier editing.
crispr0703_AW2fRr6RQl.afdesign

Schematics

Covid-19 Precision Heatblock for CRISPR Diagnostic Testing
A Fritzing dataset that implements an Arduino based dual precision heatblock for developing countries. Only the schematic portion of the dataset is valid - the breadboard and PC sections should not be used.
heatblock0703_JXACgdh1us.fzz

Comments

Similar projects you might like

COVID-19 and PM10 Levels!

Project tutorial by Mario Soranno

  • 1,796 views
  • 2 comments
  • 5 respects

Open Source Pulse Oximeter for COVID-19

Project tutorial by Arduino “having11” Guy

  • 33,823 views
  • 18 comments
  • 98 respects

Open-Source COVID-19 Pulmonary Ventilator

Project tutorial by David Pascoal

  • 4,576 views
  • 19 comments
  • 142 respects

Connected Oximeter with SMS Alert for Covid-19

Project tutorial by Martin Cornu

  • 2,329 views
  • 0 comments
  • 7 respects

COVID-19 Detector: The Need of the Crisis

Project tutorial by Raunak Singh

  • 3,609 views
  • 9 comments
  • 10 respects

Portable CoVID-19 clinic

Project tutorial by Guntas Singh

  • 1,239 views
  • 5 comments
  • 31 respects
Add projectSign up / Login