Skip to content

Commit 2a26713

Browse files
committed
Platform dependent typedef
1 parent de743ad commit 2a26713

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/DriverCommon.h

+5-1
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,13 @@ namespace audio_driver {
2525
#endif
2626

2727
typedef int error_t;
28+
#ifdef ARDUINO && !AUDIO_DRIVER_FORCE_IDF
29+
typedef Wire *i2c_bus_handle_t;
30+
typedef SPIClass *spi_bus_handle_t;
31+
#else
2832
typedef void *i2c_bus_handle_t;
29-
typedef void *i2c_cmd_handle_t;
3033
typedef void *spi_bus_handle_t;
34+
#endif
3135

3236
/**
3337
* @enum input_device_t

0 commit comments

Comments
 (0)