README.md 20.1 KB
Newer Older
Tom's avatar
Tom committed
1
2
3
4
# Context

As India begins a protracted battle against coronavirus, one of the key issues identified is that the global supply of ventilators and spares have depleted. India, like many other countries, could face a severe shortage of the respiratory devices

Yadu sharon's avatar
Yadu sharon committed
5
At present, ventilators are mainly imported, assembled in India or partially produced here. India does not have a single indigenously manufactured ventilator as the companies that produce ventilators import some or many of their components. Although demand from the government machinery has gone up, the industry is not equipped to meet the requirement.
Tom's avatar
Tom committed
6
7


Tom's avatar
Tom committed
8
## [COVID-19 Disease Progression](https://git.fablabkerala.in/pub/projects/respiratory-apparatus/blob/master/COVID-19_Disease_Progression.md)
Tom's avatar
Tom committed
9
10
11
12
13
14
15
16
17
18
19
20
21
22


# Breath of Hope

Breath of Hope is a volunteer group building solutions with the objective of solving the potential shortage of emergency medical supplies across India. The group, supported by Kerala Startup Mission and the Super Fablab at Kochi,  has social workers, doctors and engineers from different areas of expertise. One of the key projects this group is working on is to design a machine which can act as a respiratory assistant for COVID-19 patients who have trouble breathing.


## Objective

As per a report published by ICMR half of the patients at Critical Stage will need to be intubated and given mandatory ventilation, without which they cannot survive. The objective of the project is to **_design and manufacture low cost machines which can help patients with respiratory distress to continue breathing_**. The medical staff can control the volume of air and rate of breath provided by this machine to the patient. This device can also be used by patients who are in the early stages of ARDS so that their condition does not deteriorate due to lack of air supply to their lungs.

Note: This machine is not a replacement for ventilators and is intended for use only in the case of a shortage of ventilators to treat people suffering from respiratory failure due to COVID-19


Tom's avatar
Tom committed
23
## [Brief on Ventilators](https://git.fablabkerala.in/pub/projects/respiratory-apparatus/blob/master/Brief_on_Ventilators.md)
Tom's avatar
Tom committed
24
25
26
27
28
29
30
31



## Design Considerations


### Purpose

Yadu sharon's avatar
Yadu sharon committed
32
Breaths are classified as spontaneous or mandatory based on both the trigger and cycle events. A spontaneous breath is a breath for which the patient both triggers and cycles the breath. A spontaneous breath may be assisted or unassisted. A mandatory breath is a breath for which the machine triggers and/or cycles the breath. A mandatory breath is, by definition, assisted. A breath sequence is a particular pattern of spontaneous and/or mandatory breaths. The 3 possible breath sequences are:
Tom's avatar
Tom committed
33
34
35
36
37
38
39



*   Continuous Mandatory Ventilation or CMV: patients makes no effort to breath and all breaths are mandatorily provided by the machine
*   Intermittent Mandatory Ventilation or IMV: patient may take spontaneous breaths in between mandatory breaths
*   Continuous Spontaneous Ventilation or CSV: all breaths are spontaneous, i.e, initiated by the patient.

Tom's avatar
Tom committed
40
41
42

The use of high-flow nasal oxygenation and mask CPAP or BiPAP should be avoided due to greater risk of aerosol generation.

Tom's avatar
Tom committed
43
44
45
46
47
48
49
50
51
52
53
The purpose of the machine is to primarily provide CSV for COVID-19 patients who have milder respiratory issues. If a shortage arises for the normal ventilators, this machine can be used to provide CMV for patients with severe respiratory distress.


### Constraints

India’s efforts to shore up manufacturing of ventilators to deal with the rapid spread of Covid-19 infections has suffered due to the absence of a local electronics components industry. The ban on international flights has made the issue worse, with manufacturers struggling to lift sensors, chips and controllers from suppliers in China. With the recent country-wide lockdown, moving material within the country is also challenging. Given the situations the following constraints have been factored into the design of the RespiratorApparatus



*   Material: Easy availability of all components and material locally
*   Prototyping: Design which can be prototyped in any Fab Lab across the world
Yadu sharon's avatar
Yadu sharon committed
54
*   Manufacturing: Simplified processes for manufacturing at scale
Tom's avatar
Tom committed
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69


### Technical Requirements

Medical staff who are treating COVID-19 patients who need ventilator support will need to adjust the following parameters:



*   **Tidal Volume (Vt)**: Volume of gas exchanged with each breath. A lower Vt is indicated in patients with stiff, non-compliant lungs. Higher Vt may cause tachycardia, decreased blood pressure and lung injury. Vt is calculated as 6-8 mL/kg of ideal body weight (IBW) to prevent barotrauma.
*   **Respiratory Rate (RR)** or Breaths per Minute (BPM): Set number of ventilator breaths per minute. Actual RR includes the spontaneous breaths taken by the patient. Hypoventilation may cause respiratory acidosis; hyperventilation may cause respiratory alkalosis.
*   **Positive End Expiratory Pressure (PEEP)**: Pressure remaining in the lungs at end expiration. Used to keep alveoli open and “recruit” more alveoli to improve oxygenation for patients. High levels may cause barotrauma, increased intracranial pressure and decreased cardiac output. Low levels may cause the lung to collapse.


### Approach

Yadu sharon's avatar
Yadu sharon committed
70
In this situation, the quickest solution, and the most widely used solution is to create a RespiratorApparatus which can automate BVMs (Bag-Valve-Mask). A Bag Valve Mask (BVM), sometimes known by the proprietary name Ambu bag or generically as a manual resuscitator or "self-inflating bag", is a hand-held device commonly used to provide positive pressure ventilation to patients who are not breathing or not breathing adequately. The device is a required part of resuscitation kits for trained professionals in out-of-hospital settings (such as ambulance crews) and is also frequently used in hospitals as part of standard equipment found on a crash cart, in emergency rooms or other critical care settings.
Tom's avatar
Tom committed
71

Yadu sharon's avatar
Yadu sharon committed
72
While it is possible to use this bag manually only for short periods on patients who need respiratory support, the RespiratorApparatus automates the use of the bag for respiratory support for longer durations. Unlike manual pumping of BVMs by paramedical staff, electronic circuits and software in the RespiratorApparatus also allow precise control of the pressing so that the doctors can set the Tidal Volume and Respiration Rate (Breaths per Minute) as per the condition of the patient.
Tom's avatar
Tom committed
73
74
75
76
77
78

Ambu Bags or BVMs come with PEEP valve connectors, for maintaining the positive airway pressure maintenance and a pressure relief valve (often known as a "pop-up valve"), the purpose of which is to prevent accidental over-pressurization of the lungs. These safety features make use of Ambu Bags ideal for the current scenario faced by the country today.


### Project Status

Yadu sharon's avatar
Yadu sharon committed
79
The working prototype is ready after preliminary tests with a test lung. The current features include the ability to control the Tidal Volume, Breaths per Minute and PEEP.
Tom's avatar
Tom committed
80

Yadu sharon's avatar
Yadu sharon committed
81
The team is currently converting the design into a manufacturable version that can be taken to production by industries.
Tom's avatar
Tom committed
82
83


Tom's avatar
Tom committed
84
85
86
87
88
89

# Solution


## Mechanical Design

90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
#### Common problems assosiated with Ambu Bag Automation devices

**1. Life of Ambu bag (BVM)**

- Bag Valve masks are designed to be used for a short time like in an emergency or when moving the patient. They are not designed for continous operation over long periods. We might get a few hundred thousand cycles of operation before it fails completely. The average time of a pateient in the hospital is about 14 days, of that he amy need ventilation for about 7-10 days. A 20bpm rate equals 1,200 cycles an hour and 28,800 cycles a day.
    
*Possible Solution* - Using good quality bags, and stress releiving all the hoses in the breathing circuit can help increase the life of the bag. The machine should also not put too much pressure on one part of the bag.
    
**2. Mechanism of Actuation**

- Many creative designs for actuating Ambu bags have come up lately, a few ground principles are, use mechanisms and materials that are simple and robust. If we are really trusting the health of a patient using the device, we don't want our Hobby servo's to fail or our Rasberry Pi's freezing. A minimalist approach, means less things to break. Keep in mind the million of cycles it has to work continously.
- Ventilation is not a fixed state, the parameters of opeartion need to be continously adjusted, so strict CAM based mechanism with only one setting cannot be used in a live setting. The compression of the Ambu bag must be controlled, both position and velocity.
- Steppers make for excellet open loop controls, but care must be taken so that acompaniying electronics are robust and can survive the continous use.
- Mechanisms with lots of moving components are troublesome as, it is only as strong as the weakest link.
    
*Possible Solution* - Using industrial grade components that are rated for continous operation are a good starting point. In our mechanism, we choose a Car wiper motor, as they are simple and rated for 3-5 million cycles of operation, but there is a problem that it is not backdrivable.
    
**3. Dead space in the Breathing circuit**

- All BVM based designs suffer from a common problem, their limited Tidal volumes,they are designed to be used at or near the patients mouth, if we connect an Ambu bag based machine with a long tube to the patient, there is a serious problem called 'Dead space' in which the patient breaths in the same air that was expelled, for a 1m tube, this might be as big as 300ml. 

*Possible Solution* -One way to solve it is to keep exhaust valve as close to patient as possible. Another way is to use a dual limb ciruit made out of two **'Y-connectors'** the Y- connectors have one way valves in them. this means the BVM constantly delivers air to the patient using one tube and the exhaust tube is fed via another Y-connetor to the 'Peep' valve.

**4. Measuring Pressure in the breathing circuit**
- There is host of ventilator induced injury of which Barotrauma is a main concern, we cannot raisethe pressure in the sytem beyond a certain value, most comonly 40CmH20. Provisions must be made to measure the pressure and to ensure that the system does not over pressure the lung.
- To main pressures, we need ot measure and display are, Peak inspiratory pressure and Plateau pressure.
- Peak inspiratory pressure is the max pressure reached in the inspiration cycle. Plateau pressure is the pressure in the circuit when the inspiration has finished. They both are vital sources of information indicating the state of the patient.

**5. Filtration of exhaust**

- Due to the contagious nature of COVID 19, filtration of the breathing circuit and exhaust is highly recomended. Using a HEPA filter near to the patient is recomended to keep the system and exhaust free from containation.
    

Rahul's avatar
Rahul committed
123
**Note 1-** We have seen some designs online, which have wide plates and compress the Ambu Bag fully. From our testing, we found that this may not be the best approach. The Ambu bag has a cylindrical middle section where the bag can be depressed. There are two ring like structures which holds the bag's shape and help it return to bak to the original position. When the whole bagis compressed, the ring structures wil get fatigued and the bag will fail to return to its original shape, this is prominent at higher bredths per minutes, and tidal volumes.
Rahul's avatar
Rahul committed
124
125
126

Hence we opted to model our mechanism after the human hand, with the thumb being the arm that the machine moves. The bag is supported in a convex shape by the base structure. Though this does create two concentration points on the bag, we believe this will be a better approach for the life of the bag.

Rahul's avatar
Rahul committed
127
128


Rahul S Rajan's avatar
Rahul S Rajan committed
129
### Version 3 with Clamp type Arm, DC WormGear Motor, feedback sensors and enclosure
Tom's avatar
Tom committed
130
131


Rahul S Rajan's avatar
Rahul S Rajan committed
132
###
Tom's avatar
Tom committed
133
134


Rahul S Rajan's avatar
Rahul S Rajan committed
135
![](Images/v3.png )
Tom's avatar
Tom committed
136
137
138



Yadu sharon's avatar
Yadu sharon committed
139
###
Tom's avatar
Tom committed
140
141


Rahul S Rajan's avatar
Rahul S Rajan committed
142
143
144
145
146
147
148
![](Images/v31.png )

###


![](Images/v32.png )

Tom's avatar
Tom committed
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171



### Design considerations



*   The use of an optical encoder as a deedback device is explored as they are more reliable than Mechanical encoders.
*   The encoder disc is made from laser cut 3mm Acrylic sheets and attached to the arm.
*   Al limit switch is provided at the end of the arm to set the home position which can be replaced by an optical limit switch later .
*   The enclosure is designed in a minimal way to make the unit compact and to make room for all the electronics.
*   The side walls of the enclosure support the Ambu Bag and makes it easy to remove and replace bags in use.
*   The user interface must be easy to use, and quickly accessible. Safety switch is also provided in case the arm needs to be moved back to remove the bag in an emergency.
*   The interface consists of an LCD with a rotary selector switch to set the Tidal volume, Breath rate etc.
*   The machine operates on 12V and is controlled by a general purpose Arduino Mega board.


### Test Build





Yadu sharon's avatar
Yadu sharon committed
172
173
174
<!--![alt_text](Images/Copy-of2.png)--> <br>
<img src ="Images/Copy-of2.png" width ="500">
<br>
Tom's avatar
Tom committed
175

Yadu sharon's avatar
Yadu sharon committed
176
177
178
<br>
<img src ="Images/DSC_0949.png" width ="500">
<br>
Tom's avatar
Tom committed
179

Yadu sharon's avatar
Yadu sharon committed
180
<!--[alt_text](Images/Copy-of3.png "image_tooltip") -->
Tom's avatar
Tom committed
181
182
183


The body is made by laser cutting 6mm Acrylic sheets press-fit together to make the structure. The knob for adjusting the menu selection is made by 3D printing. The Mechanical assembly of moving the arm and motor is fitted inside the enclosure to provide a clean working machine.
184
185
<br>
[Here is the link to working video](https://twitter.com/Fablab_Kerala/status/1244627769163538433)
Tom's avatar
Tom committed
186
187
188
189
190
191
192
193
194
195

### Learnings



*   The design is a viable option, the tidal volume of the bag can be controlled using the position of the arm and the setting can be changed using the rotary selector and LCD display.
*   The use of an incremental encoder has advantages and disadvantages, it is reliable but the resolution is limited as we can achieve a maximum of 30 points for the range of motion of the arm, this makes the control algorithm difficult.
*   A limit switch is provided as a safety feature as well as a reference point, since we are using an incremental encoder, there is no absolute position of the arm.
*   The enclosure provides some stability to the Ambu bag and helps in keeping all the electronics contained within the machine.

Yadu sharon's avatar
Yadu sharon committed
196
## Electronics design
Tom's avatar
Tom committed
197
198
199
200
201
202
203
204
205
206
207
208
209
210

**Design Constraints**



*   The design should be very simple.
*   It should be easy to replicate .
*   Components should be locally available .
*   It should be reliable and capable of working for long time.
*   Everything should be electronically adjustable.
*   The device should be a stand alone device .

Based on the above constraints we have figured out some mechanism .

Yadu sharon's avatar
Yadu sharon committed
211
**Actuation options available**
Tom's avatar
Tom committed
212
213


Yadu sharon's avatar
Yadu sharon committed
214
215
* **Pneumatic supply and solenoid valves**
   * Opportunities
Tom's avatar
Tom committed
216
217
218
        *   Easy to implement, small number of moving parts.
        *   Reliable and proven technologies.
        *   Suitable if compressed air supply is available.
Yadu sharon's avatar
Yadu sharon committed
219
    * Challenges
Tom's avatar
Tom committed
220
221
222
223
224
        *   Size of the machine will increase.
        *   Compressed air required  .
    *   Decision made
        *   Difficult to implement as a stand alone device (difficult to source small pneumatic pumps/actuators.
        *   Decided to try later after completing a stand alone ventilator.
Yadu sharon's avatar
Yadu sharon committed
225
226
* **Stepper motor with homing switch**
    * Opportunities
Tom's avatar
Tom committed
227
228
        *   Steppers could be controlled in an open loop(No position feedback required).
        *   Easy to control velocity and position.
Yadu sharon's avatar
Yadu sharon committed
229
230
231
232
233
234
    * Challenges
        * If the torque exceed holding torque chances of missed steps are high  
        * Additional torque multiplication mechanisms are required  
        * Can’t ensure the availability of motors and drivers for mass production
        * Higher torque motors are costly and difficult to source.
    * Decision made
Tom's avatar
Tom committed
235
236
        *   We tried two designs with stepper motors one of them was successful.
        *   While considered the  foam factor, torque to weight ratio and complexity of mechanical structure required - we considered it as a second choice.
Yadu sharon's avatar
Yadu sharon committed
237
* **Stepper with feedback and homing**
Yadu sharon's avatar
Yadu sharon committed
238
    *   Opportunities
Tom's avatar
Tom committed
239
240
241
        *   To avoid missing steps, we can use an encoder along with the stepper.
    *    Challenges
        *   Cost and complexity increases.
Yadu sharon's avatar
Yadu sharon committed
242
* **DC motor with potentiometer feedback (DC Servo)**
Yadu sharon's avatar
Yadu sharon committed
243
    *   Opportunities
Tom's avatar
Tom committed
244
245
246
        *   Absolute position feedback of the arm at all points.
        *   Easy to implement and control.
        *   DC geared motors have sufficient torque and low cost.
Yadu sharon's avatar
Yadu sharon committed
247
248
249
250
251
252
    * Challenges
        * Due to continuous operations over a small range of motion, potentiometers may get damaged.
    * Decision made
        * Completed a prototype but later moved on due to the potentiometer issue
* **Worm gear DC motor with incremental encoder and homing switch**
    * Opportunities
Tom's avatar
Tom committed
253
254
        *   Can replace the potentiometer with an optical limit switch and a laser cut encoder disk and an extra optical limit switch for homing.
        *   optical limit switches are cheap and encoder disks could be laser cut easily
Yadu sharon's avatar
Yadu sharon committed
255
256
257
258
259
    * Challenges
        * Incremental encoders are relative and cannot give exact location.
        * Problems when the motor is loaded and the position is in between optical disks
    * Decision made
        * A limit switch with incremental encoder has been tried successfully, with some room for improvement that can be explored further.
Tom's avatar
Tom committed
260
261
262
263
264





Yadu sharon's avatar
Yadu sharon committed
265
![](Images/Copy-of4.png "")
Tom's avatar
Tom committed
266
267
268
269


Block Diagram

Yadu sharon's avatar
Yadu sharon committed
270
## Software design
Tom's avatar
Tom committed
271
272
273
274
275
276
277

**Requirements**



*   Accurate control of angle and angular velocity of the arm
*   The software should dynamically control the torque to match the velocity .
Yadu sharon's avatar
Yadu sharon committed
278
*   An LCD user interface for controlling parameters
Tom's avatar
Tom committed
279
280
281
282
283
284
285
286
287
288
289
290
*   The program should update the values from the user interface to the motor control algorithm

**Inputs to the controller**



*   Motor control
    *   A limit switch (optical prefered) for homing the motor.
    *   An optical encoder for measuring position increment of the arm.
*   User interface
    *   An emergency stop switch for the arm to access the ambu bag in case of an emergency.
    *   A rotary encoder to incense or decrease control parameters.
Yadu sharon's avatar
Yadu sharon committed
291
    *   Rotary encoder switch for selecting  between options.
Tom's avatar
Tom committed
292
293
294
295
296

**Output from the controller**



Yadu sharon's avatar
Yadu sharon committed
297
298
*   Motor control
    * Control outputs to the motor driver
Tom's avatar
Tom committed
299
300
301
302
        *   Motor terminal 1 direction(0 or 1)
        *   Motor terminal 2 direction(0 or 1)
        *   PWM signal to control motor speed
*   User interface
Yadu sharon's avatar
Yadu sharon committed
303
304
    * LCD control
        * Update control parameters
Tom's avatar
Tom committed
305
306
307
308
309
310

**Interrupts Required**



*   External interrupt 1 - optical encoder
Yadu sharon's avatar
Yadu sharon committed
311
    *   To measure the state change of optical position encoder - this will update the current address of the arm with respect to the homing position
Tom's avatar
Tom committed
312
313
314
315
*   External interrupt 2 - UI rotary encoder switch
    *   Changes the parameter screens in the lcd.
*   External interrupt 3 - UI rotary encoder
    *   Changes the parameter values (increase or decrease)
Yadu sharon's avatar
Yadu sharon committed
316
*   Timer interrupt
Tom's avatar
Tom committed
317
318
319
320
321
322
323
324
    *   Update the PID values for motor control.

**Software Control Flow**





Yadu sharon's avatar
Yadu sharon committed
325
![alt_text](Images/Copy-of5.png "image_tooltip")
Tom's avatar
Tom committed
326
327
328
329
330
331
332
333


**Wiring diagram**





Yadu sharon's avatar
Yadu sharon committed
334
![alt_text](Images/Copy-of6.png "image_tooltip")
Tom's avatar
Tom committed
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400



### Bill of Materials (BOM)


<table>
  <tr>
   <td>Sl No
   </td>
   <td>Item
   </td>
   <td>Qty
   </td>
  </tr>
  <tr>
   <td>1
   </td>
   <td>Windshield wiper motor (Lucas-TVS, Part No-26071041)
   </td>
   <td>1
   </td>
  </tr>
  <tr>
   <td>2
   </td>
   <td>Arduino Mega 2560
   </td>
   <td>1
   </td>
  </tr>
  <tr>
   <td>3
   </td>
   <td>L298N Motor Driver
   </td>
   <td>1
   </td>
  </tr>
  <tr>
   <td>4
   </td>
   <td>IR Optical Encoder
   </td>
   <td>1
   </td>
  </tr>
  <tr>
   <td>5
   </td>
   <td>Micro Limit Switch
   </td>
   <td>1
   </td>
  </tr>
  <tr>
   <td>6
   </td>
   <td>20x4 LCD screen (i2c)
   </td>
   <td>1
   </td>
  </tr>
  <tr>
   <td>7
   </td>
Yadu sharon's avatar
Yadu sharon committed
401
   <td>SPST Switch (or any on/off switch)
Tom's avatar
Tom committed
402
403
404
405
406
407
408
   </td>
   <td>1
   </td>
  </tr>
  <tr>
   <td>8
   </td>
Yadu sharon's avatar
Yadu sharon committed
409
   <td>Rotary encoder - Mechanical incremental
Tom's avatar
Tom committed
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
   </td>
   <td>1
   </td>
  </tr>
  <tr>
   <td>9
   </td>
   <td>12V to 5V Voltage regulator
   </td>
   <td>1
   </td>
  </tr>
  <tr>
   <td>10
   </td>
   <td>12V 5A power supply
   </td>
   <td>1
   </td>
  </tr>
  <tr>
   <td>11
   </td>
   <td>M5x20 SHCS t, Washers
   </td>
   <td>1
   </td>
  </tr>
  <tr>
   <td>12
   </td>
   <td>M3x15 SHCS
   </td>
   <td>10
   </td>
  </tr>
  <tr>
   <td>13
   </td>
   <td>3mm,6mm Acrylic sheets
   </td>
   <td>3 Sqft
   </td>
  </tr>
  <tr>
   <td>14
   </td>
   <td>10mm Delrin sheet
   </td>
   <td>2 Sqft
   </td>
  </tr>
</table>