if you want to save the screenshot just for a showcase you can use the Embedded Wizard Prototyper, here you can find the documentation of it:
Embedded Wizard Prototyper
I think in your case you want to take a screenshot of the current view on your target?
For that I would use the LCD framebuffer.This buffer holds the view that is also present on your LCD screen and this you can convert into a picture. The start address is coded in "ewmain.c" (#define FRAME_BUFFER_ADDR). Depending on the format that you want to save the picture it is able to convert this buffer. In case that you want to save it as bitmap, you can forward the data to the USB API without converting.
I can successfully take screenshot from LCD framebuffer.
Since the EW color format is RGB565 , I have converted into RGB888 and save it as bitmap.
Now,I want to replace the current view by the image in USB device.
I thought just do the reverse operation with screenshot.
But something strange, I will show in the following image.
1. Before Image https://imgur.com/x6CLGcu
the image in USB device is a white bitmap
2. After Image https://imgur.com/OfJLqxm
Is there any suggestion ? thanks!
Hi , Tim
yes, I want to load the saved bitmap into the framebuffer
I converted the RGB565 to RGB888 by doing the following steps:
color = ((*ptr & 0xf800) >> 11 ) << 3; // R color = ((*ptr & 0x07e0) >> 5 ) << 2; // G color = (*ptr & 0x001f) << 3; // B
I converted the RGB888 to RGB565 by doing the following step:
data = (_buf >> 3 ) << 11 | (_buf >> 2 ) << 5 | (_buf >> 3 ) ; // _buf = R , _buf = G , _buf = B
For example, a pixel 0xE8ECE8 (RGB888) will be converted to 0xEF7D
I followed your conversation - just some ideas:
Ask Embedded Wizard
Welcome to the question and answer site for Embedded Wizard users and UI developers.
Ask your question and receive answers from the Embedded Wizard support team or from other members of the community!