LCD Component

Forum for suggestions regarding the next update / release of Flowcode

Moderators: Benj, Mods

Post Reply
echase
Posts: 429
Joined: Mon Jun 11, 2007 11:55 am
Has thanked: 49 times
Contact:

LCD Component

Post by echase »

Would it not be a good idea to make your standard LCD component contain the lines:-

clear_bit(intcon, GIE);
set_bit(intcon, GIE);

trisb = trisb & 0x0F; //Sets the high nibble to an output
trisb = trisb | 0xF0; //Sets the high nibble to an input

in appropriate places?

This is because in real life systems it’s common to share LCD's data lines with menu pushbuttons and without the trisb lines the switches are ignored. Also interrupts seem to corrupt the LCD write process.

I find it difficult to believe that Flowcode users other then me have not met these problems.

Admittedly these problems do not affect all code and all PIC types (e.g. the interrupt problem affects my 2520 PIC but not my 886), so it isn’t essential. But it would be useful to at least have them in there commented out, with a note in the header to instruct users how to enable them and under what circumstances they may be needed.

The downsides are small, being slightly larger code and slight pauses in the interrupts.

An alternative would be to include some reference to the problem in a Help or Tutorial file.

ASDned
Posts: 6
Joined: Tue Sep 08, 2009 12:08 pm
Contact:

Re: LCD Component

Post by ASDned »

Its good to have also the 8 bits data LCD as a second option because of the timing problems in the 4 bit mode.
Best regards,
ASDned

User avatar
Benj
Matrix Staff
Posts: 15312
Joined: Mon Oct 16, 2006 10:48 am
Location: Matrix TS Ltd
Has thanked: 4803 times
Been thanked: 4314 times
Contact:

Re: LCD Component

Post by Benj »

Hello

8-bit data mode is a good option and we will put this on the features list.

Regarding the enabling and disabling of interrupts this is a possibility but we think its best to add this functionality yourself via the code customization feature.

Post Reply