If you're reading this, guide you're probably already very familiar with the products Adafruit offers for CircuitPython. I think it might be good to take a moment to explain what the difference is between the Python that you're writing in DrawBot and the Python that you would write for your CircuitPython hardware project.

In a nutshell — the language is the very same! But, the vocabulary can be a little bit different.

Think of it this way, whether you're speaking with your tailor or your butcher you might be using the English language, but you'll need to know to ask for a Filet Mignon from one and ask for a French Cuff from the other. The language for the rest of the sentence you use is still the same, but some of the terms will need be a specific to the trade. Mix the two up and neither will know what you're asking for!

The same goes for using Python in DrawBot and using CircuitPython, the language is the same but DrawBot won't understand the kinds of function names that are specific to CircuitPython (DrawBot has never heard of DigitalInOut or a pin.direction), and the same goes the other way (CircuitPython would have no way to draw a rect or set a fill color).

However, being comfortable with how Python works right here in DrawBot will put you many steps ahead for getting started with using Python in a completely different context. The fact that they both use variable names, strings, lists, numbers, for loops and all the other mechanics of the language will be essentially the same in both environments.

This guide was first published on Dec 14, 2018. It was last updated on Mar 08, 2024.

This page (Python in DrawBot vs CircuitPython) was last updated on Mar 08, 2024.

Text editor powered by tinymce.