完善资料让更多小伙伴认识你,还能领取20积分哦, 立即完善>
电子发烧友论坛扫一扫,分享给好友
|
C6657手册中 的 TCR ENAMODE_ LO 描述如下
Enabling mode bits determine the timer mode. 00b = The timer is disabled (not counting) and maintains the current value. 01b = The timer is enabled one time. The timer stops after the timer counter reaches the timer period. 10b = The timer is enabled continuously. The timer counter increments until it reaches the timer period. One timer clock cycle later, the timer counter is reset to 0 and continues counting. 11b = The timer is enabled continuously. The timer counter increments until it reaches the timer period. One timer clock cycle later, the timer counter is reset to 0, the period registers (PRDHI and PRDLO) reload with the reload registers (RELHI and RELLO) and continues counting when TIMMODE is either set to 00b (64-bit timer mode) or 01b (32-bit timers unchained mode). 可是 CSL 中之定义到2!是我理解有问题,还是这个库文件有问题! typedef enum [ /** The timer is disabled and maintains current value */ CSL_TMR_ENAMODE_DISABLE = 0, /** The timer is enabled one time */ CSL_TMR_ENAMODE_ENABLE = 1, /** The timer is enabled continuously */ CSL_TMR_ENAMODE_CONT = 2 ] CSL_TmrEnamode; |
|
相关推荐
5个回答
|
|
|
你好,可以用排除法,如果不是前三种情况,就可以确定是第四种情况。
|
|
|
|
|
|
改成这样,可以自动reload 了。应该是库里面少了一项。 CSL_TmrEnamode TimeCountMode = 3; 看定时器的时钟也是晕的。 用GEL 文件中的 PLL1 设定到1G HZ , 所谓的Intel Clock 应该就是1G HZ , 按照下面设定跑出来应该是100 毫秒才对,可以i现在跑出来是600 毫秒! hwSetup.tmrTimerMode = CSL_TMR_TIMMODE_GPT; hwSetup.tmrTimerPeriodLo = 0x5F5E100;// 100 000 000 hwSetup.tmrTimerPeriodHi = 0x0; |
|
|
|
|
w97669665 发表于 2018-6-21 12:14 找到了 (EMUMGT_CLKSPD CLKDIV 是6! 谢谢 |
|
|
|
|
|
EMUMGT_CLKSPD 寄存器中的CLKDIV 要如何访问,没找到对应的CSL 。 直接写 TIMER0->emumgt_clkspd.clkdiv = 5 ; 又编译不过! |
|
|
|
|
w97669665 发表于 2018-6-21 12:44 status = CSL_tmrGetBaseAddress(0, NULL, baseAddress); baseAddress->regs->EMUMGT_CLKSPD = 0x0050000; 好吧,我找到定时器指针,这样可以访问这个寄存器! 但是这个寄存器 是只读的,所以根本就改不了。 |
|
|
|
|
只有小组成员才能发言,加入小组>>
549 浏览 0 评论
1613 浏览 0 评论
2047 浏览 0 评论
为啥BQ7693003DBTR芯片在和BQ769X0盒子通讯时收不到信号?
1513 浏览 0 评论
DSP 28027F 开发板 XDS100v2调试探针诊断日志显示了 Error -150 (SC_ERR_FTDI_FAIL)如何解决
1337 浏览 0 评论
AT32F407在USART2 DMA发送数据时,接包接到了要发送的数据,程序还是处于等待传输完成的标识判断中,为什么?
1756浏览 29评论
2781浏览 23评论
请问下tpa3220实际测试引脚功能和官方资料不符,哪位大佬可以帮忙解答下
1723浏览 20评论
请教下关于TAS5825PEVM评估模块原理图中不太明白的地方,寻求答疑
1634浏览 14评论
两个TMP117传感器一个可以正常读取温度值,一个读取的值一直是0,为什么?
1645浏览 13评论
/9
小黑屋| 手机版| Archiver| 电子发烧友 ( 湘ICP备2023018690号 )
GMT+8, 2025-12-2 00:42 , Processed in 0.579580 second(s), Total 49, Slave 42 queries .
Powered by 电子发烧友网
© 2015 bbs.elecfans.com
关注我们的微信
下载发烧友APP
电子发烧友观察
版权所有 © 湖南华秋数字科技有限公司
电子发烧友 (电路图) 湘公网安备 43011202000918 号 电信与信息服务业务经营许可证:合字B2-20210191

淘帖
1612