Bela
Real-time, ultra-low-latency audio and sensor processing system for BeagleBone Black
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups
bela_hw_settings.h
1 #pragma once
2 // This assumes BBB/BBG/PB
3 const unsigned int codecI2cBus = 2; // Bus for TLV320AIC3104 and/or ES9080Q
4 const unsigned int kBelaCapeButtonPin = 115; //P9.27 / P2.34
5 const unsigned int kAmplifierMutePin = 61; // P8.26 / nothing on BelaMini
6 const unsigned int kSpiDacChipSelectPin = 5; // P9.17 used for ADC on BelaMini
7 const unsigned int kSpiAdcChipSelectPin = 48; // P9.15 unused on BelaMini
8 // below are for user LED USR3
9 const unsigned int kUserLedGpioPin = 56;
10 const unsigned int kUserLedNumber = 3;
11 const char kUserLedDefaultTrigger[] = "mmc1";
12 const unsigned int tlv320CodecI2cAddress = 0x18; // Address of TLV320AIC3104
13 const unsigned int es9080CodecAddress = 0x4c; // write-only address of TLV320AIC3104
14 const unsigned int es9080CodecResetPin = 11; // reset GPIO
15 
16 #include <linux/version.h>
17 #if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 14, 108) // first kernel we shipped with a different location of the spidevs
18 const char ctagSpidevGpioCs0[] = "/dev/spidev3.0"; // Path for SPI bus 0
19 const char ctagSpidevGpioCs1[] = "/dev/spidev3.1"; // Path for SPI bus 1
20 #else // 4.14.108
21 const char ctagSpidevGpioCs0[] = "/dev/spidev32766.0"; // Path for SPI bus 0
22 const char ctagSpidevGpioCs1[] = "/dev/spidev32766.1"; // Path for SPI bus 1
23 #endif // 4.14.108