Draw Bitmap Directly Command / Protocol

LK/ELK/VK/PK/OK/MX/GLK/EGLK/GVK/GLT Series

Moderators: Henry, Mods

Post Reply
mbjorge
LCD?
Posts: 9
Joined: Fri Jun 20, 2014 9:13 am

Draw Bitmap Directly Command / Protocol

Post by mbjorge » Fri Jun 20, 2014 9:22 am

I am uncertain as to the exact bytes that I need to be sending in order to using the draw bitmap directly command for the glk19264-7t-1u.

I know that I send the command and the x,y,w,h values. I am confused as to what I need to send for the actual bitmap (the data). The manual says to reference the file upload protocol, but this includes sending command prefix, upload commands, reference IDs, and size parameters, which I feel like I don't need to send? Based on another post (viewtopic.php?f=1&t=3931&p=19276&hilit= ... tly#p19276) it is unclear if the display echoes back the data sent and if I need to send confirmation bytes.

Can anyone tell me if this is correct:

--BEGIN--
0xFE (Command prefix)
0x64 (Draw bitmap directly command)
[X]
[Y]
[W]
[H]
Data[0]
<Display echoes Data[0]>
0x01 (Confirmation Byte)
Data[1]
<Display echoes Data[1]>
0x01 (Confirmation Byte)
...
Data[n]
<Display echoes Data[n]>
0x01 (Confirmation Byte)
--END--

Thanks!

Tino
Matrix Orbital
Matrix Orbital
Posts: 158
Joined: Wed May 22, 2013 9:04 am
Location: Matrix Orbital

Re: Draw Bitmap Directly Command / Protocol

Post by Tino » Fri Jun 20, 2014 9:52 am

Hi mbjorge,

If you are uploading a bitmap then you should refer to the Upload Protocol.

But if you are drawing directly like in you example then you do not need a confirmation byte.
The data of the bitmap consists of the Header which is the width and height of the bitmap. Your comand should look like:

0xFE
0x64
[X]
[Y]
Data

For example to draw the happy face bitmap in the manual example your command should look like:

0xFE
0x64
[X]
[Y]
Data[0x05,0x04,0x50,0x22,0xE0]

This will write the bitmap to the display to where ever the X,Y coordinates are.

Thank you for posting on our forums.
Regards
Martino
Martino DeLeon
Matrix Orbital
Technical Support Representative

Post Reply

Who is online

Users browsing this forum: No registered users and 13 guests