Tc3xx平台Tom /atom配置PWM模式,但是cn0不会复位

公告

大中华汽车电子生态圈社区并入开发者社区- 更多资讯点击此

Tip / 登入 to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Miles1
Level 3
Level 3
Welcome! 5 comments on blog First comment on blog
CN0 计数器一直不复位,且cn0的值等于CM0 ( 不是配置成单次触发 OSM_TRIG=0 )
0 点赞
16 回复数
Miles1
Level 3
Level 3
Welcome! 5 comments on blog First comment on blog
补充:提问:TOM的Pwm要想cn0正常计数,对于gtm的时钟有什么要求,或者有没有其他关键点需要注意的
0 点赞
青柠笑笑
Level 5
Level 5
100 replies posted 50 replies posted 25 replies posted
坐等大神答复
0 点赞
DoubleMonth
Level 4
Level 4
100 replies posted 50 replies posted 25 replies posted
过来学习一下
0 点赞
小拜月
Level 4
Level 4
First like received 100 replies posted 50 replies posted
学习一下
0 点赞
青柠笑笑
Level 5
Level 5
100 replies posted 50 replies posted 25 replies posted
学习一下
0 点赞
sjhdaflafjk
Level 4
Level 4
50 replies posted 25 replies posted 10 replies posted
要设置好CN0复位的触发方式。
0 点赞
Miles1
Level 3
Level 3
Welcome! 5 comments on blog First comment on blog
触发方式指的是?
0 点赞
Jenny123
Level 4
Level 4
First like received 25 comments on blog 10 comments on blog
CN0清零的配置,要配置好,再确认一下
0 点赞
Miles1
Level 3
Level 3
Welcome! 5 comments on blog First comment on blog
确认过了呢,CN0不是不清零,而是不进行计数。
0 点赞
Jenny123
Level 4
Level 4
First like received 25 comments on blog 10 comments on blog
CN0不加加的话,你确认下,你的clock有没有使能和运行呢
0 点赞
Miles1
Level 3
Level 3
Welcome! 5 comments on blog First comment on blog
运行自动生成的代码,cn0不计数,注掉它,然后自己手写寄存器(只是配置定时器控制,不涉及时钟配置),cn0会计数,且有波形输出。这应该能排除时钟没使能的假设吧
0 点赞
Miles1
Level 3
Level 3
Welcome! 5 comments on blog First comment on blog
在启动文件中,GTM 的时钟分频被初始化为0了,导致atom 通道时钟的初始化失败。 后面有重新初始化GTM的分频,但是初始化顺序已经不对了,所以atom通道就发生了异常,以上是我在之后找到的问题点,感谢您的解答。
0 点赞
Jenny123
Level 4
Level 4
First like received 25 comments on blog 10 comments on blog
有没有解决呢,分享学习一下
0 点赞
Jenny123
Level 4
Level 4
First like received 25 comments on blog 10 comments on blog
你可以对比你手写代码的寄存器和生成代码的寄存器值,看能不能找到差异
0 点赞
Miles1
Level 3
Level 3
Welcome! 5 comments on blog First comment on blog
差异很小,能计数的程序ACT_TB =0x00001 而我的程序烧进去运行时 0x00000
0 点赞
Miles1
Level 3
Level 3
Welcome! 5 comments on blog First comment on blog
在启动文件中,GTM 的时钟分频被初始化为0了,导致atom 通道时钟的初始化失败。 后面有重新初始化GTM的分频,但是初始化顺序已经不对了,所以atom通道就发生了异常,以上是我在之后找到的问题点,感谢您的解答。
0 点赞