OpenEdv-开源电子网

 找回密码
 立即注册
正点原子全套STM32/Linux/FPGA开发资料,上千讲STM32视频教程免费下载...
查看: 5250|回复: 2

SysTick_Counter_Disable显示未定义怎么回事

[复制链接]

1

主题

1

帖子

0

精华

新手入门

积分
25
金钱
25
注册时间
2014-9-9
在线时间
0 小时
发表于 2014-9-9 13:36:14 | 显示全部楼层 |阅读模式
5金钱
[mw_shl_code=c,true]#include "stm32f10x.h" #include "delay.h" #include "sys.h" #include "usart.h" void GPIO_Configuration() { GPIO_InitTypeDef GPIO_InitStructure; GPIO_InitStructure.GPIO_Pin = GPIO_Pin_All; GPIO_InitStructure.GPIO_Speed = GPIO_Speed_10MHz; GPIO_InitStructure.GPIO_Mode = GPIO_Mode_Out_PP ; GPIO_Init(GPIOA, &GPIO_InitStructure); GPIO_ResetBits(GPIOA, GPIO_Pin_All); GPIO_InitStructure.GPIO_Pin = GPIO_Pin_All; GPIO_InitStructure.GPIO_Speed = GPIO_Speed_10MHz; GPIO_InitStructure.GPIO_Mode = GPIO_Mode_Out_PP ; GPIO_Init(GPIOD, &GPIO_InitStructure); GPIO_ResetBits(GPIOD, GPIO_Pin_All); } void Systick_Configuration(void)//systick初始化函数 { [mw_shl_code=c,true] SysTick_CounterCmd(SysTick_Counter_Disable);//停止系统定时器[/mw_shl_code] [mw_shl_code=c,true] SysTick_CounterCmd(SysTick-Counter_Disable);[/mw_shl_code] SysTick_ITConfig(DISABLE); //停止systick中断 SysTick_CLKSourceConfig(SysTick_CLKSource_HCLK_Div8);//systick使用HCLK作为时钟源,频率值除以8。 SysTick_SetReload(9000);//重置时间1毫秒(以72MHz为基础计算) SysTick_ITConfig(ENABLE);//开启systic中断 } int main(void) { RCC_APB2PeriphClockCmd(RCC_APB2Periph_GPIOA|RCC_APB2Periph_GPIOD, ENABLE); //使能PA,PD端口时钟 GPIO_Configuration(); Systick_Configuration(); }[/mw_shl_code]
已经按不完全手册配置了MDK,也成功编译下载过一回修改的LED的程序。

正点原子逻辑分析仪DL16劲爆上市
回复

使用道具 举报

3

主题

2178

帖子

2

精华

论坛大神

Rank: 7Rank: 7Rank: 7

积分
3323
金钱
3323
注册时间
2013-7-19
在线时间
195 小时
发表于 2014-9-9 14:54:41 | 显示全部楼层
我怎么觉得你把网页代码也复制上去了呢
回复

使用道具 举报

530

主题

11万

帖子

34

精华

管理员

Rank: 12Rank: 12Rank: 12

积分
165540
金钱
165540
注册时间
2010-12-1
在线时间
2117 小时
发表于 2014-9-9 21:55:59 | 显示全部楼层
那就是没定义,看看是不是头文件没包进来。
我是开源电子网www.openedv.com站长,有关站务问题请与我联系。
正点原子STM32开发板购买店铺http://openedv.taobao.com
正点原子官方微信公众平台,点击这里关注“正点原子”
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则



关闭

原子哥极力推荐上一条 /2 下一条

正点原子公众号

QQ|手机版|OpenEdv-开源电子网 ( 粤ICP备12000418号-1 )

GMT+8, 2025-7-2 14:14

Powered by OpenEdv-开源电子网

© 2001-2030 OpenEdv-开源电子网

快速回复 返回顶部 返回列表