c3c914f4dd
machine.Timer now takes a new argument in its constructor (or init method): tick_hz which specified the units for the period argument. The period of the timer in seconds is: period/tick_hz. For backwards compatibility tick_hz defaults to 1000. If the user wants to specify the period (numerator) in microseconds then tick_hz can be set to 1000000. The user can also specify a period of an arbitrary number of cycles of an arbitrary frequency using these two arguments. An additional freq argument has been added to allow frequencies to be specified directly in Hertz. This supports floating point values when available. |
||
---|---|---|
.. | ||
bare-arm | ||
cc3200 | ||
esp32 | ||
esp8266 | ||
minimal | ||
pic16bit | ||
qemu-arm | ||
stm32 | ||
teensy | ||
unix | ||
windows | ||
zephyr |