Arduino heartbeat LED class library
Arduino heartbeat LED class library

This class combines a heartbeat live indicator with a handy diagnostics tool. You can show errors by its own LED blinking code message. 

Heartbeat showing blinking LED error code 3: 

Library download

Download at GitHub here.

Simpel example

#include "avdweb_HeartBeat.h"

const byte LedPin = 13;
HeartBeat heartBeat(LedPin);

void setup(void) 
{ 
}

void loop(void) 
{ heartBeat.poll(); // first 4sec heartBeat LED
  if(millis()>4000) heartBeat.blinkLED(3); // after 4sec diagnostic blinking LED error code 3
}



 Notes

  • If there are multiple error messages given simultaneously, the lowest number has priority and will be shown by the blinking LED.
  • The value of the LED series resistor depends on the LED efficiency, it should be selected in such a way that the LED goes from minimum to maximum.
  • There are no hardware timers used.
  • You can use all Arduino pins for the LED.

 

 

Do you have any comments about the website or problems with shopping? Please let me know.
Creative Commons License
This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License.