Skip to main content
fxdif
Associate II
Question

Reading the RCCR0 register

Posted on May 19, 2004 at 08:16

Reading the RCCR0 register

This topic has been closed for replies.

3 replies

fxdif
fxdifAuthor
Associate II
Posted on May 18, 2004 at 13:58

I want to read the RCCR0 register then load it into the RCCR register to accurately set my clock speed. I tried using a pointer to address (0x01000h) as it states in the user manual but this didn't seem to work. Any ideas???

sjo
Associate III
Posted on May 19, 2004 at 08:03

In cosmic you would define the locations:

const BYTE RCCR0 @0xFFDE;

const BYTE RCCR1 @0xFFDF;

RCCR = RCCR0; // load calibration value

in asm:

#define RCCR0 $FFDE

#define RCCR0 $FFDF

ld A, RCCR0

ld RCCR, A ; load calibration value

Regards

sjo
fxdif
fxdifAuthor
Associate II
Posted on May 19, 2004 at 08:16

Thanks!!