Author Topic: So how do you even start working with STM32 without paying an arm and a leg?  (Read 32149 times)

0 Members and 1 Guest are viewing this topic.

Offline zapta

  • Super Contributor
  • ***
  • Posts: 6190
  • Country: us


As Rstofer wrote several times: A Makefile project is as universal as it gets and many IDEs 'import' these just fine.

I should try it one day. What I did in the past is having the ide running my manual make as an external tool.

BTW, lpcxpresso also set the make files which allows also to build from command line, 'make all', etc

 

Offline JPortici

  • Super Contributor
  • ***
  • Posts: 3461
  • Country: it
Trash it and move to NXP LPC

This kind of comment is worse than useless. What exactly would an NXP ARM give him that an ST ARM wouldn't? He's asking for development environment help and by and large that is all completely agnostic to the specific "brand" of part used.  ARM from NXP or ST or Freescale or Nuvoton or Cypress or *anyone* is pretty much the same when it comes to IDE.

That all being off my chest now, I have always preferred the good old command line. vim or Sublime Text for my editor, and gdb (not graphical) for debugging. I've always ended up fighting more with the damned GUI tools than the problem at hand when I've had to use anything Eclipse based, and the various code generators such as Processor (cough)Expert or STM32CubeMX have always been poor at best.
:palm:
Again, NXP gives you a free of charge complete package that you have to download, install and go. which is what the OP probably wanted in the first place, as he is unable to set up a working environment.
Maybe this is useless to you but to me it was just another thing that makes me prefer NXP LPC over ST and many others. (others are for example features per smaller package size, price for lower quantities, better documentation, less messier hal.. but damn i am repeating myself, again.)
I don't have neither the time or the patience to set up the compiler and IDE and keep everything in balance because it breaks at every damn update
 

Offline ez24

  • Super Contributor
  • ***
  • Posts: 3082
  • Country: us
  • L.D.A.
ImgeCraft C Compiler with easy to use debugger. Pro license costs $500, while compiler only license costs $250. PM forum member richardman.
ImageCraft also comes with a Nucleo board as part of their learning kit.  I think the "learning" part is $100 (board, compiler, and book + $50 for their debugger)

https://imagecraft.com/

Also for the cost of a book and a Nucleo board this book explains how to set up a tool chain that works on all three OS systems, all free tools (but by my count 10 of them)

https://leanpub.com/mastering-stm32

(the 65% done is misleading - it currently is over 600 pages)

But it depends on how much an arm and leg costs.

Both authors told me that a STM32 is not suitable for a beginner to MCUs, but since you are not new, one of these might work (if your arm and leg is worth more than $150).  Today I decided that one of my fingers was worth $100 and bought a new saw as not to loose one of them.  Personally I would put the price of one of my arms and leg at over $1,000.  And currently at 30 years, I think the lost of my leg has come to about 300k.

So I would say the loss of an arm and leg would be worth 1/2 million, I do not think there are any solutions over 1/2 million.  So in summary ALL solutions will not cost more than an arm and leg.  I hope you do not amputate yours in the quest of a solution.


YouTube and Website Electronic Resources ------>  https://www.eevblog.com/forum/other-blog-specific/a/msg1341166/#msg1341166
 

Offline voltz

  • Frequent Contributor
  • **
  • Posts: 267
  • Country: gb
I went through the same cycle of trial and error to get a working 'free' environment. It is possible!

Result was Eclipse STM Workbench. And Cube MX for internal pin arrangements.  www.openstm32.org

However, its quirky and takes a bit to get CubeMX to actually do what you want. MX will produce startup code into a blank Workbench project but you can guarantee you need to dive in and make changes by hand. But in the end, the process works and you actually get to write 'your' source code and compile with success. No limits on flash sizes at all. And burn straight to Dev board (like a Disco f7).

This is where i settled and its working with full debugging. Its possible, but definitely not plug and play.
« Last Edit: August 07, 2016, 09:05:09 am by voltz »
 

Offline balu

  • Regular Contributor
  • *
  • Posts: 64
  • Country: de
Hello,

I use the IDE TrueStudio from atolic for STM32 software development. You can get a free version of the tool without restrictions about code size. The tool based on Eclipse and can be used together with STM32CubeMX.

http://timor.atollic.com/

 :-+

 
The following users thanked this post: voltsandjolts, Kilrah

