Skip to content

Commit 22c6294

Browse files
committed
Compile errors
1 parent 86a3d99 commit 22c6294

File tree

3 files changed

+11
-6
lines changed

3 files changed

+11
-6
lines changed

src/AudioBoard.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,11 @@ class AudioBoard {
1616
this->pins = pins;
1717
this->driver = driver;
1818
}
19+
20+
AudioBoard(AudioDriver &driver, DriverPins pins=NoPins) {
21+
this->pins = pins;
22+
this->driver = &driver;
23+
}
1924

2025
bool begin(){
2126
return pins.begin() && driver->begin(codec_cfg, pins);

src/Driver.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -69,17 +69,17 @@ class AudioDriver {
6969
codec_cfg = codecCfg;
7070
p_pins = &pins;
7171
if (!init(codec_cfg)){
72-
TRACEE();
72+
AUDIODRIVER_LOGE("init failed");
7373
return false;
7474
}
7575
codec_mode_t codec_mode = codec_cfg.get_mode();
7676
if(!controlState(codec_mode)){
77-
TRACEE();
77+
AUDIODRIVER_LOGE("controlState failed");
7878
return false;
7979
}
8080
bool result = configInterface(codec_mode, codec_cfg.i2s);
8181
if(!result){
82-
TRACEE();
82+
AUDIODRIVER_LOGE("configInterface failed");
8383
}
8484
setPAPower(true);
8585
return result;

src/DriverPins.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ struct PinsSPI {
9595
} else {
9696
// begin spi and set up pins if supported
9797
#if defined(ARDUINO_ARCH_STM32)
98-
LAUDIODRIVER_LOGIOGI("setting up SPI miso:%d,mosi:%d, clk:%d, cs:%d", miso, mosi, clk,
98+
AUDIODRIVER_LOGI("setting up SPI miso:%d,mosi:%d, clk:%d, cs:%d", miso, mosi, clk,
9999
cs);
100100
p_spi->setMISO(miso);
101101
p_spi->setMOSI(mosi);
@@ -166,12 +166,12 @@ struct PinsI2C {
166166
p_wire->setSDA(sda);
167167
p_wire->begin();
168168
#else
169-
LOGW("setting up I2C w/o pins");
169+
AUDIODRIVER_LOGW("setting up I2C w/o pins");
170170
p_wire->begin();
171171
}
172172
#endif
173173
}
174-
LOGI("Setting i2c clock: %u", frequency);
174+
AUDIODRIVER_LOGI("Setting i2c clock: %u", frequency);
175175
p_wire->setClock(frequency);
176176
}
177177
return true;

0 commit comments

Comments
 (0)