⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 at24c02.h

📁 W3100是WIZnet公司专门为以太网互联和嵌入式设备推出的硬件TCP/IP协议栈芯片
💻 H
字号:
#ifndef __AT24C02
#define __AT24C02

/*
###############################################################################
 Wiznet.
 5F Simmtech Bldg., 228-3, Nonhyun-dong, Kangnam-gu,
 Seoul, Korea

 (c) Copyright 2002, Wiznet, Seoul, Korea

 Filename : at24c02.h
 Version : 1.0
 Created : 2002/01/29
 Modified :
 Description : Implement I2C I/F using Port #1's No 3(SDA) and No 4(SCL) of 89C51 MCU and Read/Write Serail EEPROM, AT24C02.
               AT24C02 Size : 2K Bits, 256 Byte, 
	       AT24C02 Address Range : 0x00 ~ 0xFF
	       AT24C02 I/F : i2C using SDA and SCL
Note :AT24C02 has Address A2-A0 to address several,but it's not implemented in this source.
And AT24C02 has PAGE(8 BYTE) Writing, but it's not implemented in this source and it's possible to implement using this functions.
###############################################################################
*/


/*
###############################################################################
Include Part
###############################################################################
*/
                                        
#define DEVICE_WR	0xA0				// DEVICE's ADDRESS to be written into AT24C02
#define DEVICE_RD   	0xA1				// DEVICE's ADDRESS to read from AT24C02


char Check_EEPROM();					// Check operatiton of EEP_ROM(AT24C02)

char EEP_Write(char addr, char d);			// Write 1 byte data('d') into appropriate address(addr)

char EEP_WriteBytes(char addr, char* d,int len);	// Write 'len' sized data into appropriate address(addr)

char EEP_Read(char addr, char* d,char IsContinue);	// Read from AT24C02 of appropriate address(addr) and Return into 'd' value.

char EEP_ReadBytes(char addr, char* d, int len);	// Read 'len' sized data from appropriate address(addr), write into starting address of data string and return 

#endif

⌨️ 快捷键说明

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