Home>

After measuring and recording the current heart rate for a certain period of time,
I am trying to make a program that can play back the record with a circle gauge UI like an image.

I have no idea how to create a circular gauge like an image by myself or how to move the gauge with the measured heart rate data.

Could anyone please give me a hint and a path to completion?
Also, could you please tell me a site or book that shows the way?

* I'm thinking of measuring the heart rate itself with arduino.
Reference site link for heart rate measurement

  • Answer # 1

    Clarified in the question

    How to create a circular gauge like an image, how to move the gauge with the measured heart rate data

    Just a sample about. Processing looks good too.

    void setup () {
    size (500,500);
    }
    void drawGraph (float beat, float max) {
      translate (width/2, height/2);
      fill (255);
      textAlign (CENTER, CENTER);
      textSize (64);
      text (beat, 0,0);
      strokeWeight (25);
      strokeCap ​​(SQUARE);
      noFill ();
      stroke (128);
      circle (0,0, width * 0.6);
      stroke (0,192,255);
      arc (0,0, width * 0.6, width * 0.6, -HALF_PI, TWO_PI/max * beat-HALF_PI);
    }
    void draw () {
      background (0);
      float beat = 60+ (millis ()% 5000)/1000 .;
      drawGraph (beat, 100);
    }