Bonsoir,
Je réalise un petit appareil mesurant la qualité de l'air à l'aide d'un module MQ135.
Mon souhait est de ralentir le retour de la valeur réellement mesurée après une brusque montée.
Mon boitier compte 6 degrés de qualité d'air. Mon objectif est de simuler un "lent" retour depuis la valeur maximale et par toutes les phases intermédiaires avant de retrouver la valeur réelle la plus basse et réellement mesurée.
Voici mon code :
#include <SPI.h>
#include <Wire.h>
#include <Adafruit_GFX.h>
#include <Adafruit_PCD8544.h>
#define BLACK 1 //< Black pixel
#define WHITE 0 //< White pixel
#define broche_LED 6 // Définition éclaiurage écran 5110
// Adafruit_PCD8544(CLK,DIN,D/C,CE,RST) définition des ports arduino vers écran 5110
Adafruit_PCD8544 display = Adafruit_PCD8544(7, 8, 9, 10, 11);
//6 éclairage écran led 5110
//7 CLK
//8 DIN ou DN<MOSI
//9 D/C
//10 SCE ou CE
//11 RST ou reset
// Définition port du buzzer
const int buzzer=5;
//definition de la valeur d'entree "mesure"
int mesure;
//int mesureee = (mesure * 6)-25;
// Définition de chaque note de musique
#define NOTE_A 19.4//8372//2093
#define NOTE_B 311//5587//3520
#define NOTE_C 740//7458//3729
// 'POISSON01', 39x34px
const unsigned char epd_bitmap_POISSON01 [] PROGMEM = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x80, 0x00, 0x00, 0x00,
0x18, 0xc0, 0x00, 0x00, 0x00, 0x30, 0x60, 0x00, 0x00, 0x00, 0x61, 0xe0, 0x00, 0x00, 0x00, 0xcf,
0x3c, 0x00, 0x00, 0x00, 0xb8, 0x07, 0x00, 0x00, 0x00, 0xe0, 0x01, 0x80, 0x00, 0x01, 0x80, 0x00,
0xc0, 0x00, 0x03, 0x00, 0x00, 0x60, 0x03, 0xe2, 0x00, 0x00, 0x30, 0x02, 0x36, 0x00, 0x00, 0x10,
0x02, 0x1c, 0x00, 0x00, 0x18, 0x02, 0x0c, 0x00, 0x00, 0x08, 0x03, 0x00, 0x00, 0x00, 0x08, 0x01,
0x80, 0x01, 0xc0, 0x48, 0x00, 0x80, 0x03, 0x80, 0xe8, 0x01, 0x00, 0x03, 0xe0, 0xe8, 0x03, 0x0c,
0x03, 0xc0, 0xc8, 0x02, 0x1c, 0x03, 0x0e, 0x68, 0x02, 0x36, 0x01, 0xc6, 0x08, 0x03, 0xe3, 0xc0,
0x04, 0x08, 0x00, 0x01, 0x80, 0x00, 0x18, 0x00, 0x03, 0x00, 0x00, 0x30, 0x00, 0x01, 0xee, 0x00,
0x60, 0x00, 0x00, 0x38, 0x83, 0xc0, 0x00, 0x00, 0x21, 0xff, 0x00, 0x00, 0x00, 0x3f, 0x00, 0x00,
0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
};
// 'POISSON02', 39x34px
const unsigned char epd_bitmap_POISSON02 [] PROGMEM = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x80, 0x00, 0x00, 0x00,
0x18, 0xc0, 0x00, 0x00, 0x00, 0x30, 0x60, 0x00, 0x00, 0x00, 0x61, 0xe0, 0x00, 0x00, 0x00, 0xcf,
0x3c, 0x00, 0x00, 0x00, 0xb8, 0x07, 0x00, 0x00, 0x00, 0xe0, 0x01, 0x80, 0x00, 0x01, 0x80, 0x00,
0xc0, 0x00, 0x03, 0x00, 0x00, 0x60, 0x03, 0xe2, 0x00, 0x00, 0x30, 0x02, 0x36, 0x00, 0x00, 0x10,
0x02, 0x1c, 0x00, 0x00, 0x18, 0x02, 0x0c, 0x00, 0x00, 0x08, 0x03, 0x00, 0x00, 0x00, 0x08, 0x01,
0x80, 0x00, 0x00, 0x08, 0x00, 0x80, 0x00, 0x00, 0x08, 0x01, 0x00, 0x00, 0x00, 0xe8, 0x03, 0x0c,
0x03, 0xc0, 0xc8, 0x02, 0x1c, 0x03, 0x0e, 0x68, 0x02, 0x36, 0x01, 0xc0, 0x08, 0x03, 0xe3, 0xc0,
0x00, 0x08, 0x00, 0x01, 0x80, 0x00, 0x18, 0x00, 0x03, 0x00, 0x00, 0x30, 0x00, 0x01, 0xee, 0x00,
0x60, 0x00, 0x00, 0x38, 0x83, 0xc0, 0x00, 0x00, 0x21, 0xff, 0x00, 0x00, 0x00, 0x3f, 0x00, 0x00,
0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
};
// 'POISSON04', 39x34px
const unsigned char epd_bitmap_POISSON04 [] PROGMEM = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x80, 0x00, 0x00, 0x00,
0x18, 0xc0, 0x00, 0x00, 0x00, 0x30, 0x60, 0x00, 0x00, 0x00, 0x61, 0xe0, 0x00, 0x00, 0x00, 0xcf,
0x3c, 0x00, 0x30, 0x00, 0xb8, 0x07, 0x00, 0x48, 0x00, 0xe0, 0x01, 0x80, 0x84, 0x01, 0x80, 0x00,
0xc0, 0x84, 0x03, 0x00, 0x00, 0x60, 0x4b, 0xe2, 0x00, 0x00, 0x30, 0x32, 0x36, 0x00, 0x00, 0x10,
0x02, 0x1c, 0x00, 0x00, 0x18, 0x12, 0x0c, 0x00, 0x00, 0x08, 0x2b, 0x00, 0x00, 0x00, 0x08, 0x29,
0x80, 0x01, 0xc0, 0x48, 0x10, 0x80, 0x03, 0x80, 0xe8, 0x01, 0x00, 0x03, 0xe0, 0xe8, 0x03, 0x0c,
0x03, 0xc0, 0xc8, 0x02, 0x1c, 0x03, 0x0e, 0x68, 0x02, 0x36, 0x01, 0xc6, 0x08, 0x03, 0xe3, 0xc0,
0x04, 0x08, 0x00, 0x01, 0x80, 0x00, 0x18, 0x04, 0x03, 0x00, 0x00, 0x30, 0x00, 0x01, 0xee, 0x00,
0x60, 0x00, 0x00, 0x38, 0x83, 0xc0, 0x00, 0x00, 0x21, 0xff, 0x00, 0x00, 0x00, 0x3f, 0x00, 0x00,
0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
};
// 'POISSON03', 39x34px
const unsigned char epd_bitmap_POISSON03 [] PROGMEM = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x80, 0x00, 0x00, 0x00,
0x18, 0xc0, 0x00, 0x00, 0x00, 0x30, 0x60, 0x00, 0x00, 0x00, 0x61, 0xe0, 0x00, 0x00, 0x00, 0xcf,
0x3c, 0x00, 0x00, 0x00, 0xb8, 0x07, 0x00, 0x00, 0x00, 0xe0, 0x01, 0x80, 0x00, 0x01, 0x80, 0x00,
0xc0, 0x00, 0x03, 0x00, 0x00, 0x60, 0x03, 0xe2, 0x00, 0x00, 0x30, 0x02, 0x36, 0x00, 0x00, 0x10,
0x02, 0x1c, 0x00, 0x00, 0x18, 0x02, 0x0c, 0x00, 0x00, 0x08, 0x03, 0x00, 0x00, 0x00, 0x08, 0x01,
0x80, 0x01, 0xc0, 0x48, 0x00, 0x80, 0x03, 0x80, 0xe8, 0x01, 0x00, 0x03, 0xe0, 0xe8, 0x03, 0x0c,
0x03, 0xc0, 0xc8, 0x02, 0x1c, 0x03, 0x0e, 0x68, 0x02, 0x36, 0x01, 0xc6, 0x08, 0x03, 0xe3, 0xc0,
0x04, 0x08, 0x00, 0x01, 0x80, 0x00, 0x18, 0x00, 0x8b, 0x00, 0x00, 0x30, 0x01, 0x41, 0xee, 0x00,
0x60, 0x02, 0x20, 0x38, 0x83, 0xc0, 0x01, 0x40, 0x21, 0xff, 0x00, 0x00, 0x80, 0x3f, 0x00, 0x00,
0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
};
// 'POISSON05', 39x34px
const unsigned char epd_bitmap_POISSON05 [] PROGMEM = {
0x80, 0x80, 0x00, 0x00, 0x00, 0x63, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x08,
0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x0f, 0x80, 0x00, 0x20, 0x00,
0x18, 0xc0, 0x00, 0x20, 0x00, 0x30, 0x60, 0x00, 0x20, 0x40, 0x61, 0xe0, 0x00, 0x40, 0x00, 0xcf,
0x3c, 0x00, 0x80, 0x00, 0xb8, 0x07, 0x00, 0x00, 0x00, 0xe0, 0x01, 0x80, 0x00, 0x01, 0x80, 0x00,
0xc0, 0x00, 0x03, 0x00, 0x00, 0x60, 0x03, 0xe2, 0x00, 0x00, 0x30, 0x02, 0x36, 0x00, 0x00, 0x10,
0x12, 0x1c, 0x00, 0x00, 0x18, 0x02, 0x0c, 0x00, 0x00, 0x08, 0x03, 0x00, 0x00, 0x00, 0x08, 0x01,
0x80, 0x01, 0xc0, 0x48, 0x00, 0x80, 0x03, 0x80, 0xe8, 0x01, 0x00, 0x03, 0xe0, 0xe8, 0x03, 0x0c,
0x03, 0xc0, 0xc8, 0x02, 0x1c, 0x03, 0x0e, 0x68, 0x02, 0x36, 0x01, 0xc6, 0x08, 0x03, 0xe3, 0xc0,
0x04, 0x08, 0x00, 0x01, 0x80, 0x00, 0x18, 0x00, 0x03, 0x00, 0x00, 0x30, 0x00, 0x01, 0xee, 0x00,
0x60, 0x00, 0x00, 0x38, 0x83, 0xc0, 0x00, 0x00, 0x21, 0xff, 0x00, 0x00, 0x00, 0x3f, 0x00, 0x00,
0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
};
// 'OISEAU01', 39x34px
const unsigned char epd_bitmap_OISEAU01 [] PROGMEM = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x78, 0x00, 0x00, 0x00, 0x00, 0x2f, 0xe0, 0x00, 0x00,
0x01, 0xe0, 0x38, 0x00, 0x00, 0x00, 0x80, 0x0e, 0x00, 0x00, 0x01, 0x80, 0x03, 0x00, 0x00, 0x03,
0x00, 0x01, 0x80, 0x00, 0x06, 0x00, 0x00, 0x80, 0x00, 0x04, 0x00, 0x00, 0x40, 0x00, 0x0c, 0x00,
0x00, 0x60, 0x00, 0x08, 0x00, 0x01, 0x20, 0x07, 0x08, 0x00, 0x01, 0xa0, 0x05, 0x98, 0x00, 0xce,
0x20, 0x04, 0xf0, 0x00, 0x49, 0x20, 0x06, 0x52, 0x00, 0x0b, 0x20, 0x03, 0x3e, 0x00, 0x04, 0x30,
0x03, 0x98, 0x01, 0x00, 0x38, 0x06, 0xf0, 0xc1, 0x00, 0x2c, 0x04, 0x31, 0x81, 0x80, 0x24, 0x06,
0x1e, 0x01, 0x80, 0x24, 0x03, 0xf9, 0x81, 0x80, 0x24, 0x00, 0x8e, 0x23, 0x00, 0x2c, 0x00, 0xd8,
0x66, 0x00, 0x78, 0x00, 0x7f, 0xfc, 0x00, 0xe0, 0x00, 0x18, 0x30, 0x01, 0x80, 0x00, 0x0c, 0x00,
0x03, 0x00, 0x00, 0x03, 0x00, 0x0e, 0x00, 0x00, 0x01, 0xc0, 0x38, 0x00, 0x00, 0x00, 0x7f, 0xe0,
0x00, 0x00, 0x00, 0x08, 0x80, 0x00, 0x00, 0x00, 0x0e, 0xe0, 0x00, 0x00, 0x00, 0x0a, 0xa0, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
};
// 'OISEAU03', 39x34px
const unsigned char epd_bitmap_OISEAU03 [] PROGMEM = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x78, 0x00, 0x00, 0x00, 0x00, 0x2f, 0xe0, 0x00, 0x00,
0x01, 0xe0, 0x38, 0x00, 0x00, 0x00, 0x80, 0x0e, 0x00, 0x00, 0x01, 0x80, 0x03, 0x00, 0x00, 0x03,
0x00, 0x01, 0x80, 0x00, 0x06, 0x00, 0x00, 0x80, 0x00, 0x04, 0x00, 0x00, 0x40, 0x00, 0x0c, 0x00,
0x00, 0x60, 0x00, 0x08, 0x00, 0x01, 0x20, 0x07, 0x08, 0x00, 0x01, 0xa0, 0x05, 0x98, 0x00, 0xce,
0x20, 0x04, 0xf0, 0x00, 0x49, 0x20, 0x06, 0x52, 0x00, 0x0b, 0x20, 0x03, 0x3e, 0x00, 0x04, 0x30,
0x03, 0x98, 0x01, 0x00, 0x38, 0x06, 0xf0, 0xc1, 0x00, 0x2c, 0x04, 0x31, 0x81, 0x80, 0x24, 0x06,
0x1e, 0x01, 0x80, 0x24, 0x03, 0xf9, 0x81, 0x80, 0x24, 0x00, 0x8e, 0x23, 0x00, 0x2c, 0x00, 0xd8,
0x66, 0x00, 0x78, 0x00, 0x7f, 0xfc, 0x00, 0xe0, 0x00, 0x18, 0x30, 0x01, 0x80, 0x00, 0x0c, 0x00,
0x03, 0x00, 0x00, 0x23, 0x00, 0x0e, 0x00, 0x01, 0x81, 0xc0, 0x38, 0x00, 0x00, 0x00, 0x7f, 0xe0,
0x00, 0x00, 0x40, 0x08, 0x80, 0x00, 0x00, 0x00, 0x0e, 0xe0, 0x00, 0x00, 0x00, 0x0a, 0xa0, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
};
// 'OISEAU04', 39x34px
const unsigned char epd_bitmap_OISEAU04 [] PROGMEM = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x78, 0x00, 0x00, 0x00, 0x00, 0x2f, 0xe0, 0x00, 0x00,
0x01, 0xe0, 0x38, 0x00, 0x00, 0x00, 0x80, 0x0e, 0x00, 0x00, 0x01, 0x80, 0x03, 0x00, 0x00, 0x03,
0x00, 0x01, 0x80, 0x00, 0x06, 0x00, 0x00, 0x80, 0x00, 0x04, 0x00, 0x00, 0x40, 0x00, 0x0c, 0x00,
0x00, 0x60, 0x00, 0x08, 0x00, 0x01, 0x20, 0x07, 0x08, 0x00, 0x01, 0xa0, 0x05, 0x98, 0x00, 0xce,
0x20, 0x04, 0xf0, 0x00, 0x49, 0x20, 0x06, 0x52, 0x00, 0x0b, 0x20, 0x03, 0x3e, 0x00, 0x04, 0x30,
0x03, 0x98, 0x01, 0x00, 0x38, 0x06, 0xf0, 0xc1, 0x00, 0x2c, 0x04, 0x31, 0x81, 0x80, 0x24, 0x06,
0x1e, 0x01, 0x80, 0x24, 0x03, 0xf9, 0x81, 0x80, 0x24, 0x00, 0x8e, 0x23, 0x00, 0x2c, 0x00, 0xd8,
0x66, 0x00, 0x78, 0x00, 0x7f, 0xfc, 0x00, 0xe0, 0x00, 0x18, 0x30, 0x01, 0x80, 0x00, 0x0c, 0x00,
0x03, 0x00, 0x28, 0x03, 0x00, 0x0e, 0x00, 0x10, 0x81, 0xc0, 0x38, 0x00, 0x01, 0x00, 0x7f, 0xe0,
0x00, 0x00, 0x00, 0x08, 0x80, 0x00, 0x00, 0x00, 0x0e, 0xe0, 0x00, 0x03, 0x00, 0x0a, 0xa0, 0x00,
0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
};
// 'OISEAU02', 39x34px
const unsigned char epd_bitmap_OISEAU02 [] PROGMEM = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x78, 0x00, 0x00, 0x00, 0x00, 0x2f, 0xe0, 0x00, 0x00,
0x01, 0xe0, 0x38, 0x00, 0x00, 0x00, 0x80, 0x0e, 0x00, 0x00, 0x01, 0x80, 0x03, 0x00, 0x00, 0x03,
0x00, 0x01, 0x80, 0x00, 0x06, 0x00, 0x00, 0x80, 0x00, 0x04, 0x00, 0x00, 0x40, 0x00, 0x0c, 0x00,
0x01, 0xe0, 0x00, 0x08, 0x00, 0x03, 0x20, 0x07, 0x08, 0x00, 0x60, 0x20, 0x05, 0x98, 0x00, 0xce,
0x20, 0x04, 0xf0, 0x00, 0x09, 0x20, 0x06, 0x52, 0x00, 0x0b, 0x20, 0x03, 0x3e, 0x00, 0x04, 0x30,
0x03, 0x98, 0x01, 0x00, 0x38, 0x06, 0xf0, 0xc1, 0x00, 0x2c, 0x04, 0x31, 0x81, 0x80, 0x24, 0x06,
0x1e, 0x01, 0x80, 0x24, 0x03, 0xf9, 0x81, 0x80, 0x24, 0x00, 0x8e, 0x23, 0x00, 0x2c, 0x00, 0xd8,
0x66, 0x00, 0x78, 0x00, 0x7f, 0xfc, 0x00, 0xe0, 0x00, 0x18, 0x30, 0x01, 0x80, 0x00, 0x0c, 0x00,
0x03, 0x00, 0x00, 0x03, 0x00, 0x0e, 0x00, 0x00, 0x01, 0xc0, 0x38, 0x00, 0x00, 0x00, 0x7f, 0xe0,
0x00, 0x00, 0x00, 0x08, 0x80, 0x00, 0x00, 0x00, 0x0e, 0xe0, 0x00, 0x00, 0x00, 0x0a, 0xa0, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
};
// 'LAPIN01', 39x34px
const unsigned char epd_bitmap_LAPIN01 [] PROGMEM = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7c, 0x00, 0x00, 0x00, 0x0c, 0xc6, 0x00, 0x00,
0x00, 0x1f, 0x82, 0x00, 0x00, 0x00, 0x21, 0x83, 0x00, 0x00, 0x00, 0x60, 0x81, 0x00, 0x00, 0x00,
0x40, 0xc1, 0x00, 0x00, 0x00, 0x40, 0x41, 0x00, 0x00, 0x00, 0x60, 0x41, 0x00, 0x00, 0x00, 0x20,
0x41, 0x00, 0x00, 0x00, 0x20, 0x71, 0x00, 0x00, 0x00, 0x10, 0x31, 0x80, 0x00, 0x00, 0x18, 0x00,
0xc0, 0x00, 0x00, 0x08, 0x00, 0x60, 0x00, 0x00, 0x0c, 0x00, 0x20, 0x00, 0x00, 0x08, 0x61, 0xb0,
0x00, 0x00, 0x18, 0x61, 0x98, 0x00, 0x00, 0x18, 0x04, 0x08, 0x00, 0x00, 0x10, 0x0e, 0x08, 0x00,
0x00, 0x10, 0x00, 0x08, 0x00, 0x00, 0x10, 0x00, 0x08, 0x00, 0x00, 0x18, 0x00, 0x18, 0x00, 0x00,
0x18, 0x00, 0x30, 0x00, 0x00, 0x30, 0x00, 0x20, 0x00, 0x00, 0x20, 0x00, 0x30, 0x00, 0x00, 0x20,
0x00, 0x10, 0x00, 0x00, 0x60, 0x00, 0x10, 0x00, 0x01, 0xe0, 0x00, 0x10, 0x00, 0x03, 0x60, 0x00,
0x10, 0x00, 0x03, 0x01, 0x84, 0x90, 0x00, 0x03, 0x01, 0xe4, 0x90, 0x00, 0x01, 0x80, 0x24, 0xd8,
0x00, 0x00, 0xff, 0xff, 0xf8, 0x00, 0x00, 0x00, 0x00, 0x00
};
// 'LAPIN02', 39x34px
const unsigned char epd_bitmap_LAPIN02 [] PROGMEM = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7c, 0x00, 0x00, 0x00, 0x0c, 0xc6, 0x00, 0x00,
0x00, 0x1f, 0x82, 0x00, 0x00, 0x00, 0x21, 0x83, 0x00, 0x00, 0x00, 0x60, 0x81, 0x00, 0x00, 0x00,
0x40, 0xc1, 0x00, 0x00, 0x00, 0x40, 0x41, 0x00, 0x00, 0x00, 0x60, 0x41, 0x00, 0x00, 0x00, 0x20,
0x41, 0x00, 0x00, 0x00, 0x20, 0x71, 0x00, 0x00, 0x00, 0x10, 0x31, 0x80, 0x00, 0x00, 0x18, 0x00,
0xc0, 0x00, 0x00, 0x08, 0x00, 0x60, 0x00, 0x00, 0x0c, 0x00, 0x20, 0x00, 0x00, 0x08, 0x00, 0x30,
0x00, 0x00, 0x18, 0x61, 0x98, 0x00, 0x00, 0x18, 0x04, 0x08, 0x00, 0x00, 0x10, 0x0a, 0x08, 0x00,
0x00, 0x10, 0x00, 0x08, 0x00, 0x00, 0x10, 0x00, 0x08, 0x00, 0x00, 0x18, 0x00, 0x18, 0x00, 0x00,
0x18, 0x00, 0x30, 0x00, 0x00, 0x30, 0x00, 0x20, 0x00, 0x00, 0x20, 0x00, 0x30, 0x00, 0x00, 0x20,
0x00, 0x10, 0x00, 0x00, 0x60, 0x00, 0x10, 0x00, 0x01, 0xe0, 0x00, 0x10, 0x00, 0x03, 0x60, 0x00,
0x10, 0x00, 0x03, 0x01, 0x84, 0x90, 0x00, 0x03, 0x01, 0xe4, 0x90, 0x00, 0x01, 0x80, 0x24, 0xd8,
0x00, 0x00, 0xff, 0xff, 0xf8, 0x00, 0x00, 0x00, 0x00, 0x00
};
// 'LAPIN03', 39x34px
const unsigned char epd_bitmap_LAPIN03 [] PROGMEM = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7c, 0x00, 0x00, 0x00, 0x0c, 0xc6, 0x00, 0x00,
0x00, 0x1f, 0x82, 0x00, 0x00, 0x00, 0x21, 0x83, 0x00, 0x00, 0x00, 0x60, 0x81, 0x00, 0x00, 0x00,
0x40, 0xc1, 0x00, 0x00, 0x00, 0x40, 0x41, 0x00, 0x00, 0x00, 0x60, 0x41, 0x00, 0x00, 0x00, 0x20,
0x41, 0x00, 0x00, 0x00, 0x20, 0x71, 0x00, 0x00, 0x00, 0x10, 0x31, 0x80, 0x00, 0x00, 0x18, 0x00,
0xc0, 0x00, 0x00, 0x08, 0x00, 0x60, 0x00, 0x00, 0x0c, 0x00, 0x20, 0x00, 0x00, 0x08, 0x61, 0xb0,
0x00, 0x00, 0x18, 0x61, 0x98, 0x00, 0x00, 0x18, 0x04, 0x08, 0x00, 0x00, 0x10, 0x0e, 0x08, 0x00,
0x00, 0x10, 0x00, 0x08, 0x00, 0x00, 0x10, 0x00, 0x08, 0x00, 0x00, 0x18, 0x00, 0x18, 0x00, 0x00,
0x18, 0x00, 0x30, 0x00, 0x00, 0x30, 0x00, 0x20, 0x00, 0x00, 0x20, 0x00, 0x30, 0x00, 0x00, 0x20,
0x00, 0x10, 0x00, 0x00, 0x60, 0x00, 0x10, 0x00, 0x21, 0xe0, 0x00, 0x10, 0x00, 0x03, 0x60, 0x00,
0x10, 0x00, 0x3b, 0x01, 0x84, 0x90, 0x00, 0x03, 0x01, 0xe4, 0x90, 0x00, 0x01, 0x80, 0x24, 0xd8,
0x00, 0x00, 0xff, 0xff, 0xf8, 0x00, 0x00, 0x00, 0x00, 0x00
};
// 'LAPIN04', 39x34px
const unsigned char epd_bitmap_LAPIN04 [] PROGMEM = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7c, 0x00, 0x00, 0x00, 0x0c, 0xc6, 0x00, 0x00,
0x00, 0x1f, 0x82, 0x00, 0x00, 0x00, 0x21, 0x83, 0x00, 0x00, 0x00, 0x60, 0x81, 0x00, 0x00, 0x00,
0x40, 0xc1, 0x00, 0x00, 0x00, 0x40, 0x41, 0x00, 0x00, 0x00, 0x60, 0x41, 0x00, 0x00, 0x00, 0x20,
0x41, 0x00, 0x00, 0x00, 0x20, 0x71, 0x00, 0x00, 0x00, 0x10, 0x31, 0x80, 0x00, 0x00, 0x18, 0x00,
0xc0, 0x00, 0x00, 0x08, 0x00, 0x60, 0x00, 0x00, 0x0c, 0x00, 0x20, 0x00, 0x00, 0x08, 0x61, 0xb0,
0x00, 0x00, 0x18, 0x61, 0x98, 0x00, 0x00, 0x18, 0x04, 0x08, 0x00, 0x00, 0x10, 0x0e, 0x08, 0x00,
0x00, 0x10, 0x00, 0x08, 0x08, 0x00, 0x10, 0x00, 0x08, 0x0c, 0x00, 0x18, 0x00, 0x18, 0x05, 0x00,
0x18, 0x00, 0x30, 0x00, 0x80, 0x30, 0x00, 0x20, 0x01, 0x00, 0x20, 0x00, 0x30, 0x01, 0x00, 0x20,
0x00, 0x10, 0x00, 0x00, 0x60, 0x00, 0x10, 0x00, 0x01, 0xe0, 0x00, 0x10, 0x00, 0x03, 0x60, 0x00,
0x10, 0x00, 0x03, 0x01, 0x84, 0x90, 0x00, 0x03, 0x01, 0xe4, 0x90, 0x00, 0x01, 0x80, 0x24, 0xd8,
0x00, 0x00, 0xff, 0xff, 0xf8, 0x00, 0x00, 0x00, 0x00, 0x00
};
// 'LAPIN05', 39x34px
const unsigned char epd_bitmap_LAPIN05 [] PROGMEM = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x7c, 0x00, 0x00, 0x10, 0x0c, 0xc6, 0x00, 0x00,
0x20, 0x1f, 0x82, 0x00, 0x00, 0x00, 0x21, 0x83, 0x00, 0x00, 0x00, 0x60, 0x81, 0x00, 0x00, 0x00,
0x40, 0xc1, 0x00, 0x10, 0x00, 0x40, 0x41, 0x00, 0x08, 0x00, 0x60, 0x41, 0x00, 0x00, 0x00, 0x20,
0x41, 0x00, 0x00, 0x00, 0x20, 0x71, 0x00, 0x00, 0x00, 0x10, 0x31, 0x80, 0x08, 0x00, 0x18, 0x00,
0xc0, 0x00, 0x80, 0x08, 0x00, 0x60, 0x00, 0x00, 0x0c, 0x00, 0x20, 0x00, 0x80, 0x08, 0x61, 0xb0,
0x00, 0x80, 0x18, 0x61, 0x98, 0x01, 0x00, 0x18, 0x04, 0x08, 0x01, 0x00, 0x10, 0x0e, 0x08, 0x00,
0x00, 0x10, 0x00, 0x08, 0x00, 0x00, 0x10, 0x00, 0x08, 0x00, 0x00, 0x18, 0x00, 0x18, 0x00, 0x00,
0x18, 0x00, 0x30, 0x00, 0x00, 0x30, 0x00, 0x20, 0x00, 0x00, 0x20, 0x00, 0x30, 0x00, 0x00, 0x20,
0x00, 0x10, 0x00, 0x00, 0x60, 0x00, 0x10, 0x00, 0x01, 0xe0, 0x00, 0x10, 0x00, 0x03, 0x60, 0x00,
0x10, 0x00, 0x03, 0x01, 0x84, 0x90, 0x00, 0x03, 0x01, 0xe4, 0x90, 0x00, 0x01, 0x80, 0x24, 0xd8,
0x00, 0x00, 0xff, 0xff, 0xf8, 0x00, 0x00, 0x00, 0x00, 0x00
};
// 'DRAGON01', 39x34px
const unsigned char epd_bitmap_DRAGON01 [] PROGMEM = {
0xff, 0xff, 0xff, 0xff, 0xfe, 0xff, 0xdf, 0xf3, 0x3f, 0xfe, 0xff, 0xcf, 0xf5, 0x5f, 0xfa, 0xff,
0xd7, 0xf6, 0xdf, 0xf2, 0xff, 0xdb, 0xf7, 0xef, 0xea, 0xff, 0xdc, 0xe0, 0xe3, 0xca, 0xff, 0xee,
0x4f, 0x6c, 0x9a, 0xff, 0xef, 0x9f, 0xb6, 0x32, 0xff, 0xf7, 0xcf, 0xcf, 0x36, 0xff, 0xfb, 0xef,
0xff, 0xa6, 0xff, 0xfd, 0xef, 0xff, 0x8e, 0xff, 0xfe, 0x1c, 0xfe, 0xde, 0xff, 0xff, 0x70, 0x7c,
0x5e, 0xff, 0xfe, 0x72, 0x3a, 0x1e, 0xff, 0xfe, 0xf2, 0x3a, 0x5e, 0xfe, 0xfe, 0xf0, 0x38, 0x5e,
0xfe, 0x1e, 0xf8, 0x3c, 0x5e, 0xff, 0x0e, 0x7c, 0x7e, 0xde, 0xff, 0xcf, 0x7f, 0xe3, 0xde, 0xff,
0xcf, 0xbf, 0xf7, 0x9e, 0xff, 0xcf, 0xdf, 0xff, 0xbe, 0xff, 0xaf, 0xcf, 0xfe, 0x7e, 0xff, 0x2f,
0xe0, 0x00, 0xfe, 0xff, 0x5f, 0xfd, 0xb7, 0xfe, 0xfe, 0x5f, 0xfb, 0xbb, 0xfe, 0xfe, 0xcf, 0xe3,
0xdc, 0x7e, 0xfe, 0xe7, 0xc0, 0xed, 0x8e, 0xff, 0x70, 0x1e, 0x65, 0xe6, 0xff, 0x7f, 0xbf, 0x01,
0xf6, 0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 0xff, 0xf1, 0x9f, 0xb0, 0xce,
0xff, 0xfc, 0x00, 0x06, 0x1e, 0xff, 0xff, 0xff, 0xff, 0xfe
};
// 'MORT01', 39x34px
const unsigned char epd_bitmap_MORT01 [] PROGMEM = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x03, 0xff, 0x00, 0x00, 0x00, 0x0f, 0xff, 0xc0, 0x00, 0x00, 0x0f, 0xfe, 0x70, 0x00, 0x00, 0x1f,
0xff, 0x18, 0x00, 0x00, 0x1f, 0xff, 0xd8, 0x00, 0x00, 0x3f, 0xff, 0xd8, 0x00, 0x00, 0x30, 0xff,
0xd8, 0x00, 0x00, 0x36, 0xd0, 0xd8, 0x00, 0x00, 0x36, 0xd6, 0x58, 0x00, 0x00, 0x30, 0xd6, 0x58,
0x00, 0x00, 0x35, 0xd0, 0xd8, 0x00, 0x00, 0x35, 0xd7, 0xd8, 0x00, 0x00, 0x34, 0xd7, 0xd8, 0x00,
0x00, 0x3f, 0xd7, 0xd8, 0x00, 0x00, 0x3f, 0xf7, 0xd8, 0x00, 0x00, 0x3f, 0xff, 0xd8, 0x00, 0x00,
0x3f, 0xff, 0xd8, 0x00, 0x00, 0x3f, 0xff, 0xd8, 0x48, 0x80, 0xbf, 0xff, 0xd8, 0x4a, 0xa2, 0xbf,
0xff, 0xda, 0x5b, 0xb7, 0xbf, 0xff, 0xfa, 0x79, 0xbf, 0xff, 0xff, 0xfe, 0xff, 0xff, 0xff, 0xff,
0xfe, 0xff, 0xff, 0xff, 0xff, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xfe,
0xff, 0xff, 0xff, 0xff, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xfe
};
// 'MORT02', 39x34px
const unsigned char epd_bitmap_MORT02 [] PROGMEM = {
0xff, 0xff, 0xff, 0xff, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xfe, 0xff,
0xff, 0xff, 0xff, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xfe, 0xff, 0xff,
0xfc, 0x00, 0xfe, 0xff, 0xff, 0xf0, 0x00, 0x3e, 0xff, 0xff, 0xf0, 0x01, 0x8e, 0xff, 0xff, 0xe0,
0x00, 0xe6, 0xff, 0xff, 0xe0, 0x00, 0x26, 0xff, 0xff, 0xc0, 0x00, 0x26, 0xff, 0xff, 0xcf, 0x00,
0x26, 0xff, 0xff, 0xc9, 0x2f, 0x26, 0xff, 0xff, 0xc9, 0x29, 0xa6, 0xff, 0xff, 0xcf, 0x29, 0xa6,
0xff, 0xff, 0xca, 0x2f, 0x26, 0xff, 0xff, 0xca, 0x28, 0x26, 0xff, 0xff, 0xcb, 0x28, 0x26, 0xff,
0xff, 0xc0, 0x28, 0x26, 0xff, 0xff, 0xc0, 0x08, 0x26, 0xff, 0xff, 0xc0, 0x00, 0x26, 0xff, 0xff,
0xc0, 0x00, 0x26, 0xff, 0xff, 0xc0, 0x00, 0x26, 0xb7, 0x7f, 0x40, 0x00, 0x26, 0xb5, 0x5d, 0x40,
0x00, 0x24, 0xa4, 0x48, 0x40, 0x00, 0x04, 0x86, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
};
void setup() {
// inversion des couleur à l'écran
display.invertDisplay(true);
// Allumage du rétroéclairage de l'écran
pinMode(broche_LED, OUTPUT);
digitalWrite(broche_LED, HIGH);
Serial.begin(9600);
//Initialisation de l'écran Display
display.begin();
// 57 valeur de base du contraste ok
display.setContrast(57);
// Rafraichissement de l'écran
display.clearDisplay();
display.invertDisplay(true);//false pour écran normal fond blanc + dessin noir
// ANIMATION INTRO
for (int i = 48 ; i > 14 ; i--) {
display.clearDisplay();
display.setTextSize(1);
display.setCursor(4,i);
display.print("PROUT-O-METRE");
display.drawRoundRect(0, i+9, 84, 1, 0, 1);
display.setTextSize(1);
display.setCursor(7,i+12);
display.print("made for all");
display.display();// Validation affichage
delay(50);
}
// Lecture des deux notes à la fin de l'animation INTRO
tone(buzzer, NOTE_A, 200);
delay(220);
tone(buzzer, NOTE_A, 100);
delay(110);
tone(buzzer, NOTE_A, 100);
delay(1000);
display.clearDisplay();
display.display();// Validation affichage
delay(500);
// Correction : inversion couleur écran
display.invertDisplay(false);//false pour écran normal fond blanc + dessin noir
//Affichage des cadres
display.drawRoundRect(0, 0, 84, 11, 0, 1); // cadre haut (positionX, positionY, largeur, hauteur, chanfrein, epaisseur)
display.drawRoundRect(0, 12, 41, 36, 0, 1); // cadre gauche (positionX, positionY, largeur, hauteur, chanfrein, epaisseur)
display.drawRoundRect(43, 12, 41, 36, 0, 1); //cadre droit (positionX, positionY, largeur, hauteur, chanfrein, epaisseur)
display.display(); // Validation affichage
}
void loop() {
//SCORE ECRIT
mesure = analogRead(A0); // définition de la valeur "mesure" = sortie port A0
Serial.println(mesure); // ?
display.setTextSize(2);
display.setCursor(46,32); // Position du curseur pour écriture "mesure"
display.fillRect(46, 32, 36, 15, 0); //Effacement avant écriture valeur de mesure (posX,posY,largX,htY,noir ou blanc)
display.print(mesure); // Ecriture mesure
display.display();
delay(1000);
if (mesure < 100 ) {
// NIVEAU 01
//TEXTE CADRE TITRE
display.setTextSize(1);
display.setCursor(2,2);
display.fillRect(1, 1, 82, 9, 0);//Recouvrement commentaire cadre haut (0=blanc,1=noir)
//display.print("1234567891234");
display.print("Petite brise");
display.display(); // Validation affichage
display.fillRect(46, 14, 36, 15, 0);//Recouvrement score barre (posX,posY,largX,htY,noir ou blanc)
display.fillRect(46, 26, 5, 3, 1);// Barre niveau 01 colorée
display.drawRoundRect(52, 23, 5, 6, 0, 1); // Barre niveau 02
display.drawRoundRect(58, 20, 5, 9, 0, 1); // Barre niveau 03
display.drawRoundRect(64, 17, 5, 12, 0, 1); // Barre niveau 04
display.drawRoundRect(70, 16, 5, 13, 0, 1); // Barre niveau 05
display.drawRoundRect(76, 14, 5, 15, 0, 1); // Barre niveau 06
display.display(); // Validation affichage
// Affichage animation POISSSON
display.fillRect(1, 13, 39, 34, 0);//Recouvrement animation (0=blanc,1=noir)
display.drawBitmap(1, 13, epd_bitmap_POISSON01, 39, 34, 1);
display.display();
delay(1000);
display.fillRect(1, 13, 39, 34, 0);//Recouvrement animation (0=blanc,1=noir)
display.drawBitmap(1, 13, epd_bitmap_POISSON02, 39, 34, 1);
display.display();
delay(300);
display.fillRect(1, 13, 39, 34, 0);//Recouvrement animation (0=blanc,1=noir)
display.drawBitmap(1, 13, epd_bitmap_POISSON03, 39, 34, 1);
display.display();
delay(300);
display.fillRect(1, 13, 39, 34, 0);//Recouvrement animation (0=blanc,1=noir)
display.drawBitmap(1, 13, epd_bitmap_POISSON04, 39, 34, 1);
display.display();
delay(300);
display.fillRect(1, 13, 39, 34, 0);//Recouvrement animation (0=blanc,1=noir)
display.drawBitmap(1, 13, epd_bitmap_POISSON05, 39, 34, 1);
display.display();
delay(300);
}
else
if (mesure < 200 ) {
// NIVEAU 02
//TEXTE CADRE TITRE
display.setTextSize(1);
display.setCursor(2,2);
display.fillRect(1, 1, 82, 9, 0);
display.print("Faut ventiler");
display.display(); // Validation affichage
display.fillRect(46, 14, 36, 15, 0);//Effacement avant écriture score barre (posX,posY,largX,htY,noir ou blanc)
display.fillRect(46, 26, 5, 3, 1);// Barre niveau 01 colorée
display.fillRect(52, 23, 5, 6, 1);// Barre niveau 02 colorée
display.drawRoundRect(58, 20, 5, 9, 0, 1); // Barre niveau 03
display.drawRoundRect(64, 17, 5, 12, 0, 1); // Barre niveau 04
display.drawRoundRect(70, 16, 5, 13, 0, 1); // Barre niveau 05
display.drawRoundRect(76, 14, 5, 15, 0, 1); // Barre niveau 06
display.display(); // Validation affichage
// Affichage animation OISEAU
display.fillRect(1, 13, 39, 34, 0);//Recouvrement animation (0=blanc,1=noir)
display.drawBitmap(1, 13, epd_bitmap_OISEAU01, 39, 34, 1);
display.display();
delay(1000);
display.fillRect(1, 13, 39, 34, 0);//Recouvrement animation (0=blanc,1=noir)
display.drawBitmap(1, 13, epd_bitmap_OISEAU02, 39, 34, 1);
display.display();
delay(300);
display.fillRect(1, 13, 39, 34, 0);//Recouvrement animation (0=blanc,1=noir)
display.drawBitmap(1, 13, epd_bitmap_OISEAU03, 39, 34, 1);
display.display();
delay(300);
display.fillRect(1, 13, 39, 34, 0);//Recouvrement animation (0=blanc,1=noir)
display.drawBitmap(1, 13, epd_bitmap_OISEAU04, 39, 34, 1);
display.display();
delay(300);
}
else
if (mesure < 300 ) {
// NIVEAU 03
//TEXTE CADRE TITRE
display.setTextSize(1);
display.setCursor(2,2);
display.fillRect(1, 1, 82, 9, 0);
display.print("Sage puanteur");
display.display(); // Validation affichage
display.fillRect(46, 14, 36, 15, 0);//Effacement avant écriture score barre (posX,posY,largX,htY,noir ou blanc)
display.fillRect(46, 26, 5, 3, 1);// Barre niveau 01 colorée
display.fillRect(52, 23, 5, 6, 1);// Barre niveau 02 colorée
display.fillRect(58, 20, 5, 9, 1);// Barre niveau 03 colorée
display.drawRoundRect(64, 17, 5, 12, 0, 1); // Barre niveau 04
display.drawRoundRect(70, 16, 5, 13, 0, 1); // Barre niveau 05
display.drawRoundRect(76, 14, 5, 15, 0, 1); // Barre niveau 06
display.display(); // Validation affichage
// Affichage animation LAPIN
display.fillRect(1, 13, 39, 34, 0);//Recouvrement animation (0=blanc,1=noir)
display.drawBitmap(1, 13, epd_bitmap_LAPIN01, 39, 34, 1);
display.display();
delay(1000);
display.fillRect(1, 13, 39, 34, 0);//Recouvrement animation (0=blanc,1=noir)
display.drawBitmap(1, 13, epd_bitmap_LAPIN02, 39, 34, 1);
display.display();
delay(300);
display.fillRect(1, 13, 39, 34, 0);//Recouvrement animation (0=blanc,1=noir)
display.drawBitmap(1, 13, epd_bitmap_LAPIN03, 39, 34, 1);
display.display();
delay(300);
display.fillRect(1, 13, 39, 34, 0);//Recouvrement animation (0=blanc,1=noir)
display.drawBitmap(1, 13, epd_bitmap_LAPIN04, 39, 34, 1);
display.display();
delay(300);
display.fillRect(1, 13, 39, 34, 0);//Recouvrement animation (0=blanc,1=noir)
display.drawBitmap(1, 13, epd_bitmap_LAPIN05, 39, 34, 1);
display.display();
delay(300);
}
else
if (mesure < 400 ) {
// NIVEAU 04
//TEXTE CADRE TITRE
display.setTextSize(1);
display.setCursor(2,2);
display.fillRect(1, 1, 82, 9, 0);
display.print("Puanteur max");
display.display(); // Validation affichage
display.fillRect(46, 14, 36, 15, 0);//Effacement avant écriture score barre (posX,posY,largX,htY,noir ou blanc)
display.fillRect(46, 26, 5, 3, 1);// Barre niveau 01 coloré
display.fillRect(52, 23, 5, 6, 1);// Barre niveau 02 coloré
display.fillRect(58, 20, 5, 9, 1);// Barre niveau 03 coloré
display.fillRect(64, 17, 5, 12, 1);// Barre niveau 04 coloré
display.drawRoundRect(70, 16, 5, 13, 0, 1); // Barre niveau 05
display.drawRoundRect(76, 14, 5, 15, 0, 1); // Barre niveau 06
display.display(); // Validation affichage
}
else
if (mesure < 500 ) {
// NIVEAU 05
//TEXTE CADRE TITRE
display.setTextSize(1);
display.setCursor(2,2);
display.fillRect(1, 1, 82, 9, 0);
display.print("Puanteur max");
display.display(); // Validation affichage
display.fillRect(46, 14, 36, 15, 0);//Effacement avant écriture score barre (posX,posY,largX,htY,noir ou blanc)
display.fillRect(46, 26, 5, 3, 1);// Barre niveau 01 coloré
display.fillRect(52, 23, 5, 6, 1);// Barre niveau 02 coloré
display.fillRect(58, 20, 5, 9, 1);// Barre niveau 03 coloré
display.fillRect(64, 17, 5, 12, 1);// Barre niveau 04 coloré
display.fillRect(70, 16, 5, 13, 1);// Barre niveau 05 coloré
display.drawRoundRect(76, 14, 5, 15, 0, 1); // Barre niveau 06
display.display(); // Validation affichage
// Affichage animation DRAGON
display.fillRect(1, 13, 39, 34, 0);//Recouvrement animation (0=blanc,1=noir)
display.drawBitmap(1, 13, epd_bitmap_DRAGON01, 39, 34, 1);
display.display();
delay(1000);
display.fillRect(1, 13, 39, 34, 0);//Recouvrement animation (0=blanc,1=noir)
display.drawBitmap(1, 13, epd_bitmap_DRAGON02, 39, 34, 1);
display.display();
delay(300);
display.fillRect(1, 13, 39, 34, 0);//Recouvrement animation (0=blanc,1=noir)
display.drawBitmap(1, 13, epd_bitmap_DRAGON03, 39, 34, 1);
display.display();
delay(300);
display.fillRect(1, 13, 39, 34, 0);//Recouvrement animation (0=blanc,1=noir)
display.drawBitmap(1, 13, epd_bitmap_DRAGON04, 39, 34, 1);
display.display();
delay(300);
display.fillRect(1, 13, 39, 34, 0);//Recouvrement animation (0=blanc,1=noir)
display.drawBitmap(1, 13, epd_bitmap_DRAGON05, 39, 34, 1);
display.display();
delay(300);
}
else {
// NIVEAU 06
//TEXTE CADRE TITRE
display.setTextSize(1);
display.setCursor(2,2);
display.fillRect(1, 1, 82, 9, 0);
display.print("Cadavre moisi");
display.display(); // Validation affichage
display.fillRect(46, 14, 36, 15, 0);//Effacement avant écriture score barre (posX,posY,largX,htY,noir ou blanc)
display.fillRect(46, 26, 5, 3, 1);// Barre niveau 01 coloré
display.fillRect(52, 23, 5, 6, 1);// Barre niveau 02 coloré
display.fillRect(58, 20, 5, 9, 1);// Barre niveau 03 coloré
display.fillRect(64, 17, 5, 12, 1);// Barre niveau 04 coloré
display.fillRect(70, 16, 5, 13, 1);// Barre niveau 05 coloré
display.fillRect(76, 14, 5, 15, 1);// Barre niveau 06 coloré
display.display(); // Validation affichage
// Affichage animation MORT
display.fillRect(1, 13, 39, 34, 0);//Recouvrement animation (0=blanc,1=noir)
display.drawBitmap(1, 13, epd_bitmap_MORT01, 39, 34, 1);
display.display();
delay(1000);
display.fillRect(1, 13, 39, 34, 0);//Recouvrement animation (0=blanc,1=noir)
display.drawBitmap(1, 13, epd_bitmap_MORT02, 39, 34, 1);
display.display();
delay(100);
display.fillRect(1, 13, 39, 34, 0);//Recouvrement animation (0=blanc,1=noir)
display.drawBitmap(1, 13, epd_bitmap_MORT01, 39, 34, 1);
display.display();
delay(300);
display.fillRect(1, 13, 39, 34, 0);//Recouvrement animation (0=blanc,1=noir)
display.drawBitmap(1, 13, epd_bitmap_MORT02, 39, 34, 1);
display.display();
delay(100);
display.fillRect(1, 13, 39, 34, 0);//Recouvrement animation (0=blanc,1=noir)
display.drawBitmap(1, 13, epd_bitmap_MORT01, 39, 34, 1);
display.display();
delay(300);
}
}
Je pense devoir modifier le chapitre "//SCORE ECRIT" mais pour le moment je n'ai rien trouvé de probant.
Et voici une animation de l'écran :