Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Using SFR as GPR

Status
Not open for further replies.

Mosaic

Well-Known Member
Folks, i am fresh out of bank 0 gpr, and I need one more byte. 16f886 MCU.
Since I am not using the EUSART can I utilise the RCREG and the TXREG SFRs as regular GPRs?

I note that sfr 08h isn't used in the '886, is this available as a gpr then?

Simulator fails 08h and allows the EUSART TX/RC to be used as GPR.
 
Last edited:
RCREG is a read only register I do believe. However, EEADR and EEDATA I believe can be used as a GPR as long as you don't initiate an EEPROM read/write in your code.
 
The sim is allowing the SSPBUF as well...as I am not using SPI or I2C, there seems to be no impact on the program.
 
Status
Not open for further replies.

New Articles From Microcontroller Tips

Back
Top