Message Edited by CrasyCat on 2007-04-13 01:47 PM
typedef union uCOPCTL{ tU08 byte; struct { tU08 cr :3; /*cop timer rate select */ tU08 coprstp:1; /*cop runs in stop mode */ tU08 copswai:1; /*cop stops in wait mode */ tU08 wrtmask:1; /*Write Mask for WCOP and CR[2:0] Bit */ tU08 rsbck :1; /*cop stops in active bdm */ tU08 wcop :1; /*window cop enable */ }bit;}tCOPCTL;#define CR0 0x01 /*bit masks */#define CR1 0x02#define CR2 0x04#define COPRSTP 0x08#define COPSWAI 0x10#define WRTMASK 0x20#define RSBCK 0x40#define WCOP 0x80typedef struct { volatile tCOPCTL ctl; /* COP control register */ volatile tU08 armcop; /* COP timer arm/reset register */}tCOP;
extern volatile tCOP COP @0x003E; /* COP */