News:

Let's find out together what makes a PIC Tick!

Main Menu

Falling in love with C

Started by shantanu@india, Dec 22, 2022, 07:38 AM

Previous topic - Next topic

shantanu@india

#40
Quote from: CPR on Jan 28, 2023, 11:35 PM
Quote from: shantanu@india on Jan 28, 2023, 01:18 PMFanie,
Forget Arduino.... use Thonny with micropython for ESP.
Writing code is a cakewalk.

MicroPython runs interpreted. That's *not* the best choice for anything embedded. Python itself (imho) is an abomination, a truly utterly horrible invention. But if it's an easy fix & it works ok for you with the results you want, then hey :-) Just take the effort to learn C++ it'll pay off.
Its obvious that you have neither used Python nor micropython in any serious programming application. Otherwise I'm sure you wouldn't have made this sweeping statement.
Imho python is a great invention and just at this moment it runs the world!! AI modeling and machine learning have been made very easy by Python.
Talking about interpreted language how does it really matter when the processor is running at 80Mhz+ speed?? ESP doesn't have any OS like Raspbian etc. and only the main.py file gets executed after being converted into bytecode.
C/C++ would always remain the mother languages. But Les has applied the extra layer  on C++ to develop his magical Proton. Don't we use it?
Regards
Shantanu

RGV250

QuoteTalking about interpreted language how does it really matter when the processor is running at 80Mhz+ speed??
Im my opinion this is how the rot started with Windows programs. Thoughts like "It does not matter about the bloat and rubbish code as the PC has loads more memory and is faster" spring to mind. Remember small and compact DOS programs anyone?

As for Python, I find it absolutely awful and the fact it might be used in AI does not fill me with confidence as in my opinion most of AI is rubbish anyway.

Bob

shantanu@india

#42
Bob,
Have you used google search engine?
It is AI... Nothing but AI!!
Anyway let's stop this discussion(and thread!) from an endless iteration. I never intended it to waver so far from the original topic.
Regards
Shantanu

RGV250

QuoteHave you used google search engine?
It is AI... Nothing but AI!!

You are not selling it that well, apart from the fact that if I put UK in the search I still get offers from lots of other countries so not that intelligent at all. If it was really intelligent it would filter these out.
Also this "artificial intelligence" does not give you the best results but the results from the companies that have paid them to give the highest result, just proving that even artificial intelligence is corruptable I suppose.

Bob
 

Gary Scott

Quote from: shantanu@india on Jan 29, 2023, 11:02 AM
QuoteMicroPython runs interpreted. That's *not* the best choice for anything embedded. Python itself (imho) is an abomination, a truly utterly horrible invention. But if it's an easy fix & it works ok for you with the results you want, then hey :-) Just take the effort to learn C++ it'll pay off.
Its obvious that you have neither used Python nor micropython in any serious programming application. Otherwise I'm sure you wouldn't have made this sweeping statement.
Imho python is a great invention and just at this moment it runs the world!! AI modeling and machine learning have been made very easy by Python.
Talking about interpreted language how does it really matter when the processor is running at 80Mhz+ speed?? ESP doesn't have any OS like Raspbian etc. and only the main.py file gets executed after being converted into bytecode.
C/C++ would always remain the mother languages. But Les has applied the extra layer  on C++ to develop his magical Proton. Don't we use it?

According to Harry Fairhead author of "Programming the Raspberry PI Pico in MicroPython" Python is 100 times slower than "C" on the Pico.

CPR

#45
Quote from: shantanu@india on Jan 29, 2023, 11:02 AM
Quote from: CPR on Jan 28, 2023, 11:35 PM
Quote from: shantanu@india on Jan 28, 2023, 01:18 PMFanie,
Forget Arduino.... use Thonny with micropython for ESP.
Writing code is a cakewalk.

MicroPython runs interpreted. That's *not* the best choice for anything embedded. Python itself (imho) is an abomination, a truly utterly horrible invention. But if it's an easy fix & it works ok for you with the results you want, then hey :-) Just take the effort to learn C++ it'll pay off.
Its obvious that you have neither used Python nor micropython in any serious programming application. Otherwise I'm sure you wouldn't have made this sweeping statement.
Imho python is a great invention and just at this moment it runs the world!! AI modeling and machine learning have been made very easy by Python.
Talking about interpreted language how does it really matter when the processor is running at 80Mhz+ speed?? ESP doesn't have any OS like Raspbian etc. and only the main.py file gets executed after being converted into bytecode.
C/C++ would always remain the mother languages. But Les has applied the extra layer  on C++ to develop his magical Proton. Don't we use it?

I haven't and I never will. Why? Because (imho) it's an abomination for anything seriously "embedded" It's also a truly horrible language. Which I have tried (PC). So, consider: You have a processor running a program, running another program line by line? How is that a good thing? The argument of "well we have <insert your favourite processor here> and they're just so much faster" - isn't a justification. Why? Because it negates the whole advantage of faster devices. You're contributing to bloatware culture and simply put, (imho) you're being lazy in your general programming approach. "Embedded" shouldn't equate to "bloat" It should be quick, speedy, elegant, efficient, nicely written, simple, uncomplicated and reliable. The "pedal to the metal" not some raspberry pi child project -  and? making use of whatever devices unfettered speed is available, without some lousy stupid interpreter in the way. I mean, come on, seriously??? But, if what you produce makes you and your customers(?) happy because it's "easy" for you to turn to Micropython coding and selling them whatever it is you make, then hey. That's your choice. Power to your elbow. For me? You'll never convince me otherwise ;-) Back on topic. Yes for C++

Fanie

Hi guys,  Since I was here last time -

I did my first project using the ESP32 on Arduino, did the C thing (my brother helped me) and got it done.
When I started it was very confusing, especially where what codes fitted into and these platforms sitting on one another..
The C wasn't so bad if someone just point a few things out for you and explain how it fits together.

Ah, and the ESP32 is great, 32 bit, you can do a lot with it and it has verything inside, and can run at 148MHz clock  :o .  I'm using the S3. Very impressed.