Hi guys;
I starting learn the way Max7219 works. this is my first attemp.
#include "LedControlMS.h"
#define NumMatrix 1 // Cuantas matrices vamos a usar
#include <DS1302.h>
// Inicializacion del modulo.
DS1302 rtc(2, 3, 5);
Time t;
LedControl lc=LedControl(12,11,10, NumMatrix);
void setup()
{
for (int i=0; i< NumMatrix ; i++)
{
lc.shutdown(i,false);
lc.setIntensity(i,8);
lc.clearDisplay(i);
}
}
void loop()
{
t = rtc.getTime();
lc.writeString(0,t.date);
delay(1000);
}
well, as you noticed , through "if" instruction is possible print all values.
if (t.date == 1) lc.writeString("1");
if (t.hour == 1) lc.writeString("1");
However this way, is awkward and inefficient define all numbers an characters.
¿Is it possible to print any kind of variables ( serial. analog , digital read etc..) using ledControl Ms library?
¿Would you share an clue or example how I must solve this problem?