﻿#
# For a description of the syntax of this configuration file,
# see Documentation/kbuild/kconfig-language.txt.
#

mainmenu "Project Configuration"

config CTRLBOARD
    bool
    default y
    select HAVE_LCD
    select HAVE_GRAPHICS
    select HAVE_AUDIO
    select HAVE_VIDEO

config CMAKE_SOURCE_DIR
    string
    option env="CMAKE_SOURCE_DIR"

config DEF_CHIP_PKG_IT9860
    def_bool y

config RAM_SIZE
    default "0x4000000"

config RAM_INIT_SCRIPT
    default "IT9860_396Mhz_DDR2_396Mhz.scr"

config TILING_WIDTH_128
    int
    default 0

config WATCHDOG_ENABLE
    def_bool y

config DCPS_ENABLE
    def_bool y

config FONT_FILENAME
    default "wqyMicroHeiProportional_new.ttf"

config BACKLIGHT_ENABLE
    def_bool y

config GPIO_LCD_PWR_EN
    default "-1"

config BACKLIGHT_DUTY_CYCLES
    default "5, 25, 40, 55, 65, 75, 82, 88, 92, 95"

config BACKLIGHT_DEFAULT_DUTY_CYCLE
    default "95"

config LCD_ENABLE
    def_bool y

if !LCD_MULTIPLE

config ENABLE_ROTATE
    def_bool y

config LCD_WIDTH
    default "1280"

config LCD_HEIGHT
    default "480"

config LCD_PITCH
    default "2560"

config LCD_INIT_SCRIPT
    default "IT9860_MIPI_FRD686B40025_HX8394_480x1280_4Lane_GPIO65reset_standardEVB.txt"

endif

config CMDQ_ENABLE
    def_bool y

config M2D_ENABLE
    def_bool y

config JPEG_HW_ENABLE
    def_bool y

config AUDIO_ENABLE
    def_bool y

config AUDIO_DAC_MODULE
    default "itp_dac_ite970.c"

config AUDIO_CODEC_MP3DEC
    def_bool y

config AUDIO_CODEC_WAV
    def_bool y

config COMPRESS_AUDIO_PLUGIN
    def_bool y

config VIDEO_ENABLE
    def_bool y

config NOR_ENABLE
    def_bool y

config NOR_USE_AXISPI
    def_bool y

config NOR_ENABLE_QUADMODE
    def_bool y

if NOR_ENABLE

config NOR_CACHE_SIZE
    default "0x200000"

config NOR_RESERVED_SIZE
    default "0x280000"

config NOR_PARTITION0
    def_bool y

config NOR_PARTITION0_SIZE
    default "0xAC0000"

config NOR_PARTITION1
    def_bool y

config NOR_PARTITION1_SIZE
    default "0x2C0000"

config NOR_PARTITION2
    def_bool y

config NOR_PARTITION2_SIZE
    default "0x40000"

config NOR_PARTITION3
    def_bool y

endif

config SD0_ENABLE
    def_bool n

####SDIO WIFI CONFIG####
if SD1_ENABLE && NET_WIFI_SDIO
config GPIO_SD1_IO
      default "16, 17, 7, 15, 9, 10, -1, -1, -1, -1"

config SDIO_ENABLE
      def_bool y

config SDIO1_STATIC
    def_bool y
endif

if NET_WIFI_USB
config NET_WIFI_REDEFINE
    def_bool y
endif

if NET_WIFI_SDIO
config NET_WIFI_REDEFINE
    def_bool n
endif
########################

config USBHCC
    def_bool y

config USBH_CD_MST
    def_bool y

config FS_FAT
    def_bool y

config RTC_ENABLE
    def_bool y

config SPI_ENABLE
    def_bool n

config I2C1_ENABLE
    def_bool y

config GPIO_IIC1_CLK
    default "62"

config GPIO_IIC1_DATA
    default "61"

config TOUCH_ENABLE
    def_bool y

config TOUCH_MODULE
    default "gt911"

config TOUCH_X_MAX_VALUE
    default "0x4FF"

config TOUCH_Y_MAX_VALUE
    default "0x1DF"

config TOUCH_ADVANCE_CONFIG
	def_bool y

config TOUCH_REVERSE_X
	def_bool y

config GPIO_TOUCH_INT
    default "60"

config GPIO_TOUCH_RESET
    default "59"

config GPIO_TOUCH_WAKE
    default "-1"

config DEF_TOUCH_I2C1
    def_bool y

config TOUCH_INTR
    def_bool y

config I2S_ENABLE
    def_bool y

config I2S_SPDIF_ENABLE
    def_bool n

config POWER_SAVING_ENABLE
    def_bool y

config DEF_POWER_STANDBY
    def_bool y

config POWER_STANDBY_CPU_FREQ_RATIO
    default "15"

config POWER_STANDBY_BUS_FREQ_RATIO
    default "30"

config GPIO_UART0_TX
    default "4"

config GPIO_UART0_RX
    default "-1"

config AXISPI_ENABLE
    def_bool y

config AXISPI_MOSI_GPIO
    default "6"

config AXISPI_MISO_GPIO
    default "7"

config AXISPI_CLOCK_GPIO
    default "10"

config AXISPI_CHIP_SEL_GPIO
    default "5"

config AXISPI_WP_GPIO
    default "8"

config AXISPI_HOLD_GPIO
    default "9"

config GPIO_BACKLIGHT_PWM
    default "63"

config NET_ENABLE
    def_bool n

config TASK_DRIVE_PROBE
    def_bool y

config DBG_INIT_SCRIPT
    default "IT9860_396Mhz_DDR2_396Mhz.txt"

config DBG_STATS
    def_bool y

config DBG_STATS_HEAP
    def_bool y

config DEF_BUILD_MINSIZEREL
    def_bool y

config SYSTEM_NAME
    default "ITE Standard Project"

config ITU_FT_CACHE_ENABLE
    def_bool y

config ITU_FT_CACHE_SIZE
    default "0xFA000"

config GCC_LTO
    def_bool y

config BUILD_FLOWER
    def_bool y

#config AV_MIX_FILTER
#    def_bool y

#config BUILD_SPEEX
#    def_bool y

#config BUILD_MP3DEC
#    def_bool y

config BUILD_INIPARSER
    def_bool y

config BUILD_ITU
    def_bool y

config BUILD_SDL
    def_bool y

config BUILD_UPGRADE
    def_bool y

config BUILD_PYINPUT
    def_bool y

if NET_ENABLE

config NET_ETHERNET
    def_bool n

config NET_ETHERNET_LINK_INTR
    def_bool y

config NET_ETHERNET_MAC_ADDR_RANDOM
    def_bool y

if NET_ETHERNET
config NET_ETHERNET_MAC_ADDR_STORAGE
    def_bool y
endif

if NET_ETHERNET_MAC_ADDR_STORAGE

config NET_ETHERNET_MAC_ADDR_POS
    default "0x70000"

config NET_ETHERNET_MAC_ADDR_UPGRADE
    def_bool y

endif

config NET_DHCP_SERVER
    def_bool y

config DHCPS_ADDR_COUNT
    default "254"

config PING
    def_bool y

config BUILD_MICROHTTPD
    def_bool y

config BUILD_XML2
    def_bool y

config NET_HTTP
    def_bool y
endif

######################################################################
# Start of bootloader setting
######################################################################
config BOOTLOADER_ENABLE
    def_bool n

if BOOTLOADER_ENABLE && LCD_ENABLE && !LCD_MULTIPLE

config LCD_BOOT_BITMAP
    default "logo.bmp"

config BL_SHOW_LOGO
    def_bool y

endif

if BOOTLOADER_ENABLE

config UPGRADE_BOOTLOADER
    def_bool y

config UPGRADE_IMAGE
    def_bool y

config UPGRADE_DATA
    def_bool y

if UPGRADE_DATA
config UPGRADE_PRIVATE
    def_bool y

config UPGRADE_PUBLIC
    def_bool y

config UPGRADE_TEMP
    def_bool y
endif

config UPGRADE_OPEN_FILE
    def_bool y

config UPGRADE_PARTITION
    def_bool y

config UPGRADE_DELETE_PKGFILE_AFTER_FINISH
    def_bool y

if NOR_ENABLE
config DEF_UPGRADE_BOOTLOADER_NOR
    def_bool y

config DEF_UPGRADE_IMAGE_NOR
    def_bool y

config UPGRADE_IMAGE_POS
    default "0x80000"

config DEF_UPGRADE_PRIVATE_NOR
    def_bool y

config DEF_UPGRADE_PUBLIC_NOR
    def_bool y

config DEF_UPGRADE_TEMP_NOR
    def_bool y

config UPGRADE_NOR_IMAGE
    def_bool y

config UPGRADE_NOR_IMAGE_SIZE
    default "0x2000000"
endif

config BL_LCD_CONSOLE
    def_bool y

config BL_ERR
    def_bool y

config BL_WARN
    def_bool y

config BL_INFO
    def_bool y

config BL_DBG
    def_bool y

config CHECK_FILES_CRC_ON_BOOTING
    def_bool y

endif

######################################################################
# End of bootloader setting
######################################################################

source "$CMAKE_SOURCE_DIR/sdk/Kconfig"

######################################################################
# Project Menu
######################################################################
menu "Standard Project"

    config CHECK_FILES_CRC_ON_BOOTING
        bool "Checking files' CRC on booting time"
        default n
        help
            Checking files' CRC on booting time
        help_cht
            開啟開機時檢查檔案 CRC 值的功能。
        help_chs
            开启开机时检查档案 CRC 值的功能。

    config HW_VERSION
        string "Hardware version"
        default "V01"
        help
            Hardware version
        help_cht
            硬體版號。
        help_chs
            硬件版号。

    config SCREENSHOT_ENABLE
        bool "Screenshot is enabled or not"
        default n
        help
            Screenshot is enabled or not
        help_cht
            開啟螢幕擷取功能。
        help_chs
            开启屏幕撷取功能。

    config WEBSERVER_PORT
        string "Web server port"
        default "80"
        help
            Web server port
        help_cht
            網頁伺服器埠號。
        help_chs
            网页服务器埠号。

    config ITU_PATH
        string "ITU files path"
        depends on !LCD_MULTIPLE
        default "itu/1280x480"
        help
            ITU files path
        help_cht
            ITU檔案路徑。
        help_chs
            ITU档案路径。

    config UPGRADE_FTP_URL
        string "Upgrade ftp URL"
        default "ftp://192.168.1.1/ctrlboard/ITEPKG03.PKG"
        help
            Upgrade ftp URL
        help_cht
            網路更新F/W路徑。
        help_chs
            网络更新F/W路径。

    config UPGRADE_GUI
        bool "Upgrade by graphics display"
        depends on !LCD_MULTIPLE
        default n
        help
            Upgrade by graphics display
        help_cht
            圖形顯示更新。
        help_chs
            图形显示更新。

    config UPGRADE_DOWNLOAD_STORAGE
        bool "Saving download package to temporary storage device for upgrading"
        default n
        help
            Saving download package to temporary storage device for upgrading.
        help_cht
            存放下載的升級檔案到臨時儲存裝置。
        help_chs
            存放下载的升级档案到临时储存装置。

    choice
        prompt "Upgrade downloaded storage device"
        depends on UPGRADE_DOWNLOAD_STORAGE
        default UPGRADE_DOWNLOAD_NAND
        help
            Upgrade temporary storage device for downloaded package file.
        help_cht
            臨時存放下載的升級檔案儲存裝置
        help_chs
            临时存放下载的升级档案储存装置

    config UPGRADE_DOWNLOAD_NAND
        bool "NAND as downloaded storage device"
        help
            NAND as downloaded storage device
        help_cht
            臨時存放下載的升級檔案到NAND儲存裝置。
        help_chs
            临时存放下载的升级档案到NAND储存装置。

    config UPGRADE_DOWNLOAD_NOR
        bool "NOR as downloaded storage device"
        help
            NOR as downloaded storage device
        help_cht
            臨時存放下載的升級檔案到NOR儲存裝置。
        help_chs
            临时存放下载的升级档案到NOR储存装置。

    config UPGRADE_DOWNLOAD_SD0
        bool "SD0 as downloaded storage device"
        help
            SD0 as downloaded storage device
        help_cht
            臨時存放下載的升級檔案到SD0儲存裝置。
        help_chs
            临时存放下载的升级档案到SD0储存装置。

    config UPGRADE_DOWNLOAD_SD1
        bool "SD1 as downloaded storage device"
        help
            SD1 as downloaded storage device
        help_cht
            臨時存放下載的升級檔案到SD1儲存裝置。
        help_chs
            临时存放下载的升级档案到SD1储存装置。

    endchoice

    config UPGRADE_DOWNLOAD_POS
        string "Downloaded saving position on temporary storage device"
        depends on UPGRADE_DOWNLOAD_STORAGE
        default "0x400000"
        help
            The position of downloaded package file in the temporary storage. It should located on the reserved area.
            The area cannot overlap with other areas.

        help_cht
            下載的升級檔案臨時儲存裝置位置。必須放在未格式化區域，並且必須是Block Size(NOR:64kB, NAND:256kB)的倍數。
            本區域(位置 + 升級檔案大小)不能與其它區域重疊。

        help_chs
            下载的升级档案臨時储存装置位置。必须放在未格式化区域，并且必须是Block Size(NOR:64kB, NAND:256kB)的倍数。
            本区域(位置 + 升级档案大小)不能与其它区域重叠。

    config DYNAMIC_LOAD_TP_MODULE
        bool "Dynamically Load the Touch Panel Module"
        default n
        help
            One PKG can support multiple TP module by modifying the Peripheral->TOUCH_MODULE.
        help_cht
            一個PKG可同時支援多組觸控模組，須配合Peripheral->TOUCH_MODULE的設定。
        help_chs
            一个PKG可同时支持多组触控模块，须配合Peripheral->TOUCH_MODULE的设定。

endmenu
