can add EEPROM?

Status
Not open for further replies.

meera83

New Member
i m using PIC16F877..
i want to ask is it for one ANA input, we only have 256 location (because 2^8) to store the converter value of analog input?

can i use EEPROM as external memory in order to store more data converter for one ANA input?

i hv try with Nigel tutorial for EEPROM part, but it seen can't work as well..

i go through Nigel tutorial 6.1

since i m using PICDem2 Plus Demo Board to run the PIC, so i had make some changing in the tutorial source code...

1st part;
I2C_PORT equ PORTC
I2C_TRIS equ TRISC

2nd part;
ErrFlag equ 0x00
StartFlag equ 0x01
One equ 0x02
Zero equ 0x03


3rd part;
#define SDA 4
#define SCL 3

4th part;
Chip_Read equ 0xA1
Chip_Write equ 0xA0


5th part;
org 0x0000
goto Start
org 0x0004
retfie


the 1st and 3rd part i change according to hardware board..
for 2nd and 4th part, i don't know what should i change to..

when i click on Built program, the output show 'Bulit fail because of the 5th part'
 
Yes, you can use external EEPROM for storage, and what you're looking for is a VERY common project, it's a data logger.
 
2nd part;
ErrFlag equ 0x00
StartFlag equ 0x01
One equ 0x02
Zero equ 0x03

3rd part;
#define SDA 4
#define SCL 3

may i know what the 0x00-0x03 mean by at 2nd part?

'define SDA 4' is it mean by port the pin SDA to pin-4 at hardware?
then 'define SCL 3' mean port the SCL pin to pin-3 at PIC?
 
Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…