Skip to content

Commit 396b38d

Browse files
committed
Compile errors for RP2040
1 parent e3c61b7 commit 396b38d

File tree

3 files changed

+24
-2
lines changed

3 files changed

+24
-2
lines changed

src/AudioConfig.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -237,6 +237,8 @@ typedef uint32_t eps32_i2s_sample_rate_type;
237237
#define SOFT_MUTE_VALUE LOW
238238
#define PIN_CS PIN_SPI0_SS
239239

240+
// fix missing __sync_synchronize symbol
241+
#define FIX_SYNC_SYNCHRONIZE
240242
#define IRAM_ATTR
241243

242244
#endif

src/AudioTools/AudioRuntime.cpp

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
/**
2+
* @file AudioRuntime.cpp
3+
* @author Phil Schatzmann
4+
* @brief Some platform specific exceptional things which can't be implemented in a header
5+
* @version 0.1
6+
* @date 2022-02-01
7+
*
8+
* @copyright Copyright (c) 2022
9+
*
10+
*/
11+
#include "AudioConfig.h"
12+
#include "AudioTools/AudioLogger.h"
13+
14+
#if defined(ARDUINO_ARCH_RP2040) && defined(FIX_SYNC_SYNCHRONIZE)
15+
extern "C" void __sync_synchronize(){
16+
LOGE("__sync_synchronize not implemented")
17+
}
18+
#endif

src/AudioTools/AudioRuntime.h

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77

88

99
/// stops any further processing by spinning in an endless loop
10-
void stop() {
10+
inline void stop() {
1111
#ifdef EXIT_ON_STOP
1212
exit(0);
1313
#else
@@ -23,4 +23,6 @@ inline static void checkMemory(bool stackCheck=false) {
2323
assert(heap_caps_check_integrity_all(true));
2424
if (stackCheck) printf("stack available: %d \n'", uxTaskGetStackHighWaterMark(NULL));
2525
#endif
26-
}
26+
}
27+
28+

0 commit comments

Comments
 (0)