Hi i have a Grove finger-clip heart rate sensor. I use the following code to obtain heart rate readings;
#include <Wire.h>
void setup()
{
Serial.begin(115200);
Serial.println("Heart Rate Sensor");
Wire.begin();
}
void loop()
{
Wire.requestFrom(0x50, 1); // request 1 bytes from slave device
while (Wire.available()) // slave may send less than requested
{
unsigned char c = Wire.read(); // receive heart rate value (a byte)
Serial.println(c, DEC); // print heart rate value
}
delay(500);
}
The problem i am facing is displaying the data in graph form on the TFT LCD screen. Can anyone give me further guidence in accomplishing this. Do i need to add to this code or do i need to use a new one. Bare in mind this is a i2c device with the address of 0x50 and runs with library wire.h
??