首页 > 代码库 > 基于VMware的eCos应用程序测试(hello wold)

基于VMware的eCos应用程序测试(hello wold)

(1)脚本配置
ecosconfig new pc
cdl_component CYG_HAL_STARTUP {
# Flavor: data
# No user value, uncomment the following line to provide one.
user_value FLOPPY (此处为修改的位置)
# value_source default
# Default value: RAM
# Legal values: "RAM" "FLOPPY" "ROM" "GRUB"
....
}
# Default console channel.
#
cdl_option CYGNUM_HAL_VIRTUAL_VECTOR_CONSOLE_CHANNEL_DEFAULT {
# Flavor: data
# No user value, uncomment the following line to provide one.
user_value 2 (此处为修改的位置)
# value_source default
# Default value: 0
# Legal values: 0 to CYGNUM_HAL_VIRTUAL_VECTOR_COMM_CHANNELS-1
# CYGNUM_HAL_VIRTUAL_VECTOR_COMM_CHANNELS == 3

# The following properties are affected by this value
# option CYGNUM_HAL_VIRTUAL_VECTOR_CONSOLE_CHANNEL
# DefaultValue: YGNUM_HAL_VIRTUAL_VECTOR_CONSOLE_CHANNEL_DEFAULT (此处为修改的位置)
};
ecosconfig tree
make
copy ecos-3.0源文件中得hello.c
cp ./../ecos-3.0/examples/hello.c ./
编译hello.c
i386-elf-gcc -g -D_ECOS -I./install/include hello.c -L./install/lib -Ttarget.ld -nostdlib -o hello
i386-elf-objcopy -O binary hello hello.bin
生成软盘镜像
dd conv=sync if=hello.bin of=hello.flp bs=1440k