Add microcontroller.core.temperature, for use as a simple sensor on minimal boards. - #210
Add microcontroller.core.temperature, for use as a simple sensor on minimal boards.#210dhalbert wants to merge 8 commits into
Conversation
…re. Dummy value returned for now.
Squeeze firmware size by using -finline-limit. Otherwise non-Express builds were slightly too big.
There was a problem hiding this comment.
This will break the ESP8266. You probably want to #ifdef it out like nvm.
There was a problem hiding this comment.
Instead, I implemented core for ESP8266. core.temperature does not exist (or at least there's no public API yet) and will return None. The common-hal temperature function returns NAN to signal no value is available. core.frequency is available and I return that.
There was a problem hiding this comment.
Please rebase so this isn't in the diff.
There was a problem hiding this comment.
I don't think this should be documented as a mod because properties only work on objects. Instead, document microcontroller.core as an object of microcontroller.Core. Please capitalize where appropriate such as the file, docs and QSTR name.
There was a problem hiding this comment.
Remove __ to match new style header guards.
…gleton class. Clarify some documentation. Transpose support matrix in `shared-bindings/index.rst`. It was getting r-e-a-l-l-y w-i-d-e, especially after adding `core` and `nvm` entries.
adc2ddb to
3a4d91b
Compare
Add
microcontroller.core.temperature, for use as a simple sensor on minimal boards.Also added
microcontroller.core.frequencyto return CPU frequency, in int Hertz.Added
-finline-limit=_n_toatmel-samd/Makefileto squeeze non-Express enough to fit.This branch crossed the v1.9.2 merge, so I gave up trying to rebase.
Fixes #177.