Hello people, I am doing my final degree project that consists of an LED cube, the fact is that I have added an LCD and a button to interact, the thing is that when pressing the button, I would like to create a timer of 10 seconds with their respective thousandths and that the minutes would also come out but in 00, since we will use it. It would be something like this (00:10:00). So summing up, it would be to press the button, that you put "remaining time", below the stopwatch and after 1 second that I started to count down to 0. I hope you can help me because I was a bit stuck in that part, many thanks!
OK, noted your post also in the Spanish section.
So when are you going to give us the details?
Paul__B:
OK, noted your post also in the Spanish section.So when are you going to give us the details?
void loop (){
puls= digitalRead(28);
if ((puls==1)&&(key==1))
{
lcd.print("TIEMPO RESTANTE...");
lcd.setCursor(0,1);
delay(1800);
lcd.print(tiempoV / 60000); // <<== minutos
lcd.print(":");
lcd.print((tiempoV % 60000) / 1000); // <<== segundos
lcd.print(",");
lcd.print((tiempoV % 1000) / 10); // <<== decimas + centesimas
#ifdef DEBUG
showmem("start");
#endif
cubeFrame* f[] = {
cube.createFrame((byte[]) {0,6, 1,6, 2,6}, 6, 80),
cube.createFrame((byte[]) {0,7, 1,7, 2,7}, 6, 70),
cube.createFrame((byte[]) {0,8, 1,8, 2,8}, 6, 60),
cube.createFrame((byte[]) {0,5, 1,5, 2,5}, 6, 50),
cube.createFrame((byte[]) {0,2, 1,2, 2,2}, 6, 40),
cube.createFrame((byte[]) {0,1, 1,1, 2,1}, 6, 30),
cube.createFrame((byte[]) {0,0, 1,0, 2,0}, 6, 20),
cube.createFrame((byte[]) {0,3, 1,3, 2,3}, 6, 10)
};