Skip to main content

Designing and Building a Bed Monitoring System for hospital use

DSC_01861_2ed0e042650f711e3b5ec079e719c453a548604e.jpg

So far in my posts documenting the making of my bed monitoring system, I have covered writing the code and designing the circuits for a device that integrates a moisture sensor and a weighing mechanism, and made a custom acrylic case for these. The device logs a patient’s weight and a bed status of wet/dry to a CSV file that can subsequently be displayed in graph format, but also in the case of a wet bed, turns on an LED corresponding to the bed number on a LED bank located at a nurse’s station. The aim is to make a system that can be utilised in a hospital environment as wet beds increase the risk, severity, care time and cost of pressure sores. The hope is to reduce these aspects, which will in turn mean a speedier recovery and a better experience, and save some money in the process. It should also greatly benefit the patients and the nurses alike. Patient’s dignity in upheld through not having to ask publicly for help and those that are bedbound don’t have to get out of bed to be weighed several times a day to be able to quantitate their doses. It should also be a great tool for nurses to save them time and track some of the information they need. It’s all coming to a head now and the only thing I have to do is to solder all of my components to a prototyping board and assemble it. It’s the moment of truth and the pressure is on. Plus, being a bunglemsome lefty, soldering is not one of my strong points. The whole right handed world is against us, but that’s a different blog entirely. Here I’m just going to look at soldering the prototyping board, and my sensors and bringing it all together.

The Prototyping board

To minimise my chances of totally botching up my prototyping board — which I did anyway — I planned my prototyping by drawing countless plans and layouts before I started. First of all I combined my moisture sensor circuit, the IN1255P amplifier circuit and my MCP3008 analogue to digital converter circuit into one. That can be seen on the fritzing shot below.

fritz1_63f5b977214e56e4b825d27e1118ff36750c2925.png

I then used the Adafruit prototyping board for the Raspberry Pi to solder it in the hopes of creating a more professional prototype.

adafruit1_59244b0c82af49e5d955d393eb2e7f013b98c820.jpg

The board itself is half breadboard half perf board allowing for the use of DIP chips and sensors etc. There are screw blocks so you can make the sensors semi-permanent — something I decided against, but I’ll come back to that later. It is worth noting that this kit is best used for the Raspberry Pi Model A or Model B. You can use it with any "2x20 GPIO type" Pi (A+, B+, Zero, Pi 2, Pi 3) but only the 'top 26 pins' will be available for use. Luckily this didn’t affect me, but if your using those in any projects your undertaking a little re-jigging will need to be done. I drew out my set up on countless pieces of paper before I had one that I got right and then I set about soldering.

board_f5fe32b583b0d49e65b416fd5119dd8637d10dc1.jpgAbove you can see a half way through stage as it was starting to come together. Once I’d finished that I started on my sensors.

The sensors

At this stage I could have just soldered the sensors or used the screw pins, but I wanted to do a little more than that. Even though the casing for the prototype was open sided, I still wanted to make it as close to a final functioning device as I could, including sockets that meant that both the moisture sensor and the weight cell could be taken out and replaced easily if broken etc. I didn’t want to create a prototype that seemed really cheap to produce, but then once you started to develop it and add in hospital environment standards the price sky-rocketed; I wanted to be as accurate as I could from the outset. I chose IP rated sockets, and selected a 3-way panel mount socket and cable mounted plug for the moisture sensor, and 4-way panel mount socket and cable mounted plug for the weight cell. Below are a few pictures of the soldering process for my moisture sensor

solder1_76efc76020d65fd79a45d0fdc98f9ed40efeabf3.jpg

solder2_0b5f3d048fab8fed142db017b6ca7aadc2db5578.jpgsolder3_6a1c62c57c29c5db9132683bb3cdc3e556dc7a29.jpgsolder4_a74f0823513097595c5deeb2e1db826c3e790d75.jpgThe sensor terminated in very fine wire which was sewn into a piece of cloth. This is obviously not ideal, but for the purposes of the prototype was fine.

cloth1_fb9caa3c7fe73c9139f72a7743541bc310d6e0e0.jpg

cloth2_f7113f6f9a32605b53d524237ceaa26a449da942.jpgI then mounted my Raspberry Pi and the prototyping board and put the case together.

DSC_0180_d7dba68fc2c0322bd38f511756d1e37ffeb915e0.jpgDSC_0181_e06cff84027e2c8414afc90af1a669241e9efbc9.jpg

The nurse’s station was a similar process.

DSC_0126_8b13437cd8e23708fa03f9cdaadb6443e7ab0037.jpgDSC_0130_3bbd670d34b62bc6b5b8fd3693c7178bc1ce0330.jpgDSC_0132_659ee32fbeaf4db9c7cd9153fbf777d40accd4e0.jpgDSC_0136_0ad17473b79a1562aa1d32827600b7bb9fc32851.jpg

My prototype was now complete.

DSC_0188_244dbfa7fe9b0d3a5cf309ff95709466a83ca60c.jpgDSC_0190_097a1014847affb07446d1c2987d6115572e77d7.jpg

 

Connecting the Sensor to the station

To send information from the sensor to the nurse’s station I looked into a few different messaging systems. Message Queuing Telemetry Transport (MQTT) was introduced in 1999 by IBM. MQTT is a straightforward messaging protocol for machine-to-machine (M2M) communications that permits the transfer of data in the form of messages. Data Distribution Service for Real-Time systems (DDS) was another option. DDS and MQTT share some factors, such as frugality and efficiency, temporal decoupling and anonymity, but each have some inimitable features that make it more, or less suitable to a certain job. MQTT is most suitable for intermittent messages whereas DDS is most suitable for those applications that require real-time data exchange. While both have Raspberry Pi library’s that can simply be imported and used, as stated before the MQTT is pretty straightforward, and where DDS provides support for both Device-to-Cloud (Device-to-Data Centre) communication as well as Device-to-Device, MQTT provides very good support for Device-to-Data Centre communication. Since I am looking to send lots of information to one centre this appears to be the best solution. Coding can be written much in the same style as my previous code that controlled my bed monitor in my previous post. The bed monitor would run and the nurses station would send out a message to the bed monitors to return it the data regarding the beds status and patient’s weight, this would then the returned and logged on the central nurse’s station to a file or SD card etc.

Completing the project

Over the course of starting to intern at AB open and undertaking this project, I’ve learned more here than I did in my whole time in formal education. Well, that might be a slight exaggeration, but only slight. In such a short time, I’ve gone from never having even heard of Python to being able to understand functions, strings etc, to look at code and understand its purpose and write my own code. I’ve learned a lot about industry standards, do’s and don’ts, especially within prototyping. Though by no means an expert as you’ve seen, I’ve improved my soldering techniques, learned to laser cut, learnt about the design process as a whole and enjoyed myself along the way. I’ve added a few strings to my bow and I can’t wait to use them in future projects.

I Graduated from the University of Bradford with a degree in Chemistry and Forensic Science and currently I am studying towards a HND in Electronic and Electrical Engineering while interning at AB Open.
DesignSpark Electrical Logolinkedin