This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Hello,
i need help with the syntax for inline asm commands in CCE3.1 .
My code for MSPGCC :
asm (" mov.w %0,R10" : : "r" (RAM_EE.T1.MDROPaddr));
and what is the translation for CCE ?
Can someone help my ?
thanks
roy
Roy,
The asm command in cl430 (the MSP430 compiler used by CCE) does not have the operand expansions like GCC, but only strict assembly instructions. Check the details and potential pitfalls when using inline assembly at section 6.5.4 of MSP430 Optimizing C/C++ Compiler User's Guide (SLAU132).
I am not an expert in MSP assembly programming, but to access a C variable in assembly you will need to insert a leading underscore "_" to the variable name (RAM_EE in your case). Unfortunately I don't know how access the two inner members of the struct (T1 and MDROPaddr) from assembly - I don't know if the compiler creates specific symbols to each member of the struct or performs address displacement relative to the top level of the struct (RAM_EE).
Hope this helps,
Rafael