A comment to new graphics libraries

Beta Testing discussion on mikroPascal PRO for dsPIC30/33 and PIC24.
Post Reply
Author
Message
OT
Posts: 581
Joined: 19 May 2005 05:08
Location: Fairbanks, Alaska

A comment to new graphics libraries

#1 Post by OT » 08 Dec 2010 09:00

I have neither a TFT or and Epson compatible LCD available, neither does it seem to be any examples available yet (?), so testing these libraries would have required a lot of work. However I do note the following with respect to strategy for pin-assignment:

During the evolution of the GLCD library, we went through large number of different iterations with respect to how the pins were assigned, and we finally ended up with the current very nice version where all pins could be assigned individually. In the new libraries the data port has just a single port assignment, in other words the different lines will have to go for instance from RD0 to RD7 or RB0 to RB7 only (I assume) and it is not possible to reorder them. Why not go all the way with making the individual pins assignable and be done with it? Mind you it is not going to be long before users want to make their own hardware, and that is when needs will arise. Although admittedly the MMBs look very attractive right now. BTW. if you could deliver the MMBs with a matching box, perhaps with a couple of alternative backs with respect to depth for extra equipment, they could become even more attractive.

octal
Posts: 534
Joined: 09 Feb 2005 14:15
Location: France
Contact:

Re: A comment to new graphics libraries

#2 Post by octal » 08 Dec 2010 11:08

OT wrote: In the new libraries the data port has just a single port assignment, in other words the different lines will have to go for instance from RD0 to RD7 or RB0 to RB7 only (I assume) and it is not possible to reorder them. Why not go all the way with making the individual pins assignable and be done with it?
Because of effectivenes. When you write a byte, it's better to write it to a single port (in one shot) than to write each signal separately.
PIC architecture makes things worse, it uses the read/write/modify scheme. So if you put each signal in a separate port, and write each one separately, you'll need a lot of read/write/modify operations. Puting all 8 bits to a single port, does all that in 1 operation.

You can always manage to got all your data on the same port, and PIC24/dsPIC makes things easy especially with their PPS capabilitie that let you remap peripherals like I2C/USART/SPI to other pins and then free-up a port to use it as GLCD dataport.

Regards
http://www.pocketmt.com

Post Reply

Return to “mikroPascal PRO for dsPIC30/33 and PIC24 Beta Testing”