fix celsius symbol

This commit is contained in:
Daniel Esteban
2020-02-08 19:44:03 +01:00
committed by Ron Evans
parent 2034f92d11
commit 0519540d0c
14 changed files with 14 additions and 14 deletions
+1 -1
View File
@@ -22,7 +22,7 @@ func main() {
for {
temp, _ := sensor.ReadTemperature()
println("Temperature:", strconv.FormatFloat(float64(temp)/1000, 'f', 2, 64), "ºC")
println("Temperature:", strconv.FormatFloat(float64(temp)/1000, 'f', 2, 64), "°C")
press, _ := sensor.ReadPressure()
println("Pressure:", strconv.FormatFloat(float64(press)/100000, 'f', 2, 64), "hPa")
hum, _ := sensor.ReadHumidity()
+1 -1
View File
@@ -22,7 +22,7 @@ func main() {
for {
temp, _ := sensor.ReadTemperature()
println("Temperature:", float32(temp)/1000, "ºC")
println("Temperature:", float32(temp)/1000, "°C")
pressure, _ := sensor.ReadPressure()
println("Pressure", float32(pressure)/100000, "hPa")
+1 -1
View File
@@ -38,7 +38,7 @@ func main() {
fmt.Printf("Date: %d/%s/%02d %02d:%02d:%02d \r\n", dt.Year(), dt.Month(), dt.Day(), dt.Hour(), dt.Minute(), dt.Second())
}
temp, _ := rtc.ReadTemperature()
fmt.Printf("Temperature: %.2f ºC \r\n", float32(temp)/1000)
fmt.Printf("Temperature: %.2f °C \r\n", float32(temp)/1000)
time.Sleep(time.Second * 1)
}
+1 -1
View File
@@ -19,7 +19,7 @@ func main() {
println("Magnetic readings:", x, y, z)
c, _ := mag.ReadTemperature()
println("Temperature:", float32(c)/1000, "ºC")
println("Temperature:", float32(c)/1000, "°C")
time.Sleep(time.Millisecond * 100)
}
+1 -1
View File
@@ -16,7 +16,7 @@ func main() {
temp, humidity, _ := sensor.ReadTemperatureHumidity()
t := fmt.Sprintf("%.2f", float32(temp)/1000)
h := fmt.Sprintf("%.2f", float32(humidity)/100)
println("Temperature:", t, "ºC")
println("Temperature:", t, "°C")
println("Humidity", h, "%")
time.Sleep(2 * time.Second)
}
+1 -1
View File
@@ -19,7 +19,7 @@ func main() {
for {
temp, _ := sensor.ReadTemperature()
println("Temperature:", temp/1000, "ºC")
println("Temperature:", temp/1000, "°C")
time.Sleep(2 * time.Second)
}