I have used the Arduino IDE very successfully and am very happy with how it works. But …
With the Raspberry Pi I create a few ssh sessions and write code with nano. This doesn’t seem the most productive to me, but it does work. I understand the vast differences between loading code into an ATMega328P and running Python script on a Linux computer.
I have also looked at the Raspberry Pi GUI development interface. The limitation is the need for a screen, keyboard and mouse. Also, the Pi can be very slow when using multiple windows to research a project.
For those who develop Python script for the Raspberry Pi, I would like to know if there is a better way.
When I’m working on a Python script for the Raspberry Pi, which I have been doing a lot of lately, I use both a PC and a Pi side by side. I look up any reference on the computer, and have the pi setup with a keyboard/mouse/display and a write my code on there using an editor. Browsing the web is pretty demanding on the Pi and will slow you down a bit.
Thanks.
I thought the side by side would be the way to go.
Unfortunately my work space is split. Another screen keyboard and mouse will not fit on my PC desk.
But, I recently set up an old PC in the workshop, that might become my development area.
If you are looking for more of a power-user setup, then download Atom Editor (it’s free, and a great editor to get familiar with). It has syntax highlighting, collapsable code, lots of plugins, designed exactly for this type of stuff.
Install the Atom package for FTP-Remote, then explore the readme for guides.
The TL;DR, press CTRL+Space to open the FTP server manager, configure your master password, then add your SFTP settings for your Pi. An example:
Then you can “twist” the arrow down to open a connection and explore the entire RPi. From there, it’s native editing of files (double click to open, save will update the file directly on the RPi).
I code on my Linux box. Thonny is fine for this sort of stuff. I use FileZilla to copy the Python script to the Raspberry Pi and ssh to connect and restart services that run the scripts. I have 7 Pi units and use the same code on some of them.
I’m not going back to using any variant of an Arduino as code updates for an infield unit fully wired is impractical.