Offline Rolo

  • Regular Contributor
  • *
  • Posts: 206
  • Country: nl
You can take a look at stm32Duino, they are integrating the STM32 into the Arduino environment. Ok, not the best IDE but it gets you going, and you can use your own editor if you like. This does take some learning about bootloaders and STLink programmers but they use the cheap STM32 boards so no big startup costs. It's still work in progress but it works.
Forum : =http://www.stm32duino.com/index.php
Wiki : http://wiki.stm32duino.com/index.php?title=Main_Page
« Last Edit: August 07, 2016, 10:40:29 am by Rolo »
 

Offline rstofer

  • Super Contributor
  • ***
  • Posts: 9889
  • Country: us
When I develop in a Linux environment where the command line tools are readily available, I often just use gedit for the editor and 'make'.  No IDE, just a simple graphic editor and a directory (or directories) full of files.

I'm not as fond of the Windows command line.  Yes, I know I could set up the Windows command line versions of most tools or I could use Cygwin but for some reason, I don't.

And never overlook the power of 'alias'.  It can save a LOT of command line typing.
 

Offline nctnico

  • Super Contributor
  • ***
  • Posts: 26891
  • Country: nl
    • NCT Developments
As Rstofer wrote several times: A Makefile project is as universal as it gets and many IDEs 'import' these just fine.
I should try it one day. What I did in the past is having the ide running my manual make as an external tool.
You don't have to do that. Eclipse for example can deal with make targets directly and even provide environment variables / make options so you can build a project which outputs various binaries from one source by clicking a specific build version. All the errors are also parsed so the source is annotated with the compiler errors (if Eclipse's realtime syntax checking didn't catch them already).
There are small lies, big lies and then there is what is on the screen of your oscilloscope.
 

Offline zapta

  • Super Contributor
  • ***
  • Posts: 6190
  • Country: us
As Rstofer wrote several times: A Makefile project is as universal as it gets and many IDEs 'import' these just fine.
I should try it one day. What I did in the past is having the ide running my manual make as an external tool.
You don't have to do that. Eclipse for example can deal with make targets directly and even provide environment variables / make options so you can build a project which outputs various binaries from one source by clicking a specific build version. All the errors are also parsed so the source is annotated with the compiler errors (if Eclipse's realtime syntax checking didn't catch them already).
Are you talking about make files that are generated automatically by eclipse (as lpcxpresso does) or arbitrary manually written make files that are parsed by eclipse?

I used the IDE parsing of output errors file and line numbers but I think you are talking here about the IDE actually understanding the make files themselves.
 

Offline nctnico

  • Super Contributor
  • ***
  • Posts: 26891
  • Country: nl
    • NCT Developments
No, Eclipse just calls make with the options you provide and then parses whatever the make/compilation process spits out using a so called error parser (ofcourse the error parser used by Eclipse needs to understand the toolchain's output).
There are small lies, big lies and then there is what is on the screen of your oscilloscope.
 

Offline zapta

  • Super Contributor
  • ***
  • Posts: 6190
  • Country: us
No, Eclipse just calls make with the options you provide and then parses whatever the make/compilation process spits out using a so called error parser (ofcourse the error parser used by Eclipse needs to understand the toolchain's output).
OK, this is the external build mode, nothing to do with makefile, your script can build any way you like, with our without a make file. The IDE just parses the error lines.  Done that with slickedit and GCC.
 

Offline richardman

  • Frequent Contributor
  • **
  • Posts: 427
  • Country: us
ImgeCraft C Compiler with easy to use debugger. Pro license costs $500, while compiler only license costs $250. PM forum member richardman.

Note that non-commercial use license for the compiler/IDE is only $50. -NC debugger (it's optional) is another $50.
// richard http://imagecraft.com/
JumpStart C++ for Cortex (compiler/IDE/debugger): the fastest easiest way to get productive on Cortex-M.
Smart.IO: phone App for embedded systems with no app or wireless coding
 

Offline ez24

  • Super Contributor
  • ***
  • Posts: 3082
  • Country: us
  • L.D.A.
ImgeCraft C Compiler with easy to use debugger. Pro license costs $500, while compiler only license costs $250. PM forum member richardman.

Note that non-commercial use license for the compiler/IDE is only $50. -NC debugger (it's optional) is another $50.

Don't forget about your Nucleo and book.   As a dumb ass, I have "looked" at a lot of development boards and in my opinion the Nucleo is the best because of : STM32, linker built in and breakable off, Arduino shield compatible, USB (not serial nor parallel), not JTAG, and recently new.  You do not need external devices to plug into it to program it.  So for an non user, the STM32 looks the best because they have the best development board and dirt cheap (less than an arm and leg)
But in my case I am too dumb to use it and there no books or courses designed for it for real beginners.  Both books say ok for beginners but both authors confess they mean new to STM32 not MCUs.  The OP seems not new to MCUs so my (dumb) suggestion is go with 1. Imagecraft or 2. Mastering STM32  (I made it through Chap 3 by installing 10 programs to blink an LED).  But I am looking at some of the suggestions in this topic but I keep going back to No. 1 because of support.

It is not clear to me that the OP wants to use an STM32 for commercial use?

YouTube and Website Electronic Resources ------>  https://www.eevblog.com/forum/other-blog-specific/a/msg1341166/#msg1341166
 

Offline westfw

  • Super Contributor
  • ***
  • Posts: 4199
  • Country: us
You know, the real answer is that if you're STARTING, then you should probably just put up with the free development environments from the specific vendor (or various other places), even if they are code-size or optimization limited.  When you actually start to run into the limits of the environment, you can make another decision about whether to pay for the next step up, or go looking for something else.  But by then, you won't be so much of a beginner, and you'll have better ideas about what you want or don't need, how the build process works and how vendor libraries get sucked in, and you'll have a least one example of how projects are organized...
 
The following users thanked this post: jancumps

Offline MosherIV

  • Super Contributor
  • ***
  • Posts: 1530
  • Country: gb
Quote
This won't work in China. Average Chinese income is 1/6 of western average, and software sell for higher price (to recover cost due to 95%+ pirate rate). Which means an individual will never be comfort to pay $10k on a compiler.
What you are suggesting is to let the OP to get familiarized with Keil or IAR and get spoiled by the ease of use, then when he runs to its limit, either ditch the copyright creed or spend an arm and a log.
No necessarily.

I agree with westfw. IF they are an ABSOLUTE BEGINNER then it is easier to use the commercial tools because they (mostly) just work with out any fiddling around with setup. That is what an complete newbie needs - something to just get started, not having to learn how to configure the tool, that is a side distraction.

When they have learned more about the target (and host system), then they are in a better place to start to figure out how to configure the free stuff.

Just my thoughts  ;)
 

Offline dannyf

  • Super Contributor
  • ***
  • Posts: 8221
  • Country: 00
If the code size limits or optimization limits aren't binding for an application, are they really "limits"?

This " I don't want to use X because of limits" thinking is weird to me.
================================
https://dannyelectronics.wordpress.com/
 

Offline dannyf

  • Super Contributor
  • ***
  • Posts: 8221
  • Country: 00
Setting up an ide is highly similar, from one to another.

So I really don't understand the struggles so many people seem to have.
================================
https://dannyelectronics.wordpress.com/
 

Offline Sal Ammoniac

  • Super Contributor
  • ***
  • Posts: 1668
  • Country: us
I second the posters who recommend Eclipse with the CDT and ARM add-ons. I put together a set of detailed instructions--if anyone's interested, PM me and I'll send you a copy.
Complexity is the number-one enemy of high-quality code.
 

Offline MosherIV

  • Super Contributor
  • ***
  • Posts: 1530
  • Country: gb
Quote
The OP is not an EE beginner. He is a veteran volt nut, with a BSEE degree (or MSEE, I forgot, he mentioned in another thread).
Also, since ST has free GCC based IDE, and ImageCraft compiler and its libraries are tailored for STM32, why spend $ 5 digits on Keil?
And what's more, there are Atollic and more free or semi-free tools that are more accessible for an individual.
I do not remember that the OP mentioned that they are skilled in engineering. If they are OK at setting up a tool chain, why are they complaining on behalf of beginners?

Why spend money on tools?
Someone needs to support the software tools industry, even if it is only other professionals.
If every body just wants free software, there will be NO software industry. There will be fewer development tools, pushing the boundaries and the world would be a little worse off (in my opinion).
Commercial tools are not aimed at everybody, they are marketed for professional use and professional/corporate users in tern support them.
They must be better in some way than the free alternative or companies would not spend money on them!

If I remember correctly the OP was about why you have to spend so much money in order to get started on STM32.
The answer is you do not have to, there are free alternatives.
There are expensive paid alternatives.
Take your pick.

As a professional embedded SW developer, if I am asked to teach someone about say STM32 development, I am not going to start teaching them about free tools that take time to install and configure, I am going to start with the fastest and easiest tool that gets them going. From my point of view that is the commercial IDEs because they just work out of the box.
(This is just my opinion - like it or not  ;) )

Is Atollic free?
The last time I checked (which was a long time ago) they too had a size limit for their free version.
Incidentally, Atollic is the stupid Eclipse based IDE that got me hating Eclipse. Such a bloody awful debugger.
 

Offline dannyf

  • Super Contributor
  • ***
  • Posts: 8221
  • Country: 00
I agree with the above view.

One has to figure out what ones goal is. If the goal is to learn about the chips at low cost, start with the free but limited commercial ones: they allow you to focus on the learning chip part.

If the goal is about saving money, go after the free tools.

I make a living off of my tools and I simply cannot afford to have them not working for me.

On the flip side, if you have lots of time dicking around, try those free tools.
================================
https://dannyelectronics.wordpress.com/
 

Offline Kilrah

  • Supporter
  • ****
  • Posts: 1852
  • Country: ch
As a professional embedded SW developer, if I am asked to teach someone about say STM32 development, I am not going to start teaching them about free tools that take time to install and configure

Is Atollic free?
The last time I checked (which was a long time ago) they too had a size limit for their free version.

Atollic is free without limits (only advanced features way beyond "beginner" scope e.g. code analysis, advanced debugging require upgrade), comes with tons of examples for many boards, and you can get one running with debug in a couple of minutes and a few clicks...
 

Offline Sal Ammoniac

  • Super Contributor
  • ***
  • Posts: 1668
  • Country: us
Atollic is free without limits (only advanced features way beyond "beginner" scope e.g. code analysis, advanced debugging require upgrade), comes with tons of examples for many boards, and you can get one running with debug in a couple of minutes and a few clicks...

Atollic may be free, but it's as slow as molasses in January and very frustrating to use for debugging. I used to think that Eclipse itself (which Atollic is based on) was slow, but that's not the case. It was only after building my own Eclipse-based development environment starting with the bare-bones Eclipse that I found that it's really fast at debugging. What I don't understand is how a company selling a commercial tool based on Eclipse could have effed it up so badly. And Atollic isn't the only one--I've used several other commercial Eclipse-based tools that remind me of sloths.
Complexity is the number-one enemy of high-quality code.
 

Offline Kilrah

  • Supporter
  • ****
  • Posts: 1852
  • Country: ch
Again that's out of scope, a beginner doesn't need the best, fastest and most convenient tools, he needs some that allow him to get to do something pretty easily, and a chance to try out the various tools that exist, figure out what they do and how they work. It fits that bill pretty well.

Same as on the hardware side a beginner is advised to get a basic pretty cheap scope that may not be the fastest, best nor do everything but will do the job of teaching him how it works and do allow him to work on a few projects, not a high end $15k beast.

The most confusing bit about "how to start on ARM" isn't the lack of easy nor free tools, it's people who keep making it impossible for people to find a starting point by endlessly debating tons of details none of which actually matter in the poor beginner's situation.
 
The following users thanked this post: 3db

Offline andersm

  • Super Contributor
  • ***
  • Posts: 1198
  • Country: fi
Someone needs to support the software tools industry, even if it is only other professionals.
ARM is one of the major funders of the GCC port, so you're supporting its development every time you buy an ARM device.
 
The following users thanked this post: Kilrah

Offline MosherIV

  • Super Contributor
  • ***
  • Posts: 1530
  • Country: gb
Quote
  ARM is one of the major funders of the GCC port, so you're supporting its development every time you buy an ARM device.
Have you tried to raise a bug or support issue with ARM ?

One of the most insiduous issues facing the software industry is the apparent lack of value associated with software. The fact that it is non physical and easy to copy makes it all too easy to dismiss its value. The large amount of free software helps to diminish the value of maintaining teams of people developing and maintaining software. ARM's primary focus is on selling cpu cores via licensing NOT developing software. They do it as a necessary support in order to maintain sales.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf