<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[How to display picture]]></title><description><![CDATA[<p dir="auto">Hello,</p>
<p dir="auto">How do I display a picture to the screen (M5Stack) from the SD-Card.<br />
I'm looking for an example.<br />
Thanks for any help.</p>
<p dir="auto">Cheers,<br />
Jan</p>
]]></description><link>https://community.m5stack.com/topic/1251/how-to-display-picture</link><generator>RSS for Node</generator><lastBuildDate>Sat, 18 Apr 2026 13:26:51 GMT</lastBuildDate><atom:link href="https://community.m5stack.com/topic/1251.rss" rel="self" type="application/rss+xml"/><pubDate>Sat, 24 Aug 2019 17:49:48 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to How to display picture on Sun, 03 May 2020 18:36:15 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://community.m5stack.com/uid/1718">@powersoft</a> Maybe you find it interesting to know that there is a way of compiling a picture into your code so that you do not need an SD-card. This could make your solution more simple.</p>
<p dir="auto">To do:</p>
<p dir="auto">Download the UTFT-library from Rinky Dink Electronics (<a href="http://www.rinkydinkelectronics.com/library.php?id=51" target="_blank" rel="noopener noreferrer nofollow ugc">http://www.rinkydinkelectronics.com/library.php?id=51</a>)<br />
Extract the download and use the Tools\Imageconverter565.exe to convert the image to a .c file (select AVR board)<br />
Open the .c file and change the line '#include &lt;avr/pgmspace.h&gt;'   into  '#include&lt;pgmspace.h&gt;'<br />
Insert the following lines in the file (the values should be the same as the image, 320x240 is max for M5Stack):<br />
const uint16_t imageWidth = 320;<br />
const uint16_t imageHeight = 240;<br />
Rename the .c file into .h   (e.g. logo.c into logo.h) and place the file in the folder where the .ino-file for your project is<br />
In your Arduino-program add the following line in the top  (or the other filename you have chosen)<br />
#include &lt;M5Stack.h&gt;<br />
#include "logo.h"<br />
In your Arduino-program add the following line in the 'setup'-function:<br />
M5.Lcd.setSwapBytes(true);<br />
In your Arduino-program add the following line in the place where you want to show the image:<br />
M5.Lcd.pushImage(0, 0, logoWidth, logoHeight, logo);</p>
<p dir="auto">I have included a link to a small demo-file on the following page:<br />
<a href="https://info.kosternet.nl/doku.php?id=publiek:m5stack" target="_blank" rel="noopener noreferrer nofollow ugc">https://info.kosternet.nl/doku.php?id=publiek:m5stack</a></p>
]]></description><link>https://community.m5stack.com/post/8500</link><guid isPermaLink="true">https://community.m5stack.com/post/8500</guid><dc:creator><![CDATA[kosternet]]></dc:creator><pubDate>Sun, 03 May 2020 18:36:15 GMT</pubDate></item><item><title><![CDATA[Reply to How to display picture on Mon, 26 Aug 2019 07:05:31 GMT]]></title><description><![CDATA[<p dir="auto">Hey <a class="mention plugin-mentions-user plugin-mentions-a" href="https://community.m5stack.com/uid/1718">@Powersoft</a> you can try this tutorial which <a class="mention plugin-mentions-user plugin-mentions-a" href="https://community.m5stack.com/uid/79">@Dimi</a> wrote some time ago on our forums, I believe the information should still be relevant <a href="http://forum.m5stack.com/topic/49/lesson-1-2-1-lcd-how-to-create-image-array/2" target="_blank" rel="noopener noreferrer nofollow ugc">http://forum.m5stack.com/topic/49/lesson-1-2-1-lcd-how-to-create-image-array/2</a></p>
]]></description><link>https://community.m5stack.com/post/5297</link><guid isPermaLink="true">https://community.m5stack.com/post/5297</guid><dc:creator><![CDATA[lukasmaximus]]></dc:creator><pubDate>Mon, 26 Aug 2019 07:05:31 GMT</pubDate></item><item><title><![CDATA[Reply to How to display picture on Sun, 25 Aug 2019 06:25:57 GMT]]></title><description><![CDATA[<p dir="auto">I use the arduino envoirment.</p>
]]></description><link>https://community.m5stack.com/post/5289</link><guid isPermaLink="true">https://community.m5stack.com/post/5289</guid><dc:creator><![CDATA[Powersoft]]></dc:creator><pubDate>Sun, 25 Aug 2019 06:25:57 GMT</pubDate></item><item><title><![CDATA[Reply to How to display picture on Sat, 24 Aug 2019 18:04:22 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://community.m5stack.com/uid/1718">@powersoft</a> said in <a href="/post/5284">How to display picture</a>:</p>
<blockquote>
<p dir="auto">Hello,</p>
<p dir="auto">How do I display a picture to the screen (M5Stack) from the SD-Card.<br />
I'm looking for an example.<br />
Thanks for any help.</p>
<p dir="auto">Cheers,<br />
Jan</p>
</blockquote>
<p dir="auto">In what programming language?</p>
]]></description><link>https://community.m5stack.com/post/5285</link><guid isPermaLink="true">https://community.m5stack.com/post/5285</guid><dc:creator><![CDATA[ajb2k3]]></dc:creator><pubDate>Sat, 24 Aug 2019 18:04:22 GMT</pubDate></item></channel></rss>