Heart Rate demo app
The Heart Rate app provided on the Darcy Cloud platform simulates a wearable device transmitting a person’s heartbeat at the edge. The Wearable sends heart rate data over bluetooth to a data collector microservice located on the primary node . The Data collector microservice then communicates with another microservice running a web server on the secondary node to display the heart rate data on a graph.
Requirements
- A Darcy Cloud Account
- Any edge node (or a virtual node)
Deploy using Darcy Cloud Portal
Deploying the Heart Rate Application from the Darcy Cloud platform is extremely simple. Make sure you have added at least 1 node to your Darcy Cloud project , then follow the steps below:
- Go to your Darcy Cloud project page
- Select
Apps
- Click on
+ DEPLOY APP
- Click on
DARCY HEART RATE DEMO
- Select the node(s) where you want it to run
- Click
DEPLOY
See Application Results
When your app is deployed successfully you will see an Application Deployed
message in the top
right of your screen.
If you are not already seeing the app listed, click the APPS
tab to see all of the apps in your
current project. Click the app to access the app detail view.
From the app detail view, click the linked text under the ports
column to navigate to the app
output.
You should be brought to the Heart Rate Demo App.
App YAML
kind: Application
apiVersion: iofog.org/v3
metadata:
name: darcy-heart-rate-demo
spec:
microservices:
- name: data-generator
agent:
name: '{% raw %}{% assign agent = "" | findAgent | first %}{{ agent.name }}'
images:
arm: 'darcyai/heart-rate-demo-generator:1.0.0'
x86: 'darcyai/heart-rate-demo-generator:1.0.0'
container:
rootHostAccess: false
ports: []
config:
test_mode: true
data_label: Anonymous Person
- name: viewer
agent:
name: virtual-node-alexpc
images:
arm: 'darcyai/heart-rate-demo-viewer:1.0.0'
x86: 'darcyai/heart-rate-demo-viewer:1.0.0'
container:
rootHostAccess: false
ports:
- external: 5005
internal: 80
proxy: true
volumes: []
env:
- key: BASE_URL
value: 'http://localhost:8080/data'
routes:
- from: '{{self.microservices[0].name}}'
to: '{{self.microservices[1].name}}'
name: monitor-to-viewer