diff --git a/Documentation/pycardium/bme680.rst b/Documentation/pycardium/bme680.rst index 8eb02f23b3b47813c90cc13f7022c63f51ab5f13..e657d49bf35988652dd015e6ea42ec731b6499c9 100644 --- a/Documentation/pycardium/bme680.rst +++ b/Documentation/pycardium/bme680.rst @@ -28,6 +28,8 @@ Before being able to read data from the sensor, you have to call :py:func:`bme680.init`. + .. versionadded:: 1.4 + .. py:function:: get_data() Perform a single measurement of environmental data. @@ -35,6 +37,10 @@ :return: Tuple containing ``temperature`` (°C), ``humidity`` (% r.h.), ``pressure`` (hPa) and ``gas resistance`` (Ohm). + .. versionadded:: 1.4 + .. py:function:: deinit() Deinitialize the sensor. + + .. versionadded:: 1.4 diff --git a/Documentation/pycardium/simple_menu.rst b/Documentation/pycardium/simple_menu.rst index 66a3a930466470bdc33f76315787c005ccc10e82..36758c643e7356e44c4343260c2aa529f651e9f1 100644 --- a/Documentation/pycardium/simple_menu.rst +++ b/Documentation/pycardium/simple_menu.rst @@ -1,5 +1,7 @@ ``simple_menu`` - Draw a Menu ============================= +.. versionadded:: 1.4 + To allow quickly hacking some scripts, Pycardium has a small library for displaying menus. You can use it like this: diff --git a/Documentation/pycardium/utime.rst b/Documentation/pycardium/utime.rst index 7b62db053c187880bd0a25451d6ec90a52d6b4ca..ebcff6ccbc518d593431797fb5d66c580e8201e3 100644 --- a/Documentation/pycardium/utime.rst +++ b/Documentation/pycardium/utime.rst @@ -32,7 +32,11 @@ alarm. Sets the time to ``secs`` seconds since 2000-01-01 00:00 in the local timezone. - + + .. versionchanged:: 1.4 + :py:func:`utime.set_time` previously applied a wrong timezone offset, + thus leading to wrong results. + .. py:function:: set_unix_time(secs) Sets the time to ``secs`` seconds since 1970-01-01 00:00 UTC. diff --git a/epicardium/epicardium.h b/epicardium/epicardium.h index 0c21eee1dc3f092de7fb782eb23bd1ae4b70761f..2e7944b616287eeac7b51ddcd9e1ca6d9b99eeed 100644 --- a/epicardium/epicardium.h +++ b/epicardium/epicardium.h @@ -691,6 +691,8 @@ API(API_LEDS_CLEAR_ALL, void epic_leds_clear_all(uint8_t r, uint8_t g, uint8_t b /** * BME680 * ====== + * + * .. versionadded:: 1.4 */ /** @@ -710,6 +712,8 @@ struct bme680_sensor_data { /** * Initialize the BM680 sensor. * + * .. versionadded:: 1.4 + * * :return: 0 on success or ``-Exxx`` on error. The following * errors might occur: * @@ -723,6 +727,8 @@ API(API_BME680_INIT, int epic_bme680_init()); /** * De-Initialize the BM680 sensor. * + * .. versionadded:: 1.4 + * * :return: 0 on success or ``-Exxx`` on error. The following * errors might occur: * @@ -736,6 +742,8 @@ API(API_BME680_DEINIT, int epic_bme680_deinit()); /** * Get the current BME680 data. * + * .. versionadded:: 1.4 + * * :param data: Where to store the environmental data. * :return: 0 on success or ``-Exxx`` on error. The following * errors might occur: @@ -876,6 +884,8 @@ API(API_STREAM_READ, int epic_stream_read(int sd, void *buf, size_t count)); * card10 has a BHI160 onboard which is used as an IMU. BHI160 exposes a few * different sensors which can be accessed using Epicardium API. * + * .. versionadded:: 1.4 + * * **Example**: * * .. code-block:: cpp @@ -1017,6 +1027,8 @@ struct bhi160_sensor_config { * * - ``-EBUSY``: The BHI160 driver is currently busy with other tasks and * could not be acquired for enabling a sensor. + * + * .. versionadded:: 1.4 */ API(API_BHI160_ENABLE, int epic_bhi160_enable_sensor( enum bhi160_sensor_type sensor_type, @@ -1027,6 +1039,8 @@ API(API_BHI160_ENABLE, int epic_bhi160_enable_sensor( * Disable a BHI160 sensor. * * :param bhi160_sensor_type sensor_type: Which sensor to disable. + * + * .. versionadded:: 1.4 */ API(API_BHI160_DISABLE, int epic_bhi160_disable_sensor( enum bhi160_sensor_type sensor_type @@ -1034,6 +1048,8 @@ API(API_BHI160_DISABLE, int epic_bhi160_disable_sensor( /** * Disable all BHI160 sensors. + * + * .. versionadded:: 1.4 */ API(API_BHI160_DISABLE_ALL, void epic_bhi160_disable_all_sensors()); diff --git a/pycardium/modules/py/simple_menu.py b/pycardium/modules/py/simple_menu.py index a86ccf7e97c98ba64abf0db90ac5c18e57b208f4..6450e6a1cafd0cf686a4ac1930a1b15ab65ce544 100644 --- a/pycardium/modules/py/simple_menu.py +++ b/pycardium/modules/py/simple_menu.py @@ -24,6 +24,8 @@ def button_events(): elif ev == buttons.TOP_RIGHT: # Select pass + + .. versionadded:: 1.4 """ yield 0 v = buttons.read(buttons.BOTTOM_LEFT | buttons.BOTTOM_RIGHT | buttons.TOP_RIGHT) @@ -62,6 +64,8 @@ class Menu: m.run() Then, call :py:meth:`~simple_menu.Menu.run` to start the event loop. + + .. versionadded:: 1.4 """ color_1 = color.CHAOSBLUE