C18 LaurTec Library
2.5
Open Source C Library for PIC18 Microcontrollers
|
00001 /**************************************************************************** 00002 00003 Author : Mauro Laurenti 00004 Version : 1.0 00005 Date : 4/9/2006 00006 00007 CopyRight 2006 all rights are reserved 00008 00009 00010 ******************************************************** 00011 SOFTWARE LICENSE AGREEMENT 00012 ******************************************************** 00013 00014 The usage of the supplied software imply the acceptance of the following license. 00015 00016 The software supplied herewith by Mauro Laurenti (the Author) 00017 is intended for use solely and exclusively on Microchip PIC Microcontroller (registered mark). 00018 The software is owned by the Author, and is protected under applicable copyright laws. 00019 All rights are reserved. 00020 Any use in violation of the foregoing restrictions may subject the 00021 user to criminal sanctions under applicable laws (Italian or International ones), as well as to 00022 civil liability for the breach of the terms and conditions of this license. 00023 Commercial use is forbidden without a written acknowledgment with the Author. 00024 Personal or educational use is allowed if the application containing the following 00025 software doesn't aim to commercial use or monetary earning of any kind. 00026 00027 THIS SOFTWARE IS PROVIDED IN AN "AS IS" CONDITION. NO WARRANTIES, 00028 WHETHER EXPRESS, IMPLIED OR STATUTORY, INCLUDING, BUT NOT LIMITED 00029 TO, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A 00030 PARTICULAR PURPOSE APPLY TO THIS SOFTWARE. THE AUTHOR SHALL NOT, 00031 IN ANY CIRCUMSTANCES, BE LIABLE FOR SPECIAL, INCIDENTAL OR 00032 CONSEQUENTIAL DAMAGES, FOR ANY REASON WHATSOEVER. 00033 00034 ******************************************************** 00035 PURPOSES 00036 ******************************************************** 00037 00038 These functions allow the user to read/write inside the eeprom 00039 that requires 2 address bytes such as the 24LC512. 00040 00041 */ 00042 00043 /****************************************************************************/ 00044 00045 #ifndef FLAG_I2C_EEPROM 00046 #define FLAG_I2C_EEPROM 00047 00048 #include <i2c.h> 00049 #include <delay.h> 00050 00051 00069 signed char write_I2C_EEPROM( unsigned char control, int address, unsigned char data ); 00070 00071 00091 signed char write_I2C_EEPROM_check( unsigned char control, int address, unsigned char data ); 00092 00093 00113 signed char read_I2C_EEPROM( unsigned char control, int address, unsigned char *data ); 00114 00115 #endif