24cxx_test._c

来自「24IIC的源代码」· _C 代码 · 共 34 行

_C
34 行
字号
//ICC-AVR application builder : 2008-11-10 11:10:06
// Target : M16
// Crystal: 8.0000Mhz

#include <iom16v.h>
#include <macros.h>


#include "delay.h"
#include "24cxx.h"
#include "lcd1602.h"

//
void main(void)
{
 unsigned char temp1[19]={18,17,16,15,14,13,12,11,10,9,8,7,6,5,4,3,2,1,0};
 unsigned char temp2[100]={0};
 unsigned char i;
 LCD_init();
 //insert your functional code here...
 LCD_write_string(0,0,"  AT24C64 TEST  ");
 //AT24CxxWrite(64,0,1000,temp1,19);
 AT24CxxRead(64,0,1000,temp2,100);
 while(1)
 {
  for(i=0;i<100;i++)
  {
   LCD_write_data(5,1,temp2[i]);
   delay_ms(1000);
  }
 }
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?