summaryrefslogtreecommitdiff
path: root/bsp/ESP/ESP32_C6/libraries/drivers/SConscript
blob: 7128e528532634296dceed794af0ce6241c77187 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
import os
from building import *

cwd = GetCurrentDir()
src = ['board.c']

# This directory is built through a scons variant dir (duplicate=0), so the
# hand maintained sdkconfig.h that the ESP-IDF sources include is not copied
# next to the objects.  Add the real directory to the include path.
CPPPATH = [cwd, Dir('.').srcnode().abspath]

if GetDepend('BSP_USING_GPIO'):
    src += ['drv_gpio.c']

if GetDepend('BSP_USING_UART'):
    src += ['drv_uart.c']

if GetDepend('BSP_USING_ADC'):
    src += ['drv_adc.c']

if GetDepend('BSP_USING_I2C'):
    src += ['drv_hw_i2c.c']
    
if GetDepend('BSP_USING_PWM'):
    src += ['drv_pwm.c']

if GetDepend('BSP_USING_CLOCK_TIMER'):
    src += ['drv_timer.c']

if GetDepend('BSP_USING_WIFI'):
    src += ['drv_wifi.c']

if GetDepend('BSP_USING_SPI'):
    src += ['drv_spi.c']


group = DefineGroup('Drivers', src, depend = [''], CPPPATH = CPPPATH)

Return('group')