diff --git a/libs/lcd.js b/libs/lcd.js index aad14b0..21228da 100644 --- a/libs/lcd.js +++ b/libs/lcd.js @@ -95,7 +95,13 @@ module.exports = { }, weather: async (city, weatherDescription, currentTemp, highTemp, lowTemp) => { weatherDescription = weatherDescription.replace(/(^\w{1})|(\s{1}\w{1})/g, match => match.toUpperCase()); - lcd.printLineSync(2, weatherDescription + ' - ' + currentTemp + '\xDF') + if (currentTemp.toString().length == 2) { + lcd.printLineSync(1, ' ' + currentTemp + '\xDF') + } else { + lcd.printLineSync(1, ' ' + currentTemp + '\xDF') + } + + lcd.printLineSync(2, weatherDescription) lcd.printLineSync(3, 'High-' + highTemp + '\xDF' + ' / ' + 'Low-' + lowTemp + '\xDF') } } \ No newline at end of file