I've just moved up to a 40X, using it to drive a parallel LCD, among other things.
Initially I set it up to use the first 4 Output pins for the LCD data, and two portC output pins for the RS and EN lines.
The EN pulse is supposed to be short and so it was programmed as "high portC 2", followed immediately by "low portC 2".
This is effectively a "toggle" action, expected to result in a very short pulse.
The LCD didn't work, so I checked it out with a CRO and found that the EN pulses were a lot longer than expected - measured about 300uSec!
Is there some sort of timing penalty when using the portC pins as outputs?
I tried using the Pulsout and Toggle commands, but apparently they aren't allowed in his case.
I managed to get it working using Output pins 4,5 for RS and EN, but I wanted to use the lower group of 4 Output pins for another function.
I know I could use a serial LCD, but this would require a purchase, whereas I have a parallel one on hand.
The Manual needs to be a bit clearer re the Toggle/Pulsout and portC on the 40X.
There may be some relevant info there that I have missed?
Initially I set it up to use the first 4 Output pins for the LCD data, and two portC output pins for the RS and EN lines.
The EN pulse is supposed to be short and so it was programmed as "high portC 2", followed immediately by "low portC 2".
This is effectively a "toggle" action, expected to result in a very short pulse.
The LCD didn't work, so I checked it out with a CRO and found that the EN pulses were a lot longer than expected - measured about 300uSec!
Is there some sort of timing penalty when using the portC pins as outputs?
I tried using the Pulsout and Toggle commands, but apparently they aren't allowed in his case.
I managed to get it working using Output pins 4,5 for RS and EN, but I wanted to use the lower group of 4 Output pins for another function.
I know I could use a serial LCD, but this would require a purchase, whereas I have a parallel one on hand.
The Manual needs to be a bit clearer re the Toggle/Pulsout and portC on the 40X.
There may be some relevant info there that I have missed?