Comment by andoando

Comment by andoando 7 days ago

23 replies

What's hard about programming an ESP32?

I plug the USB in and its the same as an Arudino, can even use Arduino IDE, but I prefer VS Code with the PlatformIo extension. You can even use the Arduino Library (#import <Arduino.h>

And a ESP32C board with wifi/bluetooth is like $8 https://www.amazon.com/Seeed-Studio-XIAO-ESP32C3-Microcontro... (and thats from amazon, on alibaba its like couple bucks if that)

As a side note, you can power this with your IPhone's USB C which was surprisingly cool.

nunobrito 7 days ago

It is basically the same thing, don't understand either why it would harder.

The only thing is to add the ESP32 module on the addons since it doesn't come enabled by default. Arduino isn't good for projects with more than 5 source code files, it is an awful IDE beyond the basic things you can pack on a single source code file.

Always had so many difficulties handling the IDE defects, basically it can crash when starting and every now and then will just refuse to upload the firmware. The other part are libraries, really difficult to setup all the needed libraries for larger code bases.

On that sense, Visual Code with PlatformIO went far beyond. Just open the project there and the libraries are taken care. The connection to boards is more robust. I'm not so sure how to feel with this sale to Qualcomm, it just feels that it is going there to die.

Quite the difference from the early days where Arduino had such energy and the tools would bring almost anyone into microntrollers with such ease.

  • lovehashbrowns 7 days ago

    As a complete beginner to hardware stuff, I do find the Arduino Cloud thing to be pretty compelling. Being able to push out updates over the cloud is nice! Buuuut.. once I'm mostly done with a project, there's just no need at all for it anymore. The Arduino I'm using for a receipt printer is just sitting there and now the cloud bit doesn't do anything for me.

    And the problem I have is that ESP32s aren't much more difficult to set up nowadays, are wildly cheaper, and I'm soso excited to start messing around with ESP-NOW which I don't think Arduino has? But having like 10 ESP32s for messing around freely is more valuable than the cloud thing for me. And there are some super fun projects for ESP32 also like the Cheap Yellow Display thing. I ordered what I thought was one display, except it was 3, and I thought I would have to provide my own ESP32s but nope, they come with them. And these three CYDs were cheaper than a single Arduino it's actually crazy.

    • nunobrito 6 days ago

      Yeah, ESPnow is pretty good. I'm using it more than LoRa because all ESP32 come with it and is really cheap, whereas with LoRa is all the trouble with an additional module that costs 3x more than an ESP32.

      That yellow display is pretty good. I've built a tiny operating system for it, it is an unbelievable hardware for the cost of the material.

  • kbar13 7 days ago

    agree. when arduino ide first came out it was great (for the times). and to be fair at that time vscode was not a thing. but it's a big ? why arduino did not just go all in on vscode once it was clear where the market leader in IDE was headed

    • spookie 7 days ago

      Well, it's a bad idea to rely on Microsoft in some manner

      • creshal 7 days ago

        VS Code has enough momentum by now that Microsoft couldn't kill it even if it wanted to. And a lot of the arduino-side work would involve creating/tweaking LSPs to their ideosyncrasies and making IDE-agnostic compilers... all of which is IDE agnostic and makes Arduino more useful to all users.

        And, worst case, they could take it all to IntelliJ or other IDE vendors and quickly spin out an Arduino-branded IDE that isn't raw sewage.

      • schlauerfox 7 days ago

        VSCodium is a de-microsoft'd version available. Still missing some of the features that aren't licensed the same.

        • spookie 7 days ago

          Missing "some features" is an understatement. I really value what those folk are doing, but the lack of extensions such as the ones for C/C++ from Microsoft really just make it subpar.

yatopifo 7 days ago

I got introduced to microcontrollers through the original Arduino board. It took me only a year to switch to bare metal atmega/attiny (zero external components!), and to this day, those are my favourite micros despite all their shortcomings. Theyare extremely well documented, and them being 8-bit with a simple instruction set makes it very easy to learn assembly (or even opcodes). At the same time, they are compatible with 5V logic (and can be abused!) which makes them almost perfect for beginners.

Would I have been able to learn assembly with ESP32? Probably not. You couldn't even find proper manuals for ESP8266 back in the day because they either didn't exist, weren't in English or weren't released to the general public...

atoav 7 days ago

Well which board do you select then? ESP32 boardfiles do not come with the Arduino application per default.

Sure, to you and me this may seem trivial, you paste the URL into the prefs, but there are people who will get stumped by this and with an Arduino there is one less step you can forget, not know about or do wrong.

As someone who teaches those things at an University level I can assure you that does make a difference for at least 50% of my students if I let them try to do this unguided.

  • andoando 7 days ago

    I don't quite remember, but I don't think I installed anything extra for ESP32.

    But PlatformIo with VSCode has it and was extremely easy to setup.

    • numpad0 7 days ago

      You must have done File -> Preferences... -> Additional board manager URL -> OK, and clicked Tools -> Board -> Board manager... -> esp32 by Espressif Systems -> Install.

      And that's like, I think installing VSCode itself can be more scary, so...

      • estimator7292 7 days ago

        If youbuse PlatformIO everthing Just Works out of the box. Acquiring board files and such is handled behind the scenes

numpad0 7 days ago

(psa: Arduino IDE 1.x works flawlessly for tons of non-Arduino boards, including Pi Pico, ESP32 devkits, etc. Most Arduino users aren't even able to consider processor implementation specifics, never signed an NDA in life, and don't even know where generated binaries go, so those boards are almost "binary compatible" with each others, all in _very_ positive sense)

j45 7 days ago

It's not about whether it's hard for you.

Lots of people don't program.

More people don't know how to program than do know how to program.

In that way, just because I can't imagine it being hard, doesn't mean I understand everything there is to understand.

This creates a gap and opportunity for products to make technology more approachable for the majority, instead of the minority (programmers).

Making things accessible to more people instead of less people seems to increasingly be the way.

  • freehorse 7 days ago

    Programming an ESP32 using the arduino ide is no harder than programming an arduino using the arduino ide. The only difference is that you can find an ESP32 for much much cheaper.

  • andoando 7 days ago

    But there really is no difference in difficulty in setting it up?

    Besides I don't get this argument considering you're setting up an arduino/esp32 to program/learn to program a microcontroller...

  • osigurdson 7 days ago

    >> Lots of people don't program.

    Cathy Woods says we are all programmers now, so this shouldn't be a problem anymore.