Hi all,
What is an easy and general way to convert the bit number into its position?
Let say that I want to set bit 25 I would do something like:
void Setbit(arg)
{
switch(arg)
...
case 25:
flag |= 0x02000000;
....
}
Thanks
Ivan
What is an easy and general way to convert the bit number into its position?
Let say that I want to set bit 25 I would do something like:
void Setbit(arg)
{
switch(arg)
...
case 25:
flag |= 0x02000000;
....
}
Thanks
Ivan
Comment