Use pin name instead of number fails - why?

bperrybap:
I do it in the glcd library and have written a GPL open source library that does it.
............
It works outside the core code so that it can do single cycle i/o operations
rather than the goofy slow table lookup mechanisms that the Arduino core code uses.
It can also do multi bit i/o (like a full byte) in a single cycle when the multiple pins happen to be adjacent bits
in the same register all in the correct order.

Wow! I didn't know you were one of the authors of the GLCD library!

Anyway, what I was trying to do is exactly the same as you... change the code in the Noritake GUU-100 (128 x 64 GVFD library) from using digitalReads and digitalWrites because they are so slow.

I purposely wired the VFD to PORTA for the data port so I could do a fast "PORTA = data" and "data = PINA", but the other control lines are on PORTC and I'm stuck with slow digitalWrite calls.

I'll check out your avrio library... it sounds like what I need.

By the way, I added a function to your GLCD library... a "SetBrightness()" function - because the Noritake display I'm using is KS-108 compatible and it supports 8 levels of brightness, so I added that to the library.

Thanks for the reply.

-- Roger

(edit) I see I already have avrio.h... in the GLCD library! :slight_smile: