Note to self, revisit this thread later.
Demon Today, 04:49i did a little test , your way is 4 times bigger code and executes upto 10 times slower
#CONFIG __config _CONFIG1, _FEXTOSC_OFF & _RSTOSC_HFINT32 & _CLKOUTEN_OFF & _CSWEN_OFF & _FCMEN_ON
...
Modded this code for program:
https://dt.picbasic.co.uk/CODEX/ETimer
Elapsed_DN.bas came from here:
https://www.picbasic.co.uk/forum/content.php/527-Re-Elapsed-Timer-Demo
16F18877
Program:
#CONFIG
__config _CONFIG1, _FEXTOSC_OFF & _RSTOSC_HFINT32 & _CLKOUTEN_OFF & _CSWEN_OFF & _FCMEN_ON
__config _CONFIG2, _MCLRE_ON & _PWRTE_OFF & _LPBOREN_OFF &...
Weeeeee!
https://youtu.be/gvKmfPcCTvg?si=-a1qpOElWniaTyAb
...insert facepalm emote here...
Who knows how long this thing has been working. :wink:
Typo? RESETn is a low-active input so it wants a pullup, not pulldown...
The traces show you're getting a NAK to the first byte (chip address), so that needs to get fixed before anything else.
Logic Probe readings of SCL/SDA lines.
#CONFIG
__config _CONFIG1, _FEXTOSC_OFF & _RSTOSC_HFINT32 & _CLKOUTEN_OFF & _CSWEN_OFF & _FCMEN_ON
__config _CONFIG2, _MCLRE_ON & _PWRTE_OFF &...
Re: Temp variables exceeding LastTvar "Increase the MaxTvars constant"
timestamps as used on mainframes/unix etc are imho the simplest,easiest and most efficient way to measure time periods accurately. they work marvelously on pic micros too, i have tried to...
richard Today, 05:47