Chenxg 发表于 2008-7-19 15:58:21

请教宏定义:#define TASSEL_0 (0*0x100u),这个宏定义后面的数表示为多少?为什么有个

问题如上,谢谢大家

linyu0395 发表于 2008-7-19 16:08:37

unsigh

Chenxg 发表于 2008-7-19 16:31:22

请问楼上的单词是什么意思?

Chenxg 发表于 2008-7-19 19:05:31

顶起!

Chenxg 发表于 2008-7-19 19:56:53

找到答案了:

Plz Help Me ..In msp340 header file   #define SHT0_0   (0*0x100u)

What is the meaning of than "u" in the hex value..




arunkumarvkm wrote:
> Sir
>
> Plz Help Me ..In msp340 header file   #define SHT0_0   (0*0x100u)
>
> What is the meaning of than "u" in the hex value..

It means that it should be treated as an unsigned integer.

There are other suffixes as well, "L" means long and "LL" meand long
long (for those that support it).

In this case the "U" probably doesn't matter, but it might in situations
where a larger integer in the range 0x8000-0xFFFF are used.

   -- Anders Lindgren, IAR Systems
--
Disclaimer: Opinions expressed in this posting are strictly my own and
not necessarily those of my employer.

thomasdu 发表于 2008-7-19 20:29:15

unsigned,表示无符号数
页: [1]
查看完整版本: 请教宏定义:#define TASSEL_0 (0*0x100u),这个宏定义后面的数表示为多少?为什么有个