Hi everybody. My problem is when i try to mixing C++ and assembler modules. I ca mixing C and assembler modules thank to the document "Mixing C and Assemble with the MSP430" but this only work for C. I am working with the IDE IAR Embedded Workbench for MSP430, but in this environment the option "list" "generate a output file assembler source is disable, however i can't generate a skeleton file to use with my C+ code. I read the compiler referent manual for C/C++ ( is part of th environment IAR documentation) but this document realy not help me. I have the hope that somebody of this group can help me with the name o a document, a link, source code (only if is of free distribution or the author of the code made the post). Anything that can help me. PD: Thank you very much and sorry for my bad spelling, but the english is not my mother tongue. I try to do my best. :) Atte: Ing. Rodolfo Gonzalez Bernaldez
mixing C++ and assembler modules with the MSP430
Started by ●August 15, 2005
Reply by ●August 15, 20052005-08-15
On Mon, 15 Aug 2005 08:56:43 -0500, el_777 <el_777@yahoo.com> wrote:> My problem is when i try to mixing C++ and assembler modules. I can > mixing > C and assembler modules thank to the document "Mixing C and Assembler > with > the MSP430" but this only work for C.You are probably seeing the names being mangled by C++ compiler. Try to surround your declarations of assembly functions with extern "C" { } Vadim
Reply by ●August 21, 20052005-08-21
>On Mon, 15 Aug 2005 08:56:43 -0500, el_777 <el_777@yahoo.com> wrote: > >> My problem is when i try to mixing C++ and assembler modules. I can >> mixing >> C and assembler modules thank to the document "Mixing C and Assembler >> with >> the MSP430" but this only work for C. > >You are probably seeing the names being mangled by C++ compiler. Try t>surround your declarations of assembly functions with > > extern "C" > { > } > > Vadim >Hi Vadim, thanks for the tip, this really works but come up severa sorprice in the behaviour of the program. I presumme i have to made som tricks if i want to work with C++ and asm. Thank you vary much. Atte. Ing Rodolfo Gonzalez Bernaldez