unsigned char verb,
unsigned char len){
switch(verb){
- //PEEK and POKE will come later.
+ //CC_PEEK and CC_POKE will come later.
case READ: //Write a command and return 1-byte reply.
cccmd(len);
ccread(1);
//Macro commands
case CC_READ_CODE_MEMORY:
- cmddata[0]=peekcodebyte(cmddataword[0]);
+ cmddata[0]=cc_peekcodebyte(cmddataword[0]);
txdata(app,verb,1);
break;
case CC_READ_XDATA_MEMORY:
- cmddata[0]=peekdatabyte(cmddataword[0]);
+ cmddata[0]=cc_peekdatabyte(cmddataword[0]);
txdata(app,verb,1);
break;
case CC_WRITE_XDATA_MEMORY:
- cmddata[0]=pokedatabyte(cmddataword[0], cmddata[2]);
+ cmddata[0]=cc_pokedatabyte(cmddataword[0], cmddata[2]);
txdata(app,verb,1);
break;
case CC_SET_PC:
+
case CC_CLOCK_INIT:
case CC_WRITE_FLASH_PAGE:
case CC_MASS_ERASE_FLASH:
return cmddataword[0];
}
-
//! Set a hardware breakpoint.
void cc_set_hw_brkpnt(unsigned short adr){
cmddataword[0]=adr;
}
//! Fetch a byte of code memory.
-unsigned char peekcodebyte(unsigned long adr){
+unsigned char cc_peekcodebyte(unsigned long adr){
/** See page 9 of SWRA124 */
unsigned char bank=adr>>15,
lb=adr&0xFF,
//! Set a byte of data memory.
-unsigned char pokedatabyte(unsigned int adr,
+unsigned char cc_pokedatabyte(unsigned int adr,
unsigned char val){
unsigned char
hb=(adr&0xFF00)>>8,
}
//! Fetch a byte of data memory.
-unsigned char peekdatabyte(unsigned int adr){
+unsigned char cc_peekdatabyte(unsigned int adr){
unsigned char
hb=(adr&0xFF00)>>8,
lb=adr&0xFF,
//! Debug an instruction, for remote use.
void cc_debug_instr(unsigned char);
//!Read a byte of code memory.
-unsigned char peekcodebyte(unsigned long adr);
+unsigned char cc_peekcodebyte(unsigned long adr);
//!Read a byte of data memory.
-unsigned char peekdatabyte(unsigned int adr);
+unsigned char cc_peekdatabyte(unsigned int adr);
//! Set a byte of data memory.
-unsigned char pokedatabyte(unsigned int adr,
- unsigned char val);
+unsigned char cc_pokedatabyte(unsigned int adr,
+ unsigned char val);
//! Debug an instruction, for local use.
unsigned char cc_debug(unsigned char len,
unsigned char a,