That's it. It worked just fine.
Thank you Frank,
Roberto.
"Wollenberg, Frank" wrote:
{Quote hidden}> Just define
> static volatile unsigned int TIMER1 @ 0x0e;
> static volatile unsigned int CCPR1 @ 0x15;
> Now you can use these 16-bit var«s in the same manner as 8-bit var's, e.g.
> CCPR1 = CCPR1 + TIMER1;
> or short
> CCPR1 += TIMER1;
>
> See you,
> Frank
>
> > Von: Roberto Fonseca Iannini [
.....roberto1KILLspam
@spam@LINKEXPRESS.COM.BR]
> > Betreff: 8 + 8bits variable
> >
> > What's the c syntax to perform an 16-bit sum like:
> > CCPR1 = CCPR1 + TIMER1;
> > Note that TIMER1 wasn't defined by the 1687x.inc. Instead it
> > was made as
> > TIMER1H and TIME1L (each one 8 bits type). The same is true to CCPR1.
> > Summarizing: How can I define or use a new 16 bit variable called
> > TIMER1 that is formed by TIMERH and TIMERL (MSB and LSB)?
> > (this code is for 16F877)
> > See you guys,
> >
> > Beto.
> >