Hexiwear team to share code, project ideas, trick and tips

HexiWear OLED bitmap tool

04 Aug 2016

I wrote a Windows program to take a 96x96 bitmap and convert it to 16bpp and format it into a string of comma delimited hex values for use in your HexiWear programs. Enjoy.

https://github.com/CapperLabs/HexiWearOLEDbitmapTool

Let me know how you like it. It's not a bitmap editor, however, you need to make your bitmap with another program like MSPaint, and then flip it vertically before loading it into my program. Be aware there will be an extra comma at the end of the hex values before the closing bracket that needs to be removed before compiling.

Scott

11 Aug 2016

Thank you very much Scott for creating this BMP to Hex tool converter, I have not tested it yet, but it will be very useful for Hexiwear user community.

12 Aug 2016

The library SSD1351_SPI found online here in the NeatGUI library uses 32bbpArgb format, so I've added 12 more output formats to the program.

/media/uploads/Capper/img_0398.jpg

15 Aug 2016

Great assistance in developing MBed support for the Oled. Have you got a minimal MBed demo program for it ? NeatGUI as such does not claim to support it.

16 Aug 2016

Hi Scott,

Great job on the tool! Also if you are adding Bitmaps with the Kinetis Design Studio Project on github, the OLED driver in the project expects the first 6 bytes to be padded with header information.

For example a 96 by 96 pixel image will have the following header

gui_weatherStation_cover_bmp[18438] = { 0x00,0x10, 0x60,0x00, 0x60,0x00, rest of array is the actual bmp data };

16 Aug 2016

Tisham Dhar wrote:

Great assistance in developing MBed support for the Oled. Have you got a minimal MBed demo program for it ? NeatGUI as such does not claim to support it.

Hi Tisham I looked at your GPSIMU_Hotshoe project and it seems like your OLED isn't working.

There are a few things you are missing.

1. For MISO set it to NC as PTB23 is used for the Reset of the KW40 Bluetooth Chip.

2. The OLED needs to be powered on by setting PTC13 to 1. Initialize in the beginning of main.cpp DigitalOut oled_POWER(PTC13,0);

3. The RST pin (PTE6) needs to be toggled during the OLED init sequence. Initialize in the beginning of main.cpp DigitalOut oled_RST(PTE6,0);

The Kinetis Design Studio Project does something like this before calling the SSD12351_SPI::open() function

oled_POWER = 0; wait_ms(1); oled_RST = 0 ; wait_ms(1); oled_RST = 1 ; wait_ms(1); oled_POWER = 1;