Hi
i am using with blynk app: arduino mega2560 and hc-05 Bluetooth module
in blynk app, I used three buttons to call functions and they have Serial.print for each one…
the problem is that one button ( in V2 ) when i press it the program stops and it keeps giving serial.print minus a letter every time something like:
printing
printin
printi
print
prin
.
.
also it keeps looping and printing from the other buttons functions!!!
until the program crushed
please help i am not sure is it blynk code problem or my arduino.
my code:
#include <BlynkSimpleSerialBLE.h>
#include <SoftwareSerial.h>
#include "RTClib.h"
#include "Adafruit_SSD1306.h"
#include <Adafruit_GFX.h>
#include <EEPROM.h>
#define BLYNK_PRINT Serial
const int DATA_SIZE= 30;
// OLED display TWI address
#define SCREEN_WIDTH 128 // OLED display width, in pixels
#define SCREEN_HEIGHT 64 // OLED display height, in pixels
// Declaration for SSD1306 display connected using software SPI (default case):
#define OLED_MOSI 24
#define OLED_CLK 22
#define OLED_DC 28
#define OLED_CS 30
#define OLED_RESET 26
Adafruit_SSD1306 display(SCREEN_WIDTH, SCREEN_HEIGHT,
OLED_MOSI, OLED_CLK, OLED_DC, OLED_RESET, OLED_CS);
char auth[] = "";
SoftwareSerial SerialBLE(10, 11); // RX, TX
WidgetTable table;
BLYNK_ATTACH_WIDGET(table, V0);
int rowIndex = 0;
RTC_DS3231 rtc;
char daysOfTheWeek[7][12] = {"Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"};
double nowSecond;
double nowMinute;
double nowHour;
String dateText = "";
String timeText = "";
double settingTime;
String setTimerText;
// defines pins numbers
const int trigPin1 = 4;
const int echoPin1 = 5;
const int trigPin2 = 6;
const int echoPin2 = 7;
const int trigPin3 = 8;
const int echoPin3 = 9;
const int buzzerPin = 10;
// defines variables
double duration1;
double duration2;
double duration3;
double distance1;
double distance2;
double distance3;
double distance1_Limit = 50;
double distance2_Limit = 50;
double distance3_Limit = 50;
double distance1To2;
double distance1To3;
double distance2To3;
double distanceLimit1To2 = 2;
double distanceLimit1To3 = 2;
double distanceLimit2To3 = 2;
int healthySit = -1;
int eeAddress = 0;
int settingTrigger = 0;
double settingTimerStartHour = 0;
double settingTimerStartSecond = 0;
int settingTimerHourDisplay = 0;
int settingTimerMinuteDisplay = 0;
int settingTimerSecondDisplay = 0;
int settingDay;
double settingTimer = 0;
double settingTimerSecond = 0;
double settingTimeLimit_seconds = 10;
double settingTimeLimit_minutes = 0;
double settingTimeLimit_hours = 0;
double settingTimeLimit;
double noOneSetTime_seconds = 7;
int loopSecond;
int recordSit = 0;
const unsigned char sleeping[] PROGMEM = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0xf0, 0x00, 0x00, 0x38, 0x1c, 0x00,
0x00, 0xc0, 0x03, 0x7c, 0x01, 0x00, 0x1e, 0x88, 0x02, 0x03, 0x84, 0x70, 0x04, 0x01, 0x88, 0x60,
0x08, 0x03, 0xde, 0x7c, 0x08, 0x00, 0x00, 0x10, 0x10, 0x00, 0x00, 0x08, 0x10, 0x00, 0x00, 0x08,
0x30, 0x48, 0x12, 0x0c, 0x20, 0x38, 0x1c, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04,
0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x30, 0x00, 0x70, 0x0c,
0x10, 0x00, 0x88, 0x08, 0x10, 0x00, 0x88, 0x08, 0x08, 0x00, 0x70, 0x10, 0x08, 0x00, 0x00, 0x10,
0x04, 0x00, 0x00, 0x20, 0x02, 0x00, 0x00, 0x40, 0x01, 0x00, 0x00, 0x80, 0x00, 0xc0, 0x03, 0x00,
0x00, 0x38, 0x1c, 0x00, 0x00, 0x0f, 0xf0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
const unsigned char wink[] 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,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x0f, 0xf0, 0x00, 0x00, 0x00, 0x00, 0x78, 0x1e, 0x00, 0x00, 0x00, 0x01, 0xc0, 0x03,
0x80, 0x00, 0x00, 0x03, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x06, 0x00, 0x00, 0x60, 0x00, 0x00, 0x0c,
0x00, 0x00, 0x30, 0x00, 0x00, 0x18, 0x00, 0x00, 0x18, 0x00, 0x00, 0x30, 0x00, 0x00, 0x0c, 0x00,
0x00, 0x20, 0x30, 0x00, 0x04, 0x00, 0x00, 0x60, 0x78, 0x04, 0x06, 0x00, 0x00, 0x40, 0xfc, 0x1f,
0x02, 0x00, 0x00, 0x40, 0xfc, 0x31, 0x82, 0x00, 0x00, 0xc0, 0xf8, 0x20, 0x83, 0x00, 0x00, 0x80,
0x78, 0x00, 0x01, 0x00, 0x00, 0x80, 0x00, 0x00, 0x01, 0x00, 0x00, 0x80, 0x00, 0x00, 0x01, 0x00,
0x00, 0x80, 0x00, 0x00, 0x01, 0x00, 0x00, 0x80, 0x00, 0x00, 0x01, 0x00, 0x00, 0x80, 0x00, 0x00,
0x01, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x03, 0x00, 0x00, 0x40, 0xf8, 0x1f, 0x02, 0x00, 0x00, 0x40,
0x7f, 0xfe, 0x02, 0x00, 0x00, 0x60, 0x7f, 0xfe, 0x06, 0x00, 0x00, 0x20, 0x3f, 0xfc, 0x04, 0x00,
0x00, 0x30, 0x3f, 0xfc, 0x0c, 0x00, 0x00, 0x18, 0x0f, 0xf0, 0x18, 0x00, 0x00, 0x0c, 0x07, 0xe0,
0x30, 0x00, 0x00, 0x06, 0x00, 0x00, 0x60, 0x00, 0x00, 0x03, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x01,
0xc0, 0x03, 0x80, 0x00, 0x00, 0x00, 0x78, 0x1e, 0x00, 0x00, 0x00, 0x00, 0x0f, 0xf0, 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, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
const unsigned char angry[] 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,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x0f, 0xf0, 0x00, 0x00, 0x00, 0x00, 0x78, 0x1e, 0x00, 0x00, 0x00, 0x01, 0xc0, 0x03,
0x80, 0x00, 0x00, 0x03, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x06, 0x00, 0x00, 0x60, 0x00, 0x00, 0x0c,
0x00, 0x00, 0x30, 0x00, 0x00, 0x18, 0x80, 0x01, 0x18, 0x00, 0x00, 0x30, 0xe0, 0x07, 0x0c, 0x00,
0x00, 0x20, 0x30, 0x0c, 0x04, 0x00, 0x00, 0x60, 0x18, 0x18, 0x06, 0x00, 0x00, 0x40, 0x08, 0x10,
0x02, 0x00, 0x00, 0x40, 0xf0, 0x0f, 0x02, 0x00, 0x00, 0xc1, 0xf8, 0x1f, 0x83, 0x00, 0x00, 0x81,
0xf8, 0x1f, 0x81, 0x00, 0x00, 0x81, 0xf8, 0x1f, 0x81, 0x00, 0x00, 0x80, 0xf0, 0x0f, 0x01, 0x00,
0x00, 0x80, 0x60, 0x06, 0x01, 0x00, 0x00, 0x80, 0x00, 0x00, 0x01, 0x00, 0x00, 0x80, 0x00, 0x00,
0x01, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x03, 0x00, 0x00, 0x40, 0x00, 0x00, 0x02, 0x00, 0x00, 0x40,
0x0f, 0xf0, 0x02, 0x00, 0x00, 0x60, 0x38, 0x1c, 0x06, 0x00, 0x00, 0x20, 0x60, 0x06, 0x04, 0x00,
0x00, 0x30, 0xc0, 0x03, 0x0c, 0x00, 0x00, 0x18, 0x80, 0x01, 0x18, 0x00, 0x00, 0x0c, 0x00, 0x00,
0x30, 0x00, 0x00, 0x06, 0x00, 0x00, 0x60, 0x00, 0x00, 0x03, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x01,
0xc0, 0x03, 0x80, 0x00, 0x00, 0x00, 0x78, 0x1e, 0x00, 0x00, 0x00, 0x00, 0x0f, 0xf0, 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, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
const unsigned char skull[] PROGMEM = {
0x00, 0x07, 0xf0, 0x00, 0x00, 0x30, 0x0c, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x01, 0x80, 0x01, 0x80,
0x03, 0x00, 0x00, 0xc0, 0x02, 0x00, 0x00, 0x40, 0x04, 0x00, 0x00, 0x20, 0x04, 0x00, 0x00, 0x20,
0x00, 0x00, 0x00, 0x10, 0x08, 0x04, 0x30, 0x10, 0x08, 0x72, 0x4e, 0x10, 0x08, 0x82, 0x41, 0x10,
0x08, 0x82, 0x41, 0x10, 0x08, 0x82, 0x41, 0x10, 0x08, 0x86, 0x61, 0x10, 0x0a, 0x6c, 0x32, 0x10,
0x06, 0x01, 0x80, 0x50, 0x06, 0x01, 0x80, 0x60, 0x02, 0x22, 0x40, 0x40, 0x02, 0x61, 0x86, 0x40,
0x03, 0xe0, 0x07, 0xc0, 0x00, 0xa0, 0x05, 0x00, 0x00, 0xbf, 0xfd, 0x00, 0x00, 0xa0, 0x05, 0x00,
0x00, 0xaf, 0xf5, 0x00, 0x00, 0xb0, 0x05, 0x00, 0x00, 0x8f, 0xf1, 0x00, 0x00, 0x80, 0x01, 0x00,
0x00, 0x40, 0x02, 0x00, 0x00, 0x30, 0x04, 0x00, 0x00, 0x1c, 0x18, 0x00, 0x00, 0x03, 0xe0, 0x00};
struct sittingRecords
{
String dateTime;
String sittingTime;
};
sittingRecords sittingINF;
void printTimeAndDate(DateTime now);
void displayDateAndTime(DateTime now);
void displaySetTimer();
String DateText(DateTime now);
String TimeText(DateTime now);
String SetTimerText();
BLYNK_WRITE(V2) {
if (param.asInt()) {
table.clear();
delay(500);
eeAddress = 0;
rowIndex =0;
while (EEPROM.read(eeAddress) == 1){
delay(100);
eeAddress++;
sittingRecords table_sittingData;
EEPROM.get(eeAddress, table_sittingData);
delay(100);
table.addRow(rowIndex, table_sittingData.dateTime, table_sittingData.sittingTime);
//table.pickRow(rowIndex);
rowIndex++;
eeAddress += DATA_SIZE;
Serial.println("blynk_write eeAddress= " + eeAddress);
Serial.println("blynk_write rowIndex= " + eeAddress);
delay(500);
}
Serial.println("adddddd");
}
}
BLYNK_WRITE(V3) {
if (param.asInt()) {
table.clear();
rowIndex = 0;
Serial.println("clrrrrr");
}
}
BLYNK_WRITE(V4) {
if (param.asInt()) {
table.clear();
rowIndex = 0;
for (int i = 0 ; i < EEPROM.length() ; i++) {
EEPROM.write(i, 0);
Serial.println(i);
}
Serial.println("FULLY CLEARed");
}
}
BLYNK_WRITE(V5) {
if (param.asInt()) {
for (int i = 0 ; i < EEPROM.length() ; i++) {
String value= String(EEPROM.read(i));
delay(1000);
Serial.println("address: " + i);
Serial.println("value: " + value);
Serial.println();
}
rowIndex = 0;
Serial.println("READ");
}
}
void setup()
{
Serial.begin(9600); // Starts the serial communication
SerialBLE.begin(9600);
Blynk.begin(SerialBLE, auth);
// SSD1306_SWITCHCAPVCC = generate display voltage from 3.3V internally
if (!display.begin(SSD1306_SWITCHCAPVCC))
{
Serial.println(F("SSD1306 allocation failed"));
for (;;)
; // Don't proceed, loop forever
}
// Show initial display buffer contents on the screen --
// the library initializes this with an Adafruit splash screen.
display.display();
display.setTextWrap(false);
delay(2000); // Pause for 2 seconds
// Clear the buffer
display.clearDisplay();
if (!rtc.begin())
{
Serial.println("Couldn't find RTC");
while (1)
;
}
if (rtc.lostPower())
{
Serial.println("RTC lost power, lets set the time!");
// following line sets the RTC to the date & time this sketch was compiled
rtc.adjust(DateTime(F(__DATE__), F(__TIME__)));
// This line sets the RTC with an explicit date & time, for example to set
// January 21, 2014 at 3am you would call:
// rtc.adjust(DateTime(2014, 1, 21, 3, 0, 0));
}
pinMode(trigPin1, OUTPUT); // Sets the trigPin as an Output
pinMode(echoPin1, INPUT); // Sets the echoPin as an Input
pinMode(trigPin2, OUTPUT); // Sets the trigPin as an Output
pinMode(echoPin2, INPUT); // Sets the echoPin as an Input
pinMode(trigPin3, OUTPUT); // Sets the trigPin as an Output
pinMode(echoPin3, INPUT); // Sets the echoPin as an Input
settingTimeLimit = settingTimeLimit_hours + settingTimeLimit_minutes / 60.0 + settingTimeLimit_seconds / 60.0 / 60.0;
}
void loop()
{
Blynk.run();
DateTime now = rtc.now();
printTimeAndDate(now);
nowSecond = now.hour() * 60.0 * 60.0 + now.minute() * 60.0 + now.second();
nowHour = nowSecond / 60.0 / 60.0;
Serial.println(double(now.hour()) * 60 * 60);
//Serial.println(20 * 60 * 60);
// Clears the trigPin
digitalWrite(trigPin1, LOW);
digitalWrite(trigPin2, LOW);
digitalWrite(trigPin3, LOW);
delayMicroseconds(2);
// Sets the trigPin on HIGH state for 10 micro seconds
digitalWrite(trigPin1, HIGH);
delayMicroseconds(10);
digitalWrite(trigPin1, LOW);
duration1 = pulseIn(echoPin1, HIGH);
digitalWrite(trigPin2, HIGH);
delayMicroseconds(10);
digitalWrite(trigPin2, LOW);
duration2 = pulseIn(echoPin2, HIGH);
digitalWrite(trigPin3, HIGH);
delayMicroseconds(10);
digitalWrite(trigPin3, LOW);
duration3 = pulseIn(echoPin3, HIGH);
// Reads the echoPin, returns the sound wave travel time in microseconds
// Calculating the distance
distance1 = duration1 * 0.034 / 2;
distance2 = duration2 * 0.034 / 2;
distance3 = duration3 * 0.034 / 2;
// Prints the distance on the Serial Monitor
Serial.print("Distance1: ");
Serial.println(distance1);
Serial.print("Distance2: ");
Serial.println(distance2);
Serial.print("Distance3: ");
Serial.println(distance3);
distance1To2 = abs(distance1 - distance2);
distance1To3 = abs(distance1 - distance3);
distance2To3 = abs(distance2 - distance3);
Serial.println("");
Serial.println("");
if (distance1 < distance1_Limit && distance2 < distance2_Limit && distance3 < distance3_Limit)
{
if (settingTrigger == 0)
{
settingTimerStartHour = nowHour;
settingTimerStartSecond = nowSecond;
settingDay = now.day();
settingTrigger = 1;
Serial.println("if (settingTrigger == 0)");
}
if (settingDay != now.day())
{
nowHour = nowHour + 24.0;
settingDay = now.day();
Serial.println("if (settingDay != now.day())");
}
settingTimer = nowHour - settingTimerStartHour;
settingTimerSecond = nowSecond - settingTimerStartSecond;
settingTimerSecondDisplay = int(settingTimerSecond) % 60;
settingTimerMinuteDisplay = int(settingTimerSecond / 60);
settingTimerHourDisplay = int(settingTimerSecond / 60 / 60);
Serial.print("settingTimer= ");
Serial.println(settingTimer);
Serial.print("settingTimer in seconds= ");
Serial.println(settingTimerSecond);
Serial.print("nowHour in seconds= ");
Serial.println(nowSecond);
Serial.print("settingTimerStartHour in seconds= ");
Serial.println(settingTimerStartSecond);
if (settingTimer > settingTimeLimit)
{
Serial.println("unhealthy setting time");
healthySit = 2;
}
if (distance1To2 > distanceLimit1To2 || distance1To3 > distanceLimit1To3 || distance2To3 > distanceLimit2To3)
{
Serial.println("NOT HEALTHY SET");
//display.clearDisplay();
//display.setCursor(32,16);
//display.print("Not healthy set");
healthySit = 0;
//display.display();
}
else if (!(settingTimer > settingTimeLimit))
{
Serial.println("Healthy set");
healthySit = 1;
/* display.clearDisplay();
display.setCursor(32,16);
display.print("healthy set");
display.display();
*/
}
}
else if (((nowHour - settingTimer - settingTimerStartHour) * 60.0 * 60.0) > noOneSetTime_seconds && settingTrigger == 1)
{
Serial.println("No one is set");
healthySit = -1;
settingTrigger = 0;
settingTimer = 0;
eeAddress = 0;
sittingINF.sittingTime = SetTimerText();
sittingINF.dateTime = '(' + DateText(now) + ')' + ' ' + TimeText(now);
while (EEPROM.read(eeAddress) != 0)
eeAddress += DATA_SIZE + 1; //?????????????????????
EEPROM.write(eeAddress, 1);
eeAddress++;
EEPROM.put(eeAddress, sittingINF);
settingTimerSecondDisplay = 0;
settingTimerMinuteDisplay = 0;
settingTimerHourDisplay = 0;
}
Serial.println("");
Serial.println("");
// display a line of text
display.setTextSize(1);
display.setTextColor(WHITE);
display.setCursor(0, 0);
display.clearDisplay();
displayDateAndTime(now);
//display.setCursor(0,34);
display.println();
display.setTextSize(1);
switch (healthySit)
{
case 2:
{
display.drawBitmap(
(display.width() - 32) / 1,
(display.height() - 32) / 2,
skull, 32, 32, 1);
display.print(" Take a break");
break;
}
case 1:
{
display.drawBitmap(
(display.width() - 48) / 1,
(display.height() - 48) / 2,
wink, 48, 48, 1);
display.print(" Healthy sit");
break;
}
case 0:
{
display.drawBitmap(
(display.width() - 48) / 1,
(display.height() - 48) / 2,
angry, 48, 48, 1);
display.print("Not healthy!");
break;
}
case -1:
{
display.drawBitmap(
(display.width() - 32) / 1,
(display.height() - 32) / 2,
sleeping, 32, 32, 1);
display.print("Non detected");
break;
}
}
//display.setCursor(0,60);
display.setTextSize(1);
display.setCursor(0, display.height() - 16);
displaySetTimer();
display.display();
// display.startscrollleft(0x0F, 0x0F);
// delay(2000);
// display.stopscroll();
// loopSecond = now.second();
// while (loopSecond == now.second())
// {
// now = rtc.now();
// }
}
void printTimeAndDate(DateTime now)
{
Serial.print(DateText(now));
Serial.print(" (");
Serial.print(daysOfTheWeek[now.dayOfTheWeek()]);
Serial.print(") ");
Serial.print(TimeText(now));
Serial.println();
}
void displayDateAndTime(DateTime now)
{
display.print(daysOfTheWeek[now.dayOfTheWeek()]);
display.print(",\n");
display.println(DateText(now));
display.println(TimeText(now));
// display.print(now.year(), DEC);
// display.print(" /");
// display.print(now.month(), DEC);
// display.print(" /" );
// display.println(now.day(), DEC);
// if (now.hour()<10) display.print("0");
// display.print(now.hour(), DEC);
// display.print(':');
// if (now.minute()<10) display.print("0");
// display.print(now.minute(), DEC);
// display.print(':');
// if (now.second()<10) display.print("0");
// display.print(now.second(), DEC);
display.println();
// update display with all of the above graphics
display.display();
}
void displaySetTimer()
{
Serial.print("setTimerText: ");
// Serial.println(setTimerText.length());
display.println("Sitting Timer:");
display.print(SetTimerText());
display.display();
}
String DateText(DateTime now)
{
// size of DateText: 8 bytes ?????? use sizeof to check
// DateTime now = rtc.now();
dateText = "";
dateText = String(now.year()) + '/' ;
if (now.month() < 10)
dateText += '0';
dateText += String(now.month()) + '/';
if (now.day() < 10)
dateText += '0';
dateText += String(now.day());
return dateText;
}
String TimeText(DateTime now)
{
//size of TimeText: 9 bytes ???? use sizeof to check
timeText = "";
if (now.hour() < 10)
timeText += '0';
timeText += String(now.hour()) + ':';
if (now.minute() < 10)
timeText += '0';
timeText += String(now.minute()) + ':';
if (now.second() < 10)
timeText += '0';
timeText += String(now.second());
return timeText;
}
String SetTimerText()
{
setTimerText = "";
if (settingTimerHourDisplay < 10)
setTimerText += '0';
setTimerText += String(settingTimerHourDisplay);
setTimerText += ':';
if (settingTimerMinuteDisplay < 10)
setTimerText += '0';
setTimerText += String(settingTimerMinuteDisplay);
setTimerText += ':';
if (settingTimerSecondDisplay < 10)
setTimerText += '0';
setTimerText += String(settingTimerSecondDisplay);
return setTimerText;
}