Week 5 Update

Day 1 and 2


Day one and two of this week were arguably some of the most productive of my time here so far. At this point I feel like I have a good understanding of how to produce quality production parts from my 3D printer. I was able to print some possible prototypes for the mechanism that pushes the insulin out of the reservoir. They all work on the same principle, so here is an example of one I am testing:

All of the extruders that I am testing are open source and on thingiverse.com .

Day 3


On day 3 I realized that I had completed all of the pieces necessary to have a crude pump except for the code that controlled the extruder. I used the python code mentioned in my last blog post, along with code to control the stepper motor, and merged the two to work together. Once I had successfully merged the two pieces of code into one python program, I used the blood sugar value that is updated every 5 minutes to control a specific amount of steps (at this point it is not calibrated, but it does work!). I then placed the entirety of the code into one big while loop that allows me to pump a desired amount based off of blood sugar values every 5 minutes for a desired amount of time. This was a huge success in my program having the code finished to the point where I can start making physical prototypes, and the project is really coming together now.

Day 4 and 5


Both of these days were fairly slow considering most of the day was spent waiting for pieces to print out. On the bright side I was able to successfully print out a screw and (basically) a threaded nut that works. For anyone who knows 3D printing knows how difficult this task really is on an FDM printer (the type of printer that I am using). This gives me hope for creating an insulin pump that is completely 3D printed aside from the Raspberry Pi and motor. One of the main issues that I have with current diabetes technology are the astronomical prices for the technology, and one of my main points in my project was making an insulin pump that is very cheap to produce, and 3D printing allows for costs to be far lower.

While I was waiting for my prints to emerge out of the build plates I kept busy with Dr. Remy setting up 3D printers that the IT department had ordered. We wanted to see just how fast we could get a printer from the box to a functioning state. We were able to achieve this task in ~51 minutes, which is pretty impressive considering how many moving pieces make up a 3D printer. Also, setting up 3D printers helps gain a further understanding of how the printers work. This is why I suggest new users to order 3D printer kits rather than fully assembled printers. For one, they are much cheaper when they are in the kit form, and you get a better understanding of how they function.

Hopefully by next week I will be able to have my first fully functioning prototype of an insulin pump which is very exciting. More to come in next weeks blog post!

Week 4 Update

Overview


After last weeks successes with getting the readings from my CGM (continuous glucose monitor) into my cloud database, it was now time for me to figure out how I could get those values out of the cloud so that I could use them to run my insulin pump.

Day 1 and 2


At this point I had realized that getting the readings from the database to be usable would be quite the task taking my lack of knowledge in python into consideration. I knew that I would need to use some type of driver to get the data out of the mongo database, however, I had never coded a task like this before so it was quite the learning curve. A driver basically allows the user to get the data from their collections in the database, and to be able to use that data in their programs. Luckily mongoLabs, the company that I am using to host my database has a driver through python called pymongo that allows me to access my data in python. This would be an efficient way for me to use the data that I was collecting from my CGM.

Early on Monday morning I was also surprised with the arrival of my own 3D printer that I had ordered. After seeing how much was possible with the 3D printers, I knew that I needed to have my own, so much of Monday was spent setting up and tinkering with my new printer.

Day 3 and 4


With help from Dr. Remy, the fourth day of this week I was able to have a working program that would fetch the data that I wanted from my collection and output my blood sugar value, the date and time, as well as the direction in which my blood sugar was trending. With this I am able to start programming my final program that will control my insulin pump. 

Here you can see that I ran my python program, and actively collected my blood sugar values every five minutes for over an hour.

Day 5


Now that I had a working program to collect my blood sugar information it was time for me to experiment with python programs that control stepper motors to pump out the insulin. Essentially a stepper motor allows you to program a motor that will turn a specified amount by the program. I do not yet have a working program that controls the stepper motor based off of my blood sugar values, however it should not be too difficult to program, so look out for that in the next blog post.

On day five we also talked about our project timelines and how our projects were coming along. With four weeks down already, the presentation date is fast approaching. I found that I had achieved many of the goals that I had set out to achieve and more. There are endless possibilities in my project and I am working to implement as many features as I can, and I have decided that I will be trying to achieve my stretch goal of creating a truly closed-loop insulin injection system. In the coming weeks I will be perfecting my program that controls the stepper motors, and 3D printing prototypes for the final insulin pump. The project is beginning to take shape and it is a truly rewarding process. At this point it is promising that I will be able to achieve my stretch goal, and maybe even beyond that.