Quantcast
Channel: Tools
Viewing all articles
Browse latest Browse all 91752

Forum Post: MISRA rule 12.8

$
0
0

Hello,

I am using CCSv5.5 and I am trygin to write to a register. I tried this the first time.

SYSReg2->STCCLKDIV = (0x1U << 24);

This threw a 10.5 warning, accoirding to MISRA checker. So I did this to fix it:

SYSReg2->STCCLKDIV = (((uint32_t)(0x1U)) << 24);

And it worked. The problem is that it is throwing me a 12.8 warning. Which is not possible because SYSReg2->STCCLKDIV is a uint32_t.

Is it a bug? I read somewhere that this was already fixed in 5.1 and newer versions.


Viewing all articles
Browse latest Browse all 91752

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>