Funded by AWS Activate - AWS Activate
https://github.com/obrienlabs/biometric/wiki
https://github.com/obrienlabs/biometric-ios
- BIOMETRIC-12Getting issue details... STATUS
Warning: this article involves rollerblades - please wear all protective gear (helmet, gloves, kneepads, elbopads) - There is one other older developer that wears rollerblades in NA here - one of my coworkers - https://www.wired.co.uk/article/ten-years-of-google-x
Requirements/Features
R1 | Redundant HRM tracking | |
R2 | Location based tracking correlation | |
R3 | Sensor tracking correlation | |
R4 | Data persistence on device | |
R5 | Data persistence on remote cloud | |
R6 | Live tracking of device via cloud | |
R7 | Cloud data export | |
R8 | Android specific requirements | |
R9 | iOS specific requirements |
Work Items
WI1 | XCode project | |
WI2 | Java backend | |
WI3 | JS frontend | |
WI4 | Persistence backend | |
WI5 | Cloud infrastructure | |
WI6 | Get AWS Activate funding AWS Activate | |
Use Cases
Location Tracking
Everywhere I turned on tracking is available from the DB.
run the following to get the list of record sets (ones ending in 5 are exercise specific)
SELECT distinct userId FROM biometric.gps_record r where r.userId like '202002%'; # KML for google earth http://biometric.elasticbeanstalk.com/FrontController?action=kml&u=202002210
Heart Rate Tracking
iPhone X client screen and a mobile web based monitoring screen.
Geo Tracking / Inventory
Heart rate fitness derivation
The heart rate follows the capacitator charge graph - logarithmic rise and logarithmic drop on exercise stop - an indicator of fitness
For example In the following graph you see that my fitness level increased by day 10 for 3 reasons (after I first started running in 2013 - the acceleration to peak rate, the peak rate and the deceleration from the peak rate. The slower the rise combined with a lower absolute rise combined with a swift return is optimal
Heart rate correlation to geography
Bluetooth 4 LE Mobile Rest client on iOS 12/3 with a backend JAX-RS JPA 2 Java cloud service on AWS
# Overview
- Full phone metric capture - GPS, Gravity, Accell, Orientation, Magnetic field, pressure, altitude, ambience, heading
- Additional device capture - 2 HRM bluetooth LE metrics - 2A37
- Derived metric capture - Geohash, speed
# JIRAs
Older system : https://obrienlabs.atlassian.net/projects/BIOM/issues/BIOM-2?filter=allopenissues
https://github.com/obrienlabs/biometric/issues
# Features
- Live google maps/HRM browser based user tracking
- KML google earth extract
- CSV extract
- XML extract
Design
Implementation
Virtual Machine based - EC2 - VMware
Docker Based
Kubernetes Based - RKE
Serverless Based - Lambda
Databases
Relational
MySQL Docker
Databases#RaisingMySQLinDocker
mysql> select * from biometric.gps_record where userId='201904080' order by heart2 DESC LIMIT 1; +----------+-----------+-----------+-----------+---------------+---------------+---------+--------------+----------+----------+----------+-------+-------+-------+--------+--------+--------+--------+----------+---------------+-------+-----------+-----------+-----------+----------------+------+-----------+------+----------+----------+-----------+----------+----------+-------+------+------------+------------+----------+---------------+---------------+-----------+---------+ | IDENT_ID | ACCELX | ACCELY | ACCELZ | ACCURACY | ALTITUDE | bearing | geohash | GRAVX | GRAVY | GRAVZ | GYROX | GYROY | GYROZ | HEART1 | HEART2 | HRDEV1 | HRDEV2 | humidity | LATITUDE | light | LINACCX | LINACCY | LINACCZ | LONGITUDE | PRES | provider | PROX | RECV_SEQ | ROTVECX | ROTVECY | ROTVECZ | SEND_SEQ | speed | temp | teslaX | teslaY | teslaZ | tsStart | tsStop | userId | version | +----------+-----------+-----------+-----------+---------------+---------------+---------+--------------+----------+----------+----------+-------+-------+-------+--------+--------+--------+--------+----------+---------------+-------+-----------+-----------+-----------+----------------+------+-----------+------+----------+----------+-----------+----------+----------+-------+------+------------+------------+----------+---------------+---------------+-----------+---------+ | 11271220 | -0.763702 | -1.003540 | -0.230164 | 65.0000000000 | 76.0890050000 | 99 | f244mkh5h13t | 0.000000 | 0.000000 | 0.000000 | NULL | NULL | NULL | NULL | 109 | NULL | NULL | NULL | 45.4180030000 | NULL | -0.763702 | -1.003540 | -0.230164 | -75.7011200000 | NULL | 12.100000 | NULL | 3662206 | 0.532636 | -0.462588 | 0.541578 | 2234 | -1 | NULL | -69.590858 | -20.243172 | 0.503548 | 1554738044948 | 1554738045010 | 201904080 | 0 | +----------+-----------+-----------+-----------+---------------+---------------+---------+--------------+----------+----------+----------+-------+-------+-------+--------+--------+--------+--------+----------+---------------+-------+-----------+-----------+-----------+----------------+------+-----------+------+----------+----------+-----------+----------+----------+-------+------+------------+------------+----------+---------------+---------------+-----------+---------+ 1 row in set (12.66 sec) mysql> select count(1) from biometric.gps_record; +----------+ | count(1) | +----------+ | 11933650 | +----------+ 1 row in set (11.87 sec) increase core count from 8 to 14 mysql> select count(1) from biometric.gps_record; +----------+ | count(1) | +----------+ | 11933650 | +----------+ 1 row in set (5.32 sec)
Graph
Key Value
Deployment
Fitbit BLE 2a37 Characteristic API for Heart Rate
Via SDK https://dev.fitbit.com/build/reference/device-api/heart-rate/
Links
Covid related - https://www.theglobeandmail.com/business/international-business/article-apple-google-to-adapt-phones-for-virus-infection-tracking/
DND Physical Testing https://www.cfmws.com/en/aboutus/psp/dfit/fitness/forceprogram/pages/force_videos.aspx
https://www.supersapiens.com/en-GB/