IronJungle
Senior Member
Using the LKM1638 discussed here with a:
- PICAXE 18M2
- DS1307 RTC
- 24LC156 EERPOM
The objective is to display the time of day (from the 1307 RTC) on the LEFT four 7 segments and
display a four letter words from the 24LC156 EERPOM on the RIGHT four segments.
Separately every thing works fine. If I comment out the readi2c command for the 1307 RTC the display happily shows four letter words read from the EEPROM just fine.
If I comment out the readi2c commands for the EEPROM the display happily shows the time just fine.
When I try to show both the time of day AND a four letter word the result is: time as "ghost in the machine" and the four letter word remains perfect.
This is the first time I have had more that one device on the i2c bus. I think this has something to do with the way I am reading the two devices from the i2c bus. I am doing no writei2c in the program. I have pre loaded the EEPROM and the time of day into the RTC.
To read the 1307 RTC I am using:
readi2c 0,(seconds, minutes, hours, junkread, junkread, junkread, junkread, blinky) 'REMARK: 'junkread' because I do not need day, date, month, year.
To read the 24LC156 EERPOM I am using:
readi2c w10, (Segment1RIGHT) ' where w10 ranges from 0 to 1,003.
BTW, I have tried starting the EEPROM with w10 = 1 (thinking "0" was conflicting with the RTC), but no change.
Any guidance?
- PICAXE 18M2
- DS1307 RTC
- 24LC156 EERPOM
The objective is to display the time of day (from the 1307 RTC) on the LEFT four 7 segments and
display a four letter words from the 24LC156 EERPOM on the RIGHT four segments.
Separately every thing works fine. If I comment out the readi2c command for the 1307 RTC the display happily shows four letter words read from the EEPROM just fine.
If I comment out the readi2c commands for the EEPROM the display happily shows the time just fine.
When I try to show both the time of day AND a four letter word the result is: time as "ghost in the machine" and the four letter word remains perfect.
This is the first time I have had more that one device on the i2c bus. I think this has something to do with the way I am reading the two devices from the i2c bus. I am doing no writei2c in the program. I have pre loaded the EEPROM and the time of day into the RTC.
To read the 1307 RTC I am using:
readi2c 0,(seconds, minutes, hours, junkread, junkread, junkread, junkread, blinky) 'REMARK: 'junkread' because I do not need day, date, month, year.
To read the 24LC156 EERPOM I am using:
readi2c w10, (Segment1RIGHT) ' where w10 ranges from 0 to 1,003.
BTW, I have tried starting the EEPROM with w10 = 1 (thinking "0" was conflicting with the RTC), but no change.
Any guidance?