Yahoo Groups archive

Lpc2000

Index last updated: 2026-04-28 23:31 UTC

Message

Constructors

2004-09-20 by Rodrigo Cesar da Silva Martins

How can I use class constructors with gnu arm? I'm using a LPC2129 and
Keil development system. 
For example:
//header file
class SPI
{
            public:
            SPI(char init);
            .
}
//source file
SPI::SPI(char init)
{
            .
}
//application file
 SPI ADSPI(0); //spi channel for AD converter
 
The constructor function should be called when I declare an object, but
it doesn't happen.
 
Thanks in advance,
Rodrigo Martins
Intermetric Instrumentos Ltda
(11) 4761-8009
rodrigo@...
 


[Non-text portions of this message have been removed]

Attachments

Move to quarantaine

This moves the raw source file on disk only. The archive index is not changed automatically, so you still need to run a manual refresh afterward.