Why did I completely stop using PlatformIO

Hello,

To give you an example, I am a big fan of FreeRTOS, which I consider not less as the linux for embedded systems. (best proof is AWS bought it… )

It is almost impossible to debug a real time app without symbolic debugger, bkpts (at least one… ) and memory/register access. I am designing a small device to drive multiple neopixel strips simultaneous and synced light sequence. Tried a 1st version with Nano, another with Trinket M0 and this is by far the easiest way to do it, just because I can debug it thanks to PIO debugger and Jlink.
I use FreeRTOS/Arduino for M0 setup, which works fine, needless to say I’m already far away from Arduino IDE in this case. Ideally AVR symb debug integrated into PIO would do the job, I understand AVR is limited in debugging features by construction using debugWire, but this would be the ideal way for me in this case.

2 Likes

People like you! Thank you so much for amazing support and valuable time! :blush:

I read ALL topics but with a long delay :frowning: Sorry. It’s very important for me to understand how people use PlatformIO and which problems they have. You save my time and I can spend more time for PlatformIO Core and other sub-projects in our ecosystem.

The great example of “my delay” is PlatformIO 4.3 - platformio-core/HISTORY.rst at develop · platformio/platformio-core · GitHub.
I’ve finally implemented 3 feature requests dated 2017 year :slight_smile: They are related to a new Device Monitor. It’s cool with Filters subsystem! It mostly was needed for ESP8266/ESP32 to provide real time exception decoding.

3 Likes

Im trying to build in rtos as well. Using a max of atduino libraries.
But not getting anywhere… Could jou share your setup please

Sorry rtos share setup please came one item to low

I use a modified FreeRTOS_SAMD21 port by Scott Briscoe for my adafruit trinket M0. Modified to accomodate SAMD21E18A in error_hooks.h otherwise it will raise a compilation error dur to processor.
look at GitHub - BriscoeTech/Arduino-FreeRTOS-SAMD21: A port of FreeRTOS that runs on Arduino Samd21 boards to look at it.

Then I use arduino libraries (Serial… ). I had to modify Adafruit_Neopixel to replace the mallocs (led buffers memory allocation free() and malloc() by port_Free and pv_PortMalloc() to make sure heap won’t crash with stack. And that’s pretty much all.

Planning to update this port to last FreeRTOS versions when I’ll need recente features like static Tasks, but this porting is sufficient so far.

To summarize, the essential is
1-to modify a couple of lines in a errors_hooks.h FreeRTOS source file, to accomodate to the target and that’s it. Other
2- Make sure your heap will stay safe and won’t crash your stack. ReeRTOS got some tools to check it, like the xPortGetFreeHeapSize() function that will warn you long enough before crash if needed.

For reference, here is my platformIO.ini specific AMTEL SAM part

[env:adafruit_trinket_m0]
platform = atmelsam
board = adafruit_trinket_m0
framework = arduino
board_build.f_cpu = 48000000L

…the rest has nothing to do with FreeRTOS…

Enjoy!

Still quite the case with lack of support documentation and more bugs than software making it completely unpractical and bad even near the simple little arduino IDE but I guess the aggressive that persists now in YouTube and else where will enlarge the user count enough to accelerate the idea which makes sense and embedded developments easier but as for now too buggy to be useable(Might also have something to do with the changing nature of VSCode).

I admit I may develop too simple projects to hit the bugs, but I haven’t yet seen anything I couldn’t solve either by reading the docs and tinkering with my Platformio installation, or by asking here on the forum. The bugs are always out there, but making it completely unpractical and bad even? Come on.

1 Like

Hi @MikeLemo,

EDITED: For spelling and grammar. Sigh!

Not sure why you would say that, there’s plenty of documentation available, have you looked at Your Gateway to Embedded Software Development Excellence — PlatformIO latest documentation lately? If you want a (large) PDF for offline reading, scroll down the left sidebar until you hit bottom.

Down there you will see “Read the Docs V:Latest”, click “V:Latest”. Under “Downloads”, click on “PDF” to get you to this URL: https://docs.platformio.org/_/downloads/en/latest/pdf/ which will download the latest version of the docs. Currently 2,843 pages. A little light bedtime reading! :wink:

All software has bugs. If you spot one, and want it fixing, tell someone. Have you done so? However, be prepared to be advised that sometimes, a bug in “PlatformIO” is not what it seems. PlatformIO uses Atom/VSCode as an IDE and they have bugs too. Intellisense is a bit of a nightmare in VSCode, for example, but is getting better.

Can you list a few of the “more bugs than software” you refer to and maybe someone will get them sorted to your satisfaction. Thanks.

The Arduino IDE, love it or loathe it, is for beginners really. It’s a great way to get into writing C/C++ code for various microcontrollers using a standard language. Hell, you can even write plain AVR C++ in the IDE if you want. Personally, I found it great for starting off with (back in 2010) but I’ve grown up since then and I now find it a little unwieldy.

I tried to attempt to use Atmel Studio, but that was Windows only and I’m on Linux. Eclipse was too big, too slow and too buggy on my 10 year old (and more) laptop with 2 cores and 8 Gb RAM.

QT Creator and Code:Blocks were tried, PlatformIO can generated project files for these IDEs. QT Creator didn’t like the AVR compiler for some reason and I didn’t pursue it. Code::Blocks was fine, and worked pretty well but C::B isn’t (wasn’t) being supported back then so I moved on.

There wan’t much else at the time, so I ended up on Atom running PlatformIO IDE and have since migrated to VSCode as I really didn’t like Atom. I haven’t looked back. I have been known to use PlatformIO Core in the command line on many an occasion.

It works for me, and I used it to write my first published book, and I’m using it for my next one too. It’s hard enough writing a book for over 2 years, without having to fight with your development tools. I didn’t have to!

I think you are saying that there’s a lot of PlatformIO on YouTube? (English isn’t my first language, I’m a Scotsman! :wink:) To be honest, there’s not much really. A couple of new "getting started " videos from “Dronebot Workshop” and “Gary Explains” but most of the other stuff is years old.

I agree that it’s a good idea to get people into embedded development, and whatever makes it easier is a good thing surely. Unfortunately, you then go on to say:

See above. What bugs are you hitting? Let us know and we can get them fixed.

And, yes, it might be the ever moving target that is VSCode, but if that’s the case, surely piling the blame onto PlatformIO isn’t the way to go? (I’m a database admin and developer by trade, everyone blames the database when things go wrong. It’s never the developer’s code, always the database. :frowning_face:)

Cheers,
Norm.

1 Like

PlatformIO has been brilliant for us, I’ve used countless proprietary IDE’s for MCU’s which always seem to be buggy and unsupported to smaller customers, terrible Eclipse based approaches which vary from version to version and again have poor support.

PlatformIO support has always been timely, (thanks guys), we use VS code for all our work now and when we dive into MCU’s PlatformIO is there to make our lives easier,

Being able to test the same code on multiple MCU’s just by retargeting is a huge benefit, keep it up!

David

4 Likes

I am new in the field of microcontrollers and thus I am testing all these platforms.
Atmel Studio, AurduinoIDE, CodeVision, CodeBlocks and PlatformIO.
I have gone through all the comments above right from “istvanb”. In my opinion it is up to the user’s thinking. When you are using open source, you have to be patient for the reply from community members.

After using all the IDEs mentioned above, I appreciate that PlatformIO is a better platform (if not the best). I too face difficulties in using it, but I did not raised the question/query on the community platform. As I am new to this line (currently I am developing commercial applications using VB and RDBMS) I myself try to resolve the problems and somewhat succeed.

Of course, you face problems when you are very much new to any platform, but slowly you get familiar with it.

So, I request all of the community members (particularly seniors and experienced on PlatformIO) not to waste unproductive discussions, and help the juniors to become seniors and further they can help their juniors.

I have just joined the community and will be using this platform regularly as I have decided to work on PlatformIO IDE in future.

Thanks but do not mind, if any one take it otherwise.

Best wishes to PlatformIO developers.

2 Likes

Hi
@normandunbar
You are right man. I liked your sense. Carry on.
I would like to have your help as I am absolutely new to microcontrollers.
Thanks and wishes.

1 Like

Feel free to ask questions and I’ll do my best to help. If the matter is off topic for PlatformIO, I’ll take it off line with you directly.

HTH

PS. I’m an Oracle DBA in my day job, RDBMS rule! :wink:

Cheers,
Norm.

Thanks @normandunbar for your reply.
I will and definitely will contact you.
If possible please give me your EMailID.

Thanks once again.

DM sent.

Cheers,
Norm.

istvanb - nonsense…
if you can’t blink the LED with PlatformIO - don’t bother with programming at all

I, who do not understand from a Python, ported SDK-s and Arduino for industrial purposes ( GSM modules, GSM SoC-s, LoRa, PI Pico … etc ) with PlatformIO !!!
I can say that in the critical moments Ivan and the PIO team losed their time and helped - not me, but you
If this is not support - what to talk about…

I feel that is a little harsh. Complete beginners need to be considered as well as those with some or lots of experience. Communities come in all shapes and sizes, with different levels of experience.

Cheers,
Norm.

1 Like

yep - sorry … I meant it’s easy enough
Cheers !

1 Like

No worries.

Cheers,
Norm

Hello I’m from 2022, so how are you today? I’m using PIO and everything is working fine also comfortable with my VSCode. My code looks clean, idk what happened with 2017 past back, but I don’t see any problem so far. Also there are community that answer my question even though it was moderator. I will try my best to promote this PlatformIO mainly in Indonesia.

1 Like

Platformio is garbage one day work other day no work !