Minimalistic bootloader for Ingenic SoCs.
Only the X1000 series (X1000(E), X1500, X1501) is supported at this moment.
This project is under construction.
kernel编译: make vmlinux.bin
board.c中board_init()用于在引导前对板子 进行初始化,当然也可以没有
include/configs/boards_common.h为默认值 打开板极头文件BOARD.h,去定义默认值再重新定义期望值
打开include/configs/BOARD_NAME.h 修改:
#define CONFIG_CONSOLE_BAUDRATE 3000000
#define CONFIG_CONSOLE_PC
#define CONFIG_CONSOLE_INDEX 2
打开include/configs/BOARD_NAME.h
#undef CONFIG_CONSOLE_ENABLE
打开include/configs/BOARD_NAME.h
#define KERNEL_ARGS_BOARD "xxx "
打开include/configs/BOARD_NAME.h 增加定义:#define CONFIG_RTCCLK_SRC_EXT
打开include/configs/BOARD_NAME.h 增加定义:#define CONFIG_RECOVERY
打开include/configs/BOARD_NAME.h 增加定义:#define CONFIG_WDT 默认timeout为1000ms 通过#define CONFIG_WDT_TIMEOUT_MS修改默认值
打开include/configs/BOARD_NAME.h 增加定义:#define CONFIG_PM_SUSPEND 以及
#define CONFIG_PM_SUSPEND_STATE PM_SUSPEND_STANDY ---> CPU进入idle状态
#define CONFIG_PM_SUSPEND_STATE PM_SYSPEND_MEM ---> CPU进入sleep状态
在boards/BOARD_NAME/board.c中实现gpio_ss_table[][2]数组设置休眠状态,可以不实现
打开include/configs/BOARD_NAME.h 增加定义:#define CONFIG_SOFT_BURN 在适当位置调用set_jump_to_usbboot();机器会重启进入烧录模式
编译完成会有提示:“Image: xxxxxx” is ready
首先确认代码没有超过12KByte,如果没有继续debug
This is a fork of the original x-loader written by Yanming Zhang from Ingenic.
GPLv2 or later