Closed emilydohrem1111 closed 6 years ago
I wanted to keep the code size small. Returning temperature in degrees as an integer loses precision. Returning floating point incurs processing overhead as well as larger code size. By just returning the raw data from the RTC register, the caller can handle it however they want.
According to the documentation, the
temperature()
function returns the temperature times four. Why is this the case? Won't it be better to just return the temperature directly? I may be missing something here.Documentation: