www.pudn.com > pd16682(2006).zip > WriteC.c


/* 写指令函数: WriteCommand() 
   函数调用入口: WriteCommand() 
   函数输入变量:dat */ 
void WriteCommand(unsigned char dat)  //写指令 
  { 
   unsigned char i; 
   for(i=0;i<8;i++) 
    { 
     CS1=0; 
     A0=0; 
     SCL=0; 
     SI=(bit)(dat&0x80); 
     _nop_(); 
     _nop_(); 
     _nop_(); 
     _nop_(); 
     _nop_(); 
     SCL=1; 
     _nop_(); 
     _nop_(); 
     dat<<=1; 
     SCL=0; 
    } 
  }