1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00
19767: boards: Fix I2C Arduino mapping r=chrysn a=maribu

### Contribution description

The correct macro name is `ARDUINO_I2C_UNO` for Arduino UNO compatible I2C bus location, or `ARDUINO_I2C_NANO` for Arduino Nano compatible I2C bus location.


19768: sys/arduino: move pseudo modules to makefiles r=chrysn a=maribu

### Contribution description

This allows using the arduino_pwm feature (which is translated into a module) without the arduino module; e.g. for only using the Arduino I/O mapping but not the Arduino API.


Co-authored-by: Marian Buschsieweke <marian.buschsieweke@posteo.net>
This commit is contained in:
bors[bot] 2023-06-28 07:41:50 +00:00 committed by GitHub
commit 117c577bf6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 8 additions and 5 deletions

View File

@ -63,7 +63,11 @@ extern "C" {
/**
* @brief The only hardware I2C on ATmegas
*/
#define ARDUINO_I2C0 I2C_DEV(0)
#ifndef BOARD_ARDUINO_NANO
#define ARDUINO_I2C_UNO I2C_DEV(0)
#else
#define ARDUINO_I2C_NANO I2C_DEV(0)
#endif
/** @} */
/**

View File

@ -56,7 +56,7 @@ extern "C" {
/**
* @brief The only configured I2C
*/
#define ARDUINO_I2C0 I2C_DEV(0)
#define ARDUINO_I2C_UNO I2C_DEV(0)
/** @} */
/**

View File

@ -33,6 +33,8 @@ PSEUDOMODULES += base64url
## be advertised in any other capacity, e.g. through @ref sys_auto_init_saul).
PSEUDOMODULES += board_software_reset
PSEUDOMODULES += arduino_pwm
PSEUDOMODULES += arduino_serial_stdio
PSEUDOMODULES += can_mbox
PSEUDOMODULES += can_pm
PSEUDOMODULES += can_raw

View File

@ -19,6 +19,3 @@ endif
# include the Arduino headers
INCLUDES += -I$(RIOTBASE)/sys/arduino/include
PSEUDOMODULES += arduino_pwm
PSEUDOMODULES += arduino_serial_stdio