Voice Activated Hospital Bed

A while back I did a post about controlling a hospital bed with a robotic button pusher and then voice activating it:

That can be a useful method if for some reason the bed controls can not or should not be modified. But in cases where you can modify the bed controls, this can simplify the solution and remove some possible points of failure. Here’s a video of one implementation in action:

The individual I built this for had great voice recognition success with Amazon Echo and was already using that for other things like controlling lights in her apartment so for this first go that’s what we also used to control the bed. Similar to my voice activated window shade project, voice commands are picked up by Echo and sent to a Photon board via IFTTT:

Even though the bed is now voice activated, there are times an aide will want to still be able to control the bed with a controller for more direct control. Also if there’s some issue with the voice activation you want a fallback. To facilitate this I repurposed the controller as an input to the new system. In this way both voice and the controller can control the bed.

img_20160930_111742  img_20160930_111407

Here are some closeups of the electronics now controlling the bed. These electronics perform the same functions that the original bed controls did but these can also be activated by voice. The original controller simply had relays in it that were button actuated. This new setup also has a set of relays wired up the same way to the bed control wiring which I unsoldered from the original controller circuit board. These new relays are controlled by an Arduino.

img_20160930_111023  img_20160930_111241  img_20160930_111201

Original Bed Control Wiring
For each of the movements, the corresponding wire should connect to GND when OFF, and connect to VDD when ON.

  • Lt Blue -> S1 -> Head Up
  • Dk Blue -> S2 -> Head Down
  • Pink -> S3 -> Feet Up
  • Purple -> S4 -> Feet Down
  • Yellow -> S5 -> Bed Up
  • Brown -> S6 -> Bed Down
  • White -> GND
  • Green -> VDD

Below is the main motor under the bed including the cable to the bed controls and the cable to the secondary motor. NOTE: kept in the room is a second unmodified bed controller. If for some reason the new setup breaks, it can be unplugged and the unmodified controller can be plugged in to replace it until a repair is made. As much as possible fallbacks must be in place so the user is not stuck in a bad situation.


This particular setup does have several dependencies and risks which must be evaluated for the the user’s exact situation. First are the network dependencies which amount to the internet connection in the user’s living space, the WiFi router, Amazon’s Alexa servers, IFTTT’s servers, and Particle’s servers. If any of these are down, the bed will not operate by voice until those are restored. Note that there are several means of voice recognition that do not rely on the internet, but those must be evaluated with the particular user.

Lastly, the outcome of a malfunction must be understood and weighed, in this case the bed moving when it shouldn’t, or not moving when it should. If a malfunction would only be inconvenient, that’s a different conversation than if a malfunction would be harmful.

4 thoughts on “Voice Activated Hospital Bed

  1. I met with a young man today who needs a solution like this. I am curious if it is possible to stop somewhere in between the head end being all the way up and all the way flat down.

    • Yes. The device as-is simulates holding the given button for a set period of time, lets say 30 seconds.

      You could change that to 10 seconds to break up the distance, but then multiple commands will need to be spoken to go all the way. But if the user was ok with this, that is what I would suggest.

      Alternately a stop command could be implemented. But often the response time is too long (or sometimes the user is misheard), leading to the desired stop position being missed.

  2. Would it be possible to use this same concept to raise and lower a table that a child is using so that it can be height adjustable with voice command as well as with a remote? Would the electronics be small enough to fit in the table leg? Thanks.

    • Hello Gail, thank you for the question. Yes, it would be possible to set this up, and it could potentially fit inside the table leg itself depending on the size of the leg and access to it. The main thing is to assure the safety of the user. A voice command can always be misheard and the table would then start moving down unintentionally. The setup must insure that the full range of table motion including the lowest position does not hit any part of the user’s body including their legs under the table for example. There are many ways to ensure this safety, but it must be thought through carefully.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s