2016-03-15 (Tu) Cyborg Heart Rate Sensor

Upper and lower limits were recorded by the program to track the boundary of accurate readings. The low limit recorded the lowest reading from readings were presumably taken from skin. Readings from the skin tended to be away from 0V and Vcc. The highest reading worked similarly. Pseudo code was designed before that would calculate these limits based on the first readings that were seen then push the limits further out if such readings occurred. The flaw with this system was that errant readings could skew the rest of the data by keeping the limits far out. One method to correct this would have been to calculate the upper and lower limits based on only the previous X readings but this would have involved keeping a large amount of data in storage and repeatedly cycling through it. Instead it was decided to try "creeping" the limits in slowly. By continuously lowering the upper limit and raising the lower limit the range would stay roughly from one reading to the next but any time a high or low value was seen the program would acknowledge it. Errant readings would still upset the data but only briefly.

A graph was made to show the data being read, green, the lower limit, blue, and the upper limit, yellow. Limits can be seen to continuously move toward the center of the data being read while the data only occasionally has to bump it back into position.

Graph showing the creeping limits

After seeing the data it became clear that the current method of acknowledging a heartbeat was not working. A heartbeat was considering anytime the recorded data was 3/4 of the way from the lower limit to the upper limit. This should be changed so that a heartbeat is recognized anytime a reading jumps at least Y volts from one reading to the next and is in the upper half of the limit range.

To do:
      • Program with Digispark
      • Debug 
      • Integrate hardware
        • Coil
        • Vibrator motor
      • Build into glove

        The rest of the posts for this project have been arranged by date.

        First time here?

        Completed projects from year 1.
        Completed projects from year 2

        This disclaimer must be intact and whole. This disclaimer must be included if a project is distributed.

        All information in this blog, or linked by this blog, are not to be taken as advice or solicitation. Anyone attempting to replicate, in whole or in part, is responsible for the outcome and procedure. Any loss of functionality, money, property or similar, is the responsibility of those involved in the replication.

        All digital communication regarding the email address 24hourengineer@gmail.com becomes the intellectual property of Brian McEvoy. Any information contained within these messages may be distributed or retained at the discretion of Brian McEvoy. Any email sent to this address, or any email account owned by Brian McEvoy, cannot be used to claim property or assets.

        Comments to the blog may be utilized or erased at the discretion of the owner. No one posting may claim claim property or assets based on their post.

        This blog, including pictures and text, is copyright to Brian McEvoy.

        2016-03-12 (Sa)