1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-01-17 04:52:59 +01:00
Commit Graph

7 Commits

Author SHA1 Message Date
Marian Buschsieweke
e7c9451b55
drivers/pcf857x: use errno code for error reporting
This makes it easier to use common error reporting such as `strerror()`
or `tiny_strerror()` to give more insight on why something failed.

The custom error codes via `enum` have been updated to be synonymous
with the `errno` codes for backward compatibility.

In addition, `pcf857x_init()` has been updated to no longer or
together the return code, but rather abort on the first fail transaction
and return the error code as is. Otherwise (when both fail due to
different error codes) the returned error code may be garbage.
2023-11-22 10:29:33 +01:00
Marian Buschsieweke
d0fccdb549
drivers/pcf857x: Move compile time check to compilation unit
This allows including the header without using the module. Obviously,
calls to the functions provided by the header won't like without using
the module. But including the header can still be useful for e.g.:

    if (IS_USED(MODULE_PCF857x)) {
        /* make use of the module */
    }

In the above example all calls to pcf857x functions would be optimized
out when the module is not used, full compile checks happen in either
case.
2023-09-15 12:52:58 +02:00
Hugues Larrive
85e41a1f18 drivers/pcf857x: allow to define PCF857x_BASE_ADDR at compile time 2023-06-14 05:38:20 +02:00
2dbf57fa46
drivers/pcf857x: fix path to saul test application 2023-05-13 19:08:40 +02:00
f9d247791d
treewide: replace occurrences of tests/driver_ with new path 2023-05-06 15:38:21 +02:00
Karl Fessel
da51932737 boards: add some missing whitespaces for static tests 2022-09-14 15:11:14 +02:00
Gunar Schorcht
7eb599e765 drivers: add PCF857X I/O expander driver 2021-12-04 14:11:04 +01:00