'''
Description: 
Date: 2022-01-06 14:31:32
LastEditors: CK.Zh
LastEditTime: 2022-01-07 12:56:02
FilePath: /rt-thread/bsp/hc32l073/drivers/SConscript
'''
from building import *

cwd = GetCurrentDir()

# add the general drivers.
src = Split("""

""")

if GetDepend(['RT_USING_PIN']):
    src += ['drv_gpio.c']
    
if GetDepend(['RT_USING_SERIAL']):
    src += ['drv_usart.c']

if GetDepend(['RT_USING_I2C', 'RT_USING_I2C_BITOPS']):
    src += ['drv_soft_i2c.c']

if GetDepend(['RT_USING_CAN']):
    src += ['drv_can.c']

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

Return('group')
