Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

i2c eeprom cant read a page

Status
Not open for further replies.

spuffock

Member
having great trouble trying to read a 16 byte page from a 24aa512 eeprom using 16f887. The memory accepts the control byte, the address bytes, and the read control byte. It then produces the first byte, and that's it. The ACK looks good on the scope, but theres no more. I can read any of the other bytes one at a time, all correct, proving that the page write routine worked .
Hope someone can look at this bit of code and spot my ridiculous mistake.
 

Attachments

  • I2C PROBLEM.ASM
    6.4 KB · Views: 115
having great trouble trying to read a 16 byte page from a 24aa512 eeprom using 16f887. The memory accepts the control byte, the address bytes, and the read control byte. It then produces the first byte, and that's it. The ACK looks good on the scope, but theres no more. I can read any of the other bytes one at a time, all correct, proving that the page write routine worked .
Hope someone can look at this bit of code and spot my ridiculous mistake.

hi,
Trying your asm on Oshonsoft Sim, two subr are missing SEND and FAIL, it will not assemble.

EDIT:
On the SIM it goes into a continuous loop here [SETUP]
Code:
BSF    SSPCON2,SEN    ;START CONDITION
    BTFSC    SSPCON2,SEN
    GOTO    $-1

Inserted a dummy SEND & FAIL
 
Last edited:
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top