Try to put a pause of 1 sec. yust before your programm starts.
The display must be initialised. And that kosts time.
The instruction is faster then the display initialisation.
Between
value var byte
(here)
lcdout $FE,1
you put a pause ot 1 sec.
Try to put a pause of 1 sec. yust before your programm starts.
The display must be initialised. And that kosts time.
The instruction is faster then the display initialisation.
Between
value var byte
(here)
lcdout $FE,1
you put a pause ot 1 sec.
If i remember correctly, lower bits of PORTB, ( PORTB.2 ) is also multiplexed with RX of the USART. And i don't remember if this PIC allow you to disable the RX part, so my guess would be...
sure enough there's few unecessary delay up here... not sure if this will help and work at all using the above... Maybe a good situation to use SEROUT/SEROUT2/DEBUG?Code:for value = 1 to 255 RCSTA=0 ' Disable USART TRISB.2=0 pause 25 LCDout $FE,$C0, dec value pause 25 RCSTA=$90 ' enable USART pause 25 hserout [0,dec value] ; IF THIS LINE IS ENABLED, LCD DOESN NOT DISPLAY ANYTHING pause 50 next value
PS: Make sure of your DEFINES, must all be in UPPERCASE, unless, it may not work.
Steve
It's not a bug, it's a random feature.
There's no problem, only learning opportunities.
Mister E is right, the DEFINES must be in upper-case, and are not checked by the compiler, which means there are no error messages if you don't enter them correctly - they just don't work.
Also, you are using PORTA.4 as your LCD ENABLE. You MUST put a pull-up on this port if you are going to use it as an output.
Charles Linquist
If you do not believe in MAGIC, Consider how currency has value simply by printing it, and is then traded for real assets.
.
Gold is the money of kings, silver is the money of gentlemen, barter is the money of peasants - but debt is the money of slaves
.
There simply is no "Happy Spam" If you do it you will disappear from this forum.
Thank you for your help
I modifies as Steve's suggestion, it works now
Actually I do not require the RX part, is there any way permanently disable the RX part ( to save 2x pause 25 ) ?
Not sure you require them anyways... seems there's no way to use only the Transmitter section. So, or you change HSEROUT to DEBUG, or you add the above in your code.
Probably I would use the DEBUG route myself.
Steve
It's not a bug, it's a random feature.
There's no problem, only learning opportunities.
Bookmarks