3

After a two year experience of ATMEL's SAM mcu I decided to move on STM32 microcontrollers. I choosed to begin with STM32F410RB. After a lot search on the internet I found two free IDE, Atollic TrueSTUDIO and SW4STM32. I've both installed them and I see no difference between of them. I also installed CubeMX extension for code generation for hardware periperal drivers, I think is correspond to ATMEL's ASF. At this point I have two questions.

  1. What's the main difference between of two IDEs above that I didn't notice yet?
  2. How can I enable autocomplete while typing? AtmelStudio does this and is extremely usefull but in TrueSTUDIO and SW4STM32 I need to hit Ctrl+space everytime to wakeup this feature and it's a little annoying.
MrBit
  • 1,973
  • 4
  • 27
  • 54

2 Answers2

2

huh, never heard of these two. Generally, you don't need a specific IDE for your Chip manufacturer – they are just ARM microcontrollers, and as long as your IDE is not restricted to a specific manufacturer (AtmelStudio probably is), they'll work with any MCU that is an ARM.

Now, of course, manufacturer versions of IDEs come with tools to generate initialization code, do things like estimate power usage and so on, but you can find these features to varying degrees in the big embedded IDEs, too.

There's actually quite some choice here. I'm kinda oldschool, and do my programming in the OS Text editor of my choice, build and flash images with Makefiles and run GDB by hand for debugging, but I recon that's not necessarily the way to go for bigger projects.

So, the large competitors here are

  • Keil (keil can, iirc, even be used free for STM32)
  • IAR workshop
  • ARM's own DS-5

and a lot of free tools, and I think it woul dbe worth mentioning

  • CoIDE
  • MCU on Eclipse

I'd go for Eclipse, if you've ever used that before. There's neat installation tutorials and it's got all the nice autocomplete, type inspection, debugging features already coming with it. Eclipse is a very "mighty" IDE platform, and is very broadly used for a lot of different targets, be it Java development, C++ for Servers, PHP for websites, or C for microcontrollers. It's very modular, so you get a pretty mature editor with very nice code tools, and nice debugger integration and so on. This particular Eclipse-based setup also comes with STM32 project templates, IIRC.

Basically, you can use any IDE that support GCC / GDB as compiler – the free (as in speech and beer, and both is good being free) GCC suite is practically the "native" compiler for the ARM architecture. You'll just have to configure your favorite IDE to use arm-none-eabi-gcc / -gdb instead of your host's default GCC and GDB binary :)

Marcus Müller
  • 88,280
  • 5
  • 131
  • 237
  • 2
    TrueStudio and SW4STM32 are just Eclipse + GCC/GDB with a windows installer. That's probably why the OP can't tell the difference. – Jon Apr 22 '17 at 12:14
  • aaaah now I see. So I'm basically also suggesting the same :) – Marcus Müller Apr 22 '17 at 12:15
  • I agree rolling your own setup is better though. TrueStudio is quite buggy and slow. Good for doing helloworld stuff when you are learning, but quickly becomes frustrating. – Jon Apr 22 '17 at 12:20
1

Generally I would recommend SW4 (OpenSTM32).

  1. Easy import from CubeMx. I do not personally use HAL (usually only bare registers programming) but when I create the Cube project I get most up to date CMSIS files for my uC.
  2. It works very well. I have done many large projects using Eclipse + plugin, without any problems.
  3. Its free and it has a great community of users
  4. Is officially supported by STM.

You can of course make your own DIY configuration. If you need the newest toolchain I would recommend Freddy's BleedingEdge toolchain (but you will have to compile gcc, libraries and and tools).

0___________
  • 2,458
  • 10
  • 25
  • +1 for not using HAL libraries , but who can you use the Cube Mx generated files without HAL libraries ? ( the created project by MX already forces use to use their interrupt service routines and initialization functions ) – ElectronS Apr 22 '17 at 15:34
  • Why not using HAL libraries? I haven't found any other libraries for low level drivers. – MrBit Apr 22 '17 at 16:22
  • 1. CubeMx generates HAL dependencies but it can be easily removed (just couple of clicks). I actually use modified HAL only for USB and Ethernet. All other peripherals - it is much too heavy. 2. What another library - you do not need any libraries for 90% of projects. STM32 are very easy to program using just using the hardware registers (easier than learning HAL mega structures and functions) – 0___________ Apr 24 '17 at 08:59