Tuesday, January 8, 2008

[oopic] Re: Interpreting serial data.

--- In oopic@yahoogroups.com, "aravind_2917" <aravind_2917@...> wrote:
>
> Thank you very much for replying...
>
> I tried writing a program similar to whats there in tht link..
> here is what i tried (and failed)...

You are misunderstanding the comments about not declaring objects
WITHIN functions. You can't do that!

oByte b1 = new oByte;
oByte b2 = new oByte;
oSerialPort sp = new oSerialPort;
oLED l1 = new oLed;
oLED l2 = new oLED;

void main(void)
{
// your logic goes here
}

void some_function(void)
{
// code for called 'some_function' goes here
}

All objects must be declared global - that means at the top of the
file before the first function declaration.

Review the sample code carefully. You will see that objects are not
declared within functions.

Richard



Yahoo! Groups Links

<*> To visit your group on the web, go to:

http://groups.yahoo.com/group/oopic/

<*> Your email settings:
Individual Email | Traditional

<*> To change settings online go to:

http://groups.yahoo.com/group/oopic/join

(Yahoo! ID required)

<*> To change settings via email:
mailto:oopic-digest@yahoogroups.com
mailto:oopic-fullfeatured@yahoogroups.com

<*> To unsubscribe from this group, send an email to:
oopic-unsubscribe@yahoogroups.com

<*> Your use of Yahoo! Groups is subject to:

http://docs.yahoo.com/info/terms/

No comments:

Post a Comment