/*-------------------------------------------------------------------------
* Some useful defines for inline assembly stuff
*-------------------------------------------------------------------------*/
#define ACCESS 0
#define BANKED 1
/*-------------------------------------------------------------------------
* Some useful macros for inline assembly stuff
*-------------------------------------------------------------------------*/
#define Nop() {_asm nop _endasm}
#define ClrWdt() {_asm clrwdt _endasm}
#define Sleep() {_asm sleep _endasm}
#define Reset() {_asm reset _endasm}
#define Rlcf(f,dest,access) {_asm movlb f rlcf f,dest,access _endasm}
#define Rlncf(f,dest,access) {_asm movlb f rlncf f,dest,access _endasm}
#define Rrcf(f,dest,access) {_asm movlb f rrcf f,dest,access _endasm}
#define Rrncf(f,dest,access) {_asm movlb f rrncf f,dest,access _endasm}
#define Swapf(f,dest,access) {_asm movlb f swapf f,dest,access _endasm }
/*-------------------------------------------------------------------------
* A fairly inclusive set of registers to save for interrupts.
* These are locations which are commonly used by the compiler.
*-------------------------------------------------------------------------*/
#define INTSAVELOCS TBLPTR, TABLAT, PROD
#endif |