First off, thanks for a great library!
I had some trouble getting my Vitek VG128647 display to work glitch free with an Arduino DUE in parallel mode. It took quite a while to figure out that on this display the PSB pin is not broken out, but is on an unmarked jumper. But after changing the jumper I finally have the display working well in software SPI mode using the following constructor:
U8GLIB_ST7920_128X64_1X u8g(18, 16, 17); // SPI Com: SCK = en = 18, MOSI = rw = 16, CS = di = 17
In soft-serial mode, the display's refresh rate is quite slow (around 4FPS). While I can work with that, the problem is that with the picture loop in the main loop, it slows the main loop down to about the same +- 4 loops a second, since the picture loop has to execute first before the loop continues. (Using 4X mode makes very little difference).
My question: is there any way to prevent the U8glib code from blocking the execution of other code in this way? I'm building audio applications, and I've had some success by making use of the DUEs numerous timers and placing my other code (button checks, analog readings, updating of LEDs) in interrupt routines. But I seem to only get away with adding two more interrupt routines in addition to the main audio one, before the audio starts to degrade.
I understand that using hardware SPI will speed up the refresh rate, but my second problem is that I can't seem to get hardware SPI to work. I used the following constructor:
U8GLIB_ST7920_128X64_1X u8g(10); // chip select
I used the SCK an MOSI pins on the DUE's SPI header, and also tried with a number of different chip select pins, but no luck so far. Am I forgetting something?