Skip to content

Commit

Permalink
Rename Common. to DriverCommon.h
Browse files Browse the repository at this point in the history
  • Loading branch information
pschatzmann committed May 2, 2024
1 parent 6acd7e1 commit 0e1fc6c
Show file tree
Hide file tree
Showing 18 changed files with 22 additions and 17 deletions.
7 changes: 6 additions & 1 deletion src/Driver.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@

#pragma once
#include "Common.h"
#include "DriverCommon.h"
#include "Driver/ac101/ac101.h"
#include "Driver/ad1938/ad1938.h"
#include "Driver/cs42448/cs42448.h"
Expand Down Expand Up @@ -261,6 +261,9 @@ class AudioDriver {
return true;
}

/// Gets the number of I2S Interfaces
virtual int getI2SCount() { return 1;}

protected:
CodecConfig codec_cfg;
DriverPins *p_pins = nullptr;
Expand Down Expand Up @@ -1323,6 +1326,8 @@ class AudioDriverLyratMiniClass : public AudioDriver {
bool setInputVolume(int volume) { return adc.setVolume(volume); }
int getInputVolume() { return adc.getVolume(); }
bool isInputVolumeSupported() { return true; }
// Separate ADC and DAC I2S
int getI2SCount() override { return 2;}

protected:
AudioDriverES8311Class dac;
Expand Down
2 changes: 1 addition & 1 deletion src/Driver/ac101/ac101.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
#pragma once

#include "stdbool.h"
#include "Common.h"
#include "DriverCommon.h"
#include "Utils/I2C.h"
#include "Driver/DriverConstants.h"

Expand Down
2 changes: 1 addition & 1 deletion src/Driver/ad1938/ad1938.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@

#pragma once
#include <SPI.h>
#include "Common.h"
#include "DriverCommon.h"
#include "Driver/DriverConstants.h"

/**
Expand Down
2 changes: 1 addition & 1 deletion src/Driver/cs42448/cs42448.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
*
*/
#pragma once
#include "Common.h"
#include "DriverCommon.h"
#include "Driver/DriverConstants.h"
#include "Utils/I2C.h"

Expand Down
2 changes: 1 addition & 1 deletion src/Driver/cs43l22/cs43l22.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
//#include "../Common/audio.h"
#include <stdint.h>
#include "stdbool.h"
#include "Common.h"
#include "DriverCommon.h"
#include "Utils/I2C.h"
#include "Driver/DriverConstants.h"

Expand Down
2 changes: 1 addition & 1 deletion src/Driver/es7210/es7210.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
#pragma once

#include "stdbool.h"
#include "Common.h"
#include "DriverCommon.h"
#include "Utils/I2C.h"
#include "Driver/DriverConstants.h"

Expand Down
2 changes: 1 addition & 1 deletion src/Driver/es7243/es7243.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
#define _ES7243_H_

#include "stdbool.h"
#include "Common.h"
#include "DriverCommon.h"
#include "Utils/I2C.h"
#include "Driver/DriverConstants.h"

Expand Down
2 changes: 1 addition & 1 deletion src/Driver/es7243e/es7243e.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
#define _ES7243E_H_

#include "stdbool.h"
#include "Common.h"
#include "DriverCommon.h"
#include "Utils/I2C.h"
#include "Driver/DriverConstants.h"

Expand Down
2 changes: 1 addition & 1 deletion src/Driver/es8156/es8156.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
#pragma once

#include "stdbool.h"
#include "Common.h"
#include "DriverCommon.h"
#include "Utils/I2C.h"
#include "Driver/DriverConstants.h"

Expand Down
2 changes: 1 addition & 1 deletion src/Driver/es8311/es8311.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
#pragma once

#include "stdbool.h"
#include "Common.h"
#include "DriverCommon.h"
#include "Utils/I2C.h"
#include "Driver/DriverConstants.h"

Expand Down
2 changes: 1 addition & 1 deletion src/Driver/es8374/es8374.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
#pragma once

#include "stdbool.h"
#include "Common.h"
#include "DriverCommon.h"
#include "Utils/I2C.h"
#include "Driver/DriverConstants.h"

Expand Down
2 changes: 1 addition & 1 deletion src/Driver/es8388/es8388.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
#pragma once

#include "stdbool.h"
#include "Common.h"
#include "DriverCommon.h"
#include "Driver/DriverConstants.h"
#include "Utils/I2C.h"

Expand Down
2 changes: 1 addition & 1 deletion src/Driver/tas5805m/tas5805m.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
#pragma once

#include "stdbool.h"
#include "Common.h"
#include "DriverCommon.h"
#include "Driver/DriverConstants.h"
#include "Utils/I2C.h"

Expand Down
2 changes: 1 addition & 1 deletion src/Driver/wm8978/WM8978.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#define __WM8978_H

#include <stdio.h>
#include "Common.h"
#include "DriverCommon.h"
#include "Utils/I2C.h"
#include "Wire.h"

Expand Down
2 changes: 1 addition & 1 deletion src/Driver/wm8994/wm8994.h
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
//#include "../Common/audio.h"
#include <stdint.h>
#include "stdbool.h"
#include "Common.h"
#include "DriverCommon.h"
#include "Driver/DriverConstants.h"
#include "Utils/I2C.h"
#include "Utils/etc.h"
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/DriverPins.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@

#pragma once
#include "Common.h"
#include "DriverCommon.h"
#include "SPI.h"
#include "Utils/Optional.h"
#include "Utils/Vector.h"
Expand Down
2 changes: 1 addition & 1 deletion src/Utils/I2C.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#pragma once
#include <stdint.h>
#include "Common.h"
#include "DriverCommon.h"


#ifdef __cplusplus
Expand Down

0 comments on commit 0e1fc6c

Please sign in to comment.