New Chipcon library stuff.
[goodfet] / firmware / apps / chipcon / chipcon.c
index b8cf041..c2c2a27 100644 (file)
@@ -53,10 +53,15 @@ void ccsetup(){
   P5OUT|=MOSI+SCK+RST;
   P5DIR|=MOSI+SCK+RST;
   //P5DIR&=~MISO;  //MOSI is MISO
+  
+  //P5REN=0xFF;
+  
 }
 
 //! Initialize the debugger
 void ccdebuginit(){
+  delay(30); //So the beginning is ready for glitching.
+  
   //Two positive debug clock pulses while !RST is low.
   //Take RST low, pulse twice, then high.
   P5OUT&=~SCK;
@@ -283,7 +288,7 @@ void cc_wr_config(unsigned char config){
 void cc_lockchip(){
   register int i;
   
-  debugstr("Locking chip.");
+  //debugstr("Locking chip.");
   cc_wr_config(1);//Select Info Flash 
   if(!(cc_rd_config()&1))
     debugstr("Config forgotten!");