Skip to content

A 1-button alarm system for Raspberry Pi and cell phone hat. Dog presses button -> SMSes sent to emergency contacts

License

Notifications You must be signed in to change notification settings

Wheels00/dog-phone

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

A 1-button alarm system for Raspberry Pi and cell phone hat. Dog presses button -> SMSes sent to emergency contacts

Purpose

A service dog can be trained to press a button to call for help when a person with a disability needs help but can’t get to the phone. If you know your service dog can call for help, you feel more confident and secure, especially if you can customise who gets contacted, when, in what order, and what information they receive.

The purpose of this software is to reliably, transparently and configurably do this.

The idea for this project came from Claire S and her service dog, Ned.

Contribute

I Wheels00 am making only very slow progress due to lack of knowledge of Linux, Python, and Flask. Assistance needed!

Two ways you can help:

  1. Read this README then add suggestions under Issues for how to achieve the aims
  2. Clone this repo, make code contributions, and then send us a pull-request

Hardware

Here's the hardware we already have:

Feature Specification

Minimum Requirements

On button press:

  • play countdown.wav on speaker (opportunity for user to cancel)
  • Check for cell network connection
  • send alert_message by SMSes to contact_list in specified order after specified delays (announce each action on speaker); and
  • loop waiting.wav on speaker; while
  • listen for reply SMS from contacts, and on receiving message containing acknowledge_keyword:
    • announce receipt of acknowledge_keyword
    • loop help_on_way.wav on speaker
  • listen for SMS from user, and on receiving cancel_keyword:
    • reset

Connection monitoring

  • Every 5 minutes:
    • check for cell network connection, and if not connected after 10 minutes:
      • play no_signal.wav on speaker

Config Web App

  • Connect to LAN via WiFi
  • Serve web app on port 80
  • Allow user to set:
    • alert_message
    • contact_list:
      • name
      • phone_number
      • delay
    • acknowledge_keyword
    • cancel_keyword
    • Wifi SSID
    • Wifi password

Boot

  • Automatically run all scripts on boot

Installation

  • Install all components and dependencies by running setup.sh

Eventual features

  • 'just a drill' mode
  • speaker phone phone call

Approach thus far

This may not be the best approach, but it's what I have thus far.

  • Web app via Flask and Flask-WTF
    • Web app saves user config to json files in the storage folder
  • 'main' program
    • reads user preferences from json files in the storage folder
    • Monitors GPIO pin for button press
    • Interacts with Waveshare Phone HAT by AT commands, with helper functions defined in phonelib.py (based on the Waveshare demo code)
    • plays audio on speaker

Footnotes

  1. Extra Waveshare info

About

A 1-button alarm system for Raspberry Pi and cell phone hat. Dog presses button -> SMSes sent to emergency contacts

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published