iot of heart rate watchdog

28
105 嵌入 式韌體工程師菁英班 Internet of Things of Heart Rate Watchdog Group Members : 劉語文 高世宇 何裕鈞 王建凱 Special thanks for instructions given by 何文吉

Upload: -

Post on 15-Apr-2017

1.482 views

Category:

Technology


0 download

TRANSCRIPT

105 嵌入式韌體工程師菁英班

Internet of Things

of

Heart Rate Watchdog

Group Members :

劉語文

高世宇

何裕鈞

王建凱

Special thanks for instructions given by 何文吉

You care about your health!

You care for your heart!

…Affecting heart rate and

pulse, moreover your health!

The ‘Why’ for

the project!

• For any possibilities:

– Analyze heart conditions for personal daily health

maintenance

– Red alert for emergencies

– Remotely observe the health welfare of those you love

– Smart software as personal health coach

– Easy-to-carry heart rate device

– Simple usage and low cost

P.S. Heart disease is the

NO.1 death factor in the world!

Sensor

Board

ADC

UARTs WiFi

Web Server

1.TCP socket

2.WebSocket

Heart Rate

Calculation

on PC

LCD

System Structure

Rasbberry Pi 2ARM MCU

Client

Heart Beat

Calculation and Analysis

Heart Beat’s Waveform

• Diagram 1 –Animated plotting

• Diagram 2 – Recorded data points with peaks

BPM

(Beats per minute)

𝐻𝑒𝑎𝑟𝑡 𝑅𝑎𝑡𝑒 =N𝑢𝑚𝑏𝑒𝑟 𝑜𝑓 𝐵𝑒𝑎𝑡𝑠

(𝑇𝑎−𝑇𝑏) (𝑠)∙60 (𝑠)

1 (𝑚𝑖𝑛)= 𝐵𝑒𝑎𝑡𝑠

𝑚𝑖𝑛

𝑇𝑎(first beat at time 𝑇𝑎)

𝑇𝑏(last beat at time 𝑇𝑏)

ARM MCU

&

Electronics

Sensor

Board

ADC

UARTs WiFi

Web Server

1.TCP socket

2.WebSocket

Heart Rate

Calculation

on PC

LCD

Client

Rasbberry Pi 2ARM MCU

System Structure

Infrared Sensor CNY70 Board

Heart

pumps

Heart

relaxes

A. Signal detect B. Current Amp.

C. Volt. Amp.

Blood

thickens

Blood

thins

Physical Sensor Board

• Done with OrCAD schematic and Allegro layout

Sensor

Board

ADC

UARTs WiFi

Web Server

1.TCP socket

2.WebSocket

Heart Rate

Calculation

on PC

LCD

Client

Rasbberry Pi 2ARM MCU

System Structure

Analog-to-Digital

Converter

ADC converts analog

signal every 20ms.

ADC Process

Sensor

Board

ADC

UARTs WiFi

Web Server

1.TCP socket

2.WebSocket

Heart Rate

Calculation

on PC

LCD

Client

Rasbberry Pi 2ARM MCU

System Structure

ADCConverted data

UART1

UART0

BPM calculation

Data to UARTs

WifiData storage

Sensor

Board

ADC

UARTs WiFi

Web Server

1.TCP socket

2.WebSocket

Heart Rate

Calculation

on PC

LCD

Client

Rasbberry Pi 2ARM MCU

System Structure

WiFi Transmittion

By UART0

Original Signal

UART0

Internet

Communications

Sensor

Board

ADC

UARTs WiFi

Web Server

1.TCP socket

2.WebSocket

Heart Rate

Calculation

on PC

LCD

Client

Rasbberry Pi 2ARM MCU

System Structure

TCP

socket

HTTP

WebSocket

MCU

Server

Client

Internet Comm.

Broadcast

Broadcast

Clients

Using WebSocket

Over Polling

Source: http://www.websocket.org/quantum.html

WebSocket

Connection

Open

On_message

Close

Build and record connections

Start and transfer data for both

sides of client and server

Disconnect connections and remove records

WebSocket

Data Transmitting

HTTP

request

response

WebSocket connecting

Data sent at different times

Server Client

Chopped data 1

Chopped data 2

Chopped data 3

Webpage As Client

Sensor

Board

ADC

UARTs WiFi

Web Server

1.TCP socket

2.WebSocket

Heart Rate

Calculation

on PC

LCD

Client

Rasbberry Pi 2ARM MCU

System Structure

Graph frame setup

Requests data from server

Receives and stores data into array

Awaits until array saves 200 data points and

starts graphing

Graphs and refreshes by adding 5 newest data

points to and removing oldest 5 data points from

the graph

HTML WebSocket

JavaScript

JQuery

Design Process

Last, but not least…

Importance of heart rate analysis