I have been using DS1307 Real Time Clocks for some time now without problems. I am attempting to port a program I wrote a while back from a 18f4620 to a 18f46k22 and I can't seem to get the I2C RTC...
PICs always have hidden surprises ....
Ok, understood also indirect addressing now, thanks for your patience :-)
db is definitely an easier way to pack a mixed string data statement like "say",34,"hello",34,0 . funny I could never see the point of db until now
4.14 da – STORE STRINGS IN PROGRAM MEMORY (PIC12/16 MCUs)
Funny, but if you try it you'll see the unwanted 00 added
db is ok
@ da "say \"Hello\"\0"
da – Data ASCII.
Generates a packed 14-bit number representing two 7-bit ASCII characters.
Found the problem.
I have a string like this:
I use this format do declare it, the same format I was using with arraywrite
@ da "say",34,"hello",34,0
there's another little cheat if all the strings are odd length the 0 terminator is redundant
00013E 6548 6C6C 006F 00199 da "Hello",0
odd length strings , wastes space but not a problem
00013E 6854 7369 6920 00199 data "This is a string1",0
2073 2061 7473
6972 676E 0031
00013E 6854 7369...