17-11-2015, 17:34
The multiple use of Last_min in the firmware 1.5 keeps it from updating the time and date on the screen using a TFT LCD.
I have changed my code as follows so it updates. Please note this is only a snippet of the code I have modified. Werks have a look and confirm?
I found that Last_min was getting changed into minutos before the D_TFT sketch conditions could be met. Therefore no date and time was available. This is my finding anyways
I have changed my code as follows so it updates. Please note this is only a snippet of the code I have modified. Werks have a look and confirm?
I found that Last_min was getting changed into minutos before the D_TFT sketch conditions could be met. Therefore no date and time was available. This is my finding anyways
Code:
// --- Every minute Tasks - Update LCD Clock, Read local sensors, Broadcast ATM
if (MinuteNow % 1 == 0 && MinuteNow != last_minN)
{
#if DisplayType >= 1
DisplayClock_LCD(YearNow, MonthNow, DayNow, HourNow, MinuteNow);
#endif
read_InsideTH_Sensor();
read_BMP();
#if Relay_Data == 1
send_LocalData();
#endif
last_minN = MinuteNow;
}