Image to Byte array

Use this online image to Byte array tool for converting (monochromatic) bitmaps to data arrays (C++ style). You can use these arrays with programs for embedded systems with microcontrollers to output graphics on monochromatic LCD's or thermal printers (like Arduino with the Adafruit mini printer, which I needed this for). Probably the output also works for graphics monochromatic LCD displays like T6963C, KS0108, SED1335 etc. but haven't tested this yet.

This tool was meant as a quick online version of LCD Assistant, which is Win only. It creates files for use with a C compiler: for AVR, ARM, PIC, 8051 and ohter microcontrollers. You can use it directly with Arduino (tested), or probably any other design environment based on C compiler (not tested).


→ Image will be auto-converted to monochrome
→ Some LCD's & printers require image width to be a multiple of 8 pixels

How to

To convert an image from bitmap file (.jpg/.png/.gif, RGB/Grayscale) to a data array, simply upload it and hit 'Convert'.

This tool uses 8 pixels per byte and will try to auto-convert your image to black & white. It seems to have some problems with images containing indexed colors, so use RGB/Grayscale. Also; I got the best results with the Adafruit printer by using images with a width of a multiple of 8 (eg. 384 pixels wide).


Link to this page: “Image to Byte array”

You can link to this tool using this HTML code. Simply copy and paste it into your page:

<a href="https://dvps.manytools.org/hacker-tools/image-to-byte-array/">Image to C++ Byte array (for Arduino & thermal printer)</a>

If you have any problems using this Image to Byte array, please contact me.


Updates

August 15, 2022

hack stega

Steganography tool fixed (server errors)

The past few weeks you may have seen a server error or two on the steganography tool. These intermittent errors were a byproduct of the recent server move and have now been fixed.

July 15, 2022

Phasing out hosting server after (almost) 10 years

After having been running steadily on the previous server for almost ten(!) years, it became time to retire that machine. So, ManyTools has now been moved to a shiny new hosting cluster. You may/should notice some speed improvements. In case you notice any problems or irregularities I'd be happy if you notify me so I can check on them.

September 27, 2017

Exit Coinhive (in-browser bitcoin mining)

Thank you for your feedback on our (brief) test with browser based bitcoin mining. This seemed like a nice way to support this website, but turned out to be far too much of a burden to our visitors. So we've decided to remove it. Our apologies for the inconvenience it has caused.

August 18, 2017

Migrated to HTTPS

Happy to inform that Manytools is now fully Chrome-62-ready, thanks Google! A secure connection had been due for a very long time. Today we finally got around to upgrading the site to run on HTTPS. – (Starting October 2017, Chrome (version 62) will show a “NOT SECURE” warning when users enter text in a form on an HTTP page, and for all HTTP pages in Incognito mode.)

August 10, 2016

article personal

Who is this person?

Quickly lookup any person by e-mail address or name. Run an instant background check or find contact details & personal records (including public legal records).