Hi Back again
I have changed from 16F648A to a 18F1320 to allow the use of PBPL, the pin allocations are different for the CCP and the USUART but that is now sorted.
I am looking now at Darrel Taylor’s macro HPWM10, there are two uses of DIV32 the first calculating the value of PR2. The DIV32 multiply is within the PR2 ASM routine
With Darrels' permission.. could the next lines be something like?
HP_Long = (resultant of Multiplication) / HP_Freq
HP_Temp = HP_Long.WORD0
in which R register does the resultant reside?
or remove the PR2 ASM altogether and just use PBPL.
and the second use of DIV32 for the CCP section
HP_Long = HP_Temp * HP_Duty
HP_Long = HP_Long / 1023
HP_Duty = HP_Long.WORD0
long winded and compiles into 1624
I would very much wish to contribute but I find it very difficult when there are so many people who know soooooo much more than I.
Thanks also for the help Charles, I do not have any PICs hooked up to a 108 type keyboard, I presume that it is easier on is the older type rather than the newer PS2 type. Actually I have a couple of old magnetic swipe card readers and some old keyboard inline barcode readers as well in the same box, trouble is I could not begin to remember where the box might be![]()
I am also reminded that I used to know all the barcode symbologies once.......... now I regret all gone................ come to think of it quite glad really. maybe it made space for something more exciting
Duncan





Bookmarks