新闻中心

EEPW首页 > 嵌入式系统 > 设计应用 > 关于keil MDK 的配置文件Configuration Wizard

关于keil MDK 的配置文件Configuration Wizard

作者: 时间:2016-11-17 来源:网络 收藏
keil MDK自带的启动代码有一个优势就是可视化的配置选项,就是Configuration wizard选项,这样就省去了我们手动输入配置的问题。比如下面对于Memory的设计的Configuration界面:
而在启动代码中的这个Configuration的程序为:
// Watchdog Timer Setup
// Watchdog Timer Control Register (WTCON)
// Prescaler Value <0-255>
// Watchdog Timer Enable
// Clock Division Factor
// <0=> 16 <1=> 32 <2=> 64 <3=> 128
// Interrupt Generation Enable
// Reset Enable
//
// Watchdog Timer Data Register (WTDAT)
// Count Reload Value <0-65535>
//
// Watchdog Timer Setup

可以看出,图形化的Configuration语句放在了程序的注释上。具体的语法如下:

本文引用地址:https://www.eepw.com.cn/article/201611/315452.htm

ItemTextDescription
yesHeading: the following options belong to a group.
yesHeading with Enable: the following options belong to a group, which can be enabled via a checkbox.
yesHeading with Enable: modifies a specific bit (bit 4, in this example).
or yesHeading or Enable end.
yesTool-tip help for previous item.
yesOption for bit values which can be set via a checkbox.
yesOption with selection or number entry.
yesModify a range of bits (example: bit 4 to 5).
yesmodify a single bit (example: bit 4).
yesOption with ASCII string entry.
yesOption with ASCII string entry and a size limit of 10 characters.
ModifierDescription
<0-31>noValue range for option fields.
<0-100:10>noValue range for option fields with step 10.
<0x40-0x1000:0x10>noValue range in hex format and step 10.
<0=>yesValue and text for selection.
<#+1> <#-1>
<#*8> <#/3>
novalue modification (add, sub, mul, div) before number is merged into field.

另外还有一个重要的一点:如果想要显示Configuration Wizard

必须在代码文本的头100行之内有如下命令:

//<<>>

另外在还有一个可选的命令表示Configuration Wizard的结束:

//<<>>




评论


技术专区

关闭