Marquis wrote:

Dear All,

I am doing my frist project on using the MSP430 to read data from a parallel ADC. I know C and C++ , however, I found that there is a little bit different with the MSPGCC and GCC. Can you tell me where can I find books / document taking about the MSPGCC?

I need the explanation of some strange operators such as, P1OUT |= 0x00

or P1OUT = (1<<i) | (0x80>>(o&7));


What do you find strange about these? They are perfectly normal C. The only thing a little unusual, if you have only programmed C on a PC or server, is what P1OUT represents. It is a location in the memoery space which is actual a register in parallel port 1 - the output data register to be precise. This means it has to be treated as a volatile data item by the compiler, and its address is fixed.

P1OUT |= 0x00; isn't going to do a whole lot :-\

P1OUT = (1<<i) | (0x80>>(o&7));  seems a typical C statement.

Regards,
Steve


Reply via email to