NEW GUIDE: PyPaint Drawing Program In CircuitPython #CircuitPython #Paint #PyPortal #PyBadge #AdafruitLearningSystem @DAstels

https://learn.adafruit.com/pypaint/

A new guide in the Adafruit Learning System: PyPaint Drawing Program In CircuitPython

The latest crop of smart displays from Adafruit, including PyPortal, PyBadge and PyGamer, have screens and an input method.  This makes them all ideal for running a simple paint program using our favorite introductory language – CircuitPython. And if you received AdaBox 012, you have a PyGamer in your hands!

CircuitPython is a programming language based on Python, one of the fastest growing programming languages in the world. It is specifically designed to simplify experimenting and learning to code on low-cost microcontroller boards. Here is a guide which covers the basics:

You will want at least CircuitPython version 4.1 (possibly a beta version of it) for maximum graphics performance, it’s FAST!

All platforms have a palette on the left edge of the screen that contains 8 colors and two brush sizes. selecting a color changes the active drawing color, while selecting one of the brush cursors will change the drawing cursor as well as the size of the brush: 1 pixel square or 3 pixels square.

On the PyPortal, Use the touch screen to control the cursor. A simple stylus works really well for this. Touch on the palette to change the drawing color or brush. Touch anywhere else to place a spot of the current drawing color at the touched location. Moving while touching the screen will leave a trail. Recall that each time a change in touch location is detected, a line is drawn from the previous location to the new one. That means that if you move faster than the update cycle, you’ll get a polygon because points are relatively far apart. You can see this in the photo below. If you want a smooth curved line, move slowly.

circuitpython_IMG_3868.jpg

circuitpython_IMG_3867.jpg


Have an amazing project to share? The Electronics Show and Tell is every Wednesday at 7:30pm ET! To join, head over to YouTube and check out the show’s live chat and our Discord!

Join us every Wednesday night at 8pm ET for Ask an Engineer!

Join over 38,000+ makers on Adafruit’s Discord channels and be part of the community! http://adafru.it/discord

CircuitPython – The easiest way to program microcontrollers – CircuitPython.org


New Products – Adafruit Industries – Makers, hackers, artists, designers and engineers! — New Products 11/15/2024 Featuring Adafruit bq25185 USB / DC / Solar Charger with 3.3V Buck Board! (Video)

Python for Microcontrollers – Adafruit Daily — Python on Microcontrollers Newsletter: A New Arduino MicroPython Package Manager, How-Tos and Much More! #CircuitPython #Python #micropython @ThePSF @Raspberry_Pi

EYE on NPI – Adafruit Daily — EYE on NPI Maxim’s Himalaya uSLIC Step-Down Power Module #EyeOnNPI @maximintegrated @digikey

Adafruit IoT Monthly — The 2024 Recap Issue!

Maker Business – Adafruit Daily — Apple to build another chip at TSMC Arizona

Electronics – Adafruit Daily — SMT Tip – Stop moving around!

Get the only spam-free daily newsletter about wearables, running a "maker business", electronic tips and more! Subscribe at AdafruitDaily.com !


No Comments

No comments yet.

Sorry, the comment form is closed at this time.