0

Install python library to program feather with Python
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

Install python library to program feather with Python

by jtamsen on Sat May 08, 2021 1:07 pm

Hello community,

I am trying to program a feather from Python, NOT to use circuitpython or micropython, but pretty much install libraries under python to control feathers just like installing standardfirmata and then controlling arduinos from python with pyfirmata. ( I see blinka works only for single board computers, not feathers)

Is it possible to program feathers from Python with such libraries under windows or linux. ( I do not see support for any micro other than arduino uno,mega, for pyfirmata either, assuming we could use samd21 or samd51 with pyfirmata).
Thanks!

https://realpython.com/arduino-python/

jtamsen
 
Posts: 4
Joined: Thu May 06, 2021 2:08 pm

Re: Install python library to program feather with Python

by blnkjns on Sun May 09, 2021 4:41 am

Somewhere along the way some library has to say command X in pyhton is command Y in machine language for say the Feather M4.
The whole concept of Micro/Circuit Python is that you have a selection of precompiled libraries in machine language for the specific board preloaded on that board. I can't imagine where this Python to machine code would happen in your perfered workflow. How do you see that?
I didn't know Firmate, but a quick look into this gives me the idea this is obsolete/targeted at a very small niche:
https://github.com/firmata/protocol
It uses MIDI-like messages to interface classic Arduino's like the UNO with Python. That is severily limited (try bit-banging some NeoPixel data!), and the computer runs the Python, not the board. So no stand-alone operation!
I think if you want to stick with Python, really give CircuitPython a go.
If your goal is to have your computer talk with lights in the house or model trains or something like that, I would just stick with the UNO and the MEGA, as those are prefect for those ON/OFF kind of messages.

blnkjns
 
Posts: 615
Joined: Fri Oct 02, 2020 3:33 am

Re: Install python library to program feather with Python

by jtamsen on Sun May 09, 2021 10:40 am

Thanks for your time and feedback,
going back to the original question, I am trying to automate power supply, oscilloscope, etc with pyserial and to control the microcontroller (feather) from Python all on the same environment, not to program circuitpython, then to go back to python for the instruments, but to control instruments and microcontroller from the same environment just like standardfirmata.
I researched more some hours yesterday and found out I have to add some boards definitions under 'boards.h' for standardfirmata in order to add samd21 or samd51, but I would like to install circuitpython under regular python, I am still open to possible answers for several days and then I will close this post, if not possible.

Thank you Community!!

jtamsen
 
Posts: 4
Joined: Thu May 06, 2021 2:08 pm

Re: Install python library to program feather with Python

by blnkjns on Sun May 09, 2021 12:42 pm

I would split things: for controlling stuff via your computer with Firmata, stick to the UNO or if you need more outputs the MEGA.
If you want to do more powerful stuff, also stand-alone, run Circuitpython on an M4.
Running Firmata on an M4 is like doing cul-de-sacs with your Ferrari.

blnkjns
 
Posts: 615
Joined: Fri Oct 02, 2020 3:33 am

Re: Install python library to program feather with Python

by jtamsen on Thu May 13, 2021 12:17 pm

I found out that what I want to do is to install circuitpython under Cpython.

Is not clear on ADAFRUIT website how to do it......it could be confusing since there are many steps about how to install libraries on raspberry py, but not a clear sequence like step1,2,3.... but I see basically you can control FT232H from Cpython in ubuntu for example, those steps are clear, I want todo the same but for feathers microcontrollers, is any engineer from ADAFRUIT watching this post, the question is clear now, how do you install circuitpython on Cpython. ( all libraries needed in a clear sequence)

This info is very useful for the community,

Thanks!!

jtamsen
 
Posts: 4
Joined: Thu May 06, 2021 2:08 pm

Re: Install python library to program feather with Python

by jtamsen on Sat May 22, 2021 2:12 pm

jtamsen wrote:I found out that what I want to do is to install circuitpython under Cpython.

Is not clear on ADAFRUIT website how to do it......it could be confusing since there are many steps about how to install libraries on raspberry py, but not a clear sequence like step1,2,3.... but I see basically you can control FT232H from Cpython in ubuntu for example, those steps are clear, I want todo the same but for feathers microcontrollers, is any engineer from ADAFRUIT watching this post, the question is clear now, how do you control feather microcontrollers on Cpython. ( all libraries needed in a clear sequence)

This info is very useful for the community,

Thanks!!

jtamsen
 
Posts: 4
Joined: Thu May 06, 2021 2:08 pm

Please be positive and constructive with your questions and comments.