X-Git-Url: http://rtime.felk.cvut.cz/gitweb/pes-rpp/rpp-lib.git/blobdiff_plain/9ebcc693fb87247af18d94ba3c65229187f73a94..573021795371f41a23ed0fe0b5171f38bb96d86e:/rpp/include/rpp/gio.h diff --git a/rpp/include/rpp/gio.h b/rpp/include/rpp/gio.h index 0ffc842..9b00364 100644 --- a/rpp/include/rpp/gio.h +++ b/rpp/include/rpp/gio.h @@ -31,6 +31,9 @@ * @param[in] init_ports Specifies which ports to initialize. * RPP_GIO_PORT_ALL causes all ports to be initialized. * + * This function is not thread safe. Do not call it from multiple + * threads. + * * @return SUCCESS if successful, FAILURE otherwise. */ int8_t rpp_gio_init(uint32_t init_ports); @@ -38,6 +41,8 @@ int8_t rpp_gio_init(uint32_t init_ports); /** * Sets GIO output pin to a value. * + * The function is thread safe. + * * @param pin Pin to set * @param value Value to the pin to. * @@ -48,6 +53,8 @@ int8_t rpp_gio_set(enum pin_name pin, boolean_t value); /** * Reads the value of a GIO pin. * + * The function is thread safe. + * * @param pin Pin to read. * * @return Pin value (0 or 1) in case of success, FAILURE otherwise. @@ -70,6 +77,8 @@ enum rpp_gio_io { /** * Configure GIO pin. * + * The function is thread safe, unless compiled with -DRPP_THREADSAFE=0. + * * @param pin Pin to configure * @param io Configure the pin as input or output. * @param in_mode Input settings. Ignored when pin is configured as