Created Sun, 29 Jul 2012 18:41:33 +0000 by noxus
Sun, 29 Jul 2012 18:41:33 +0000
I was able to run de demo sketches that demonstrate the OLED functionality on my MAX32 + Basic I/O Shield combination. So far so good! What I now want to do is program the OLED display directly via MPLAB (not using the MPIDE environment)
Is there an OLED library available for using the OLED display on a Basic I/O Shield together with the MAX32 directly from MPLAB?
I noticed that there is such a library available for using the Pmod OLED display to be used with a Cerebot MX4 but we would like to use the OLED on a Basic I/O Shield directly in MPLAB.
When looking at how the OLED is connected to the PIC32MX microcontroller I noticed that the pins don't map with the SPI lines on the PIC32MX. At first I was looking at using the library for the PmodOLED to communicate with the OLED display on the Basic I/O shield but since this library makes use of the SPI functionality of the PIC microcontroller, this will not work...
Is there already a library available for directly controlling the Basic I/O Shield OLED display from MPLAB? If not, do the experts on this board maybe have a suggestion how I can best proceed with this. Probably I have to change the library so that the correct IO lines are being used and that a soft SPI implementation is going to be used instead of the hardware SPI implementation.... Until now I have only done some hobby projects with 8-bit PIC microcontrollers. This is the first time I will be using the PIC32MX but I'm looking forward to it :)
Thanks all for the help and suggestions!
Mon, 13 Aug 2012 22:03:27 +0000
If you look at the source code for the IOShieldOLED library currently on the Digilent web site, you will find that pretty much all of the library code is written in C and is in the utility folder in the library folder. The library object class is just a thin wrapper over the C functions.
When I originally wrote the OLED library, I wrote it as C functions and did the development in MPLAB. I then gave that set of functions to one of our interns who wrote the wrapper class and packaged it up to make the library. The Digilent PmodOLED library is essentially the same and was derived from the same underlying set of functions.
I have since re-written the PmodOLED library, moved the actual code into the C++ object methods and gotten rid of the C modules, but this version hasn't made it onto our web site yet.
You should be able to take the C modules from the utility folder and use them to drive the OLED on the Basic I/O Shield without too much difficulty. That's how it worked when I originally developed it.
Gene Apperson Digilent