Forums

STM32 ARM toolset advice?

Started by John Speth October 7, 2008
On 2008-10-07, Anton Erasmus <nobody@spam.prevent.net> wrote:

> Keil has been bought by ARM, and AFAIK they now use the > compiler from ARM. Apparently this compiler generates the best > code for ARM's CPUs. GCC Generates quite good code for the ARM > these days. The biggest drawback is the use of newlib. Rowley > provides a nice IDE with GCC, and their own library, which > removes the one disadvantage of using GCC. Their product is > also available for Windows and Linux.
I'd have to second that opinion on newlib. It's fine if your codespace in measured in MB (or even in hundreds of KB). But newlib seems to put more emphasis on portability and completeness than on small code size. -- Grant Edwards grante Yow! I'm RELIGIOUS!! at I love a man with visi.com a HAIRPIECE!! Equip me with MISSILES!!
Grant Edwards wrote:

> I've heard nothing but good things (from both Windows and Linux > users) about Crossworks from Rowley: > > http://www.rowley.co.uk/arm/index.htm > > For some targets, Rowley has their own compilers, but for ARM, > they use GCC. &#2013266080;The IDE and debugger are Rowley products. >
I second that. We use it with the Olimex ARM-USB-OCD http://elmicro.com/files/olimex/arm-usb-ocd.pdf Heinz
In message <81ene4hsatqaphkmp01cikmpk9l7ana9qi@4ax.com>, Anton Erasmus 
<nobody@spam.prevent.net> writes
>On Tue, 7 Oct 2008 08:01:31 -0700, "John Speth" <johnspeth@yahoo.com> >wrote: > >>(Not to start a tools war but) >> >>I'm about to start a project that will use the STM32 ARM from ST. IAR and >>Keil both supply high quality tool sets for the STM32. I've used both >>toolsets' evaluation copies. I believe I'd be satisfied buying any one over >>the other. >> >>Can anyone make any comments why one might be better than the other? >> >>At this point, it's a flip of the coin. I'd like to hear some practical >>opinions of current users to help tip the scales. >> > >Keil has been bought by ARM, and AFAIK they now use the compiler from >ARM. Apparently this compiler generates the best code for ARM's CPUs.
Well other compilers claim to be as good. Being a RISC HW designer does not make you a good compiler writer. There are other equally good compilers.
>GCC Generates quite good code for the ARM these days.
But not as good, out of the box as the commercial ones out of the box.
> The biggest >drawback is the use of newlib.
There are other drawbacks.
>Rowley provides a nice IDE with GCC, >and their own library, which removes the one disadvantage of using >GCC. Their product is also available for Windows and Linux.
-- \/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\ \/\/\/\/\ Chris Hills Staffs England /\/\/\/\/ \/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/
"Grant Edwards" <grante@visi.com> skrev i meddelandet 
news:i8KdnYvrX_7RHXbVnZ2dnUVZ_rvinZ2d@posted.visi...
> On 2008-10-07, John Speth <johnspeth@yahoo.com> wrote: > >> (Not to start a tools war but) >> >> I'm about to start a project that will use the STM32 ARM from >> ST. IAR and Keil both supply high quality tool sets for the >> STM32. I've used both toolsets' evaluation copies. I believe >> I'd be satisfied buying any one over the other. >> >> Can anyone make any comments why one might be better than the >> other? > > In my experinece IAR compilers are good products. Except for > the licensing. I avoid dongles and license servers if at all > possible. > >> At this point, it's a flip of the coin. I'd like to hear some >> practical opinions of current users to help tip the scales. > > I prefer GCC, since it doesn't require dongles or license > servers, and it's available for something besides MS-Windows. > It's free too, but that's a minor factor compared to be chained > to MS-Windows and a dongle. > > -- > Grant Edwards grante Yow! Half a mind is a > at terrible thing to waste! > visi.com
The gcc Dhrystone benchmarks published by someone on the ST Forums are not really impressive. IIRC, 32 Dhrystone MIPS when running with a fairly late gcc compiler at 72 Mhz. There was a discussion with an ST employee, and he promised to come back but never did. If I were you, I would get some 30 day free licenses, from ARM & IAR and compare the code size/execution time with gcc, before I goahed. -- Best Regards, Ulf Samuelsson ulf@a-t-m-e-l.com This message is intended to be my own personal view and it may or may not be shared by my employer Atmel Nordic AB
>>>In my experinece IAR compilers are good products. Except for >>>the licensing. I avoid dongles and license servers if at all >>>possible. >> >> IAR have dongles OR server OR node locked. > > Forgive me, there are 3 annoying choices instead of just 2. :) > >>>> At this point, it's a flip of the coin. I'd like to hear some >>>> practical opinions of current users to help tip the scales. >>> >>>I prefer GCC, since it doesn't require dongles or license >>>servers, >> >> You buy a compiler based on the method of locking it to a machine? > > It's one consideration. > >> I tend to look at it's primary purpose and see how good it is. > > If the compiler refuses to run after you replace a hard-drive > or an Ethernet card, everything else is sort of moot. >
I can vouch for that this can be an issue. Upgraded my hard disk drive this summer, and since the IAR licensing scheme then needs another key. You can transfer a key from the old system, to the new system, but BOTH have to be running. You would want to Start a transfer on HDD#1 and store the transfer information to file #1. Reboot on HDD#2 and use file #1 to start accepting the transfer generating file #2 Reboot again on HDD #1 and complete the transfer, generating file # 3 Reboot again on HDD #2 and complete the transfer using file #3 Since the transfer on both machines cannot be handled temporarily for reboots, you CANNOT transfer a license to a new hard disk, unless you have another Windows machine handy, - and then you have to do the license transfer twice! Finally, IAR provided fresh license keys but the same week, my motherboard fried and both the CPU and the motherboard was replaced by HP, so I could not even install the new licenses. Only running size limited compilers at the moment. Don't have any working licenses right now. I am sure that this will be sorted out, but If I was on a hard timeschedule this would be frustrating.
>>>and it's available for something besides MS-Windows. >> >> Is that relevant? > > It is to some people, yes. > >>>It's free too, >> Myth. > > Really? > >>> but that's a minor factor compared to be chained to MS-Windows >>> and a dongle. >>
-- Best Regards, Ulf Samuelsson ulf@a-t-m-e-l.com This message is intended to be my own personal view and it may or may not be shared by my employer Atmel Nordic AB
In article <Teidnds8cOsyOXbVnZ2dnUVZ_gCdnZ2d@posted.visi>, 
grante@visi.com says...
> On 2008-10-07, Chris H <chris@phaedsys.org> wrote: > > >>In my experinece IAR compilers are good products. Except for > >>the licensing. I avoid dongles and license servers if at all > >>possible. > > > > IAR have dongles OR server OR node locked. > > Forgive me, there are 3 annoying choices instead of just 2. :) > > >>> At this point, it's a flip of the coin. I'd like to hear some > >>> practical opinions of current users to help tip the scales. > >> > >>I prefer GCC, since it doesn't require dongles or license > >>servers, > > > > You buy a compiler based on the method of locking it to a machine? > > It's one consideration. > > > I tend to look at it's primary purpose and see how good it is. > > If the compiler refuses to run after you replace a hard-drive > or an Ethernet card, everything else is sort of moot.
Then perhaps the USB dongle licensing would work better for you. I've used the IAR ARM toolset with usb dongle on three different computers without problems.
> > >>and it's available for something besides MS-Windows. > > > > Is that relevant? > > It is to some people, yes. > > >>It's free too, > > Myth. > > Really? > > >> but that's a minor factor compared to be chained to MS-Windows > >> and a dongle. > > > > Religious bias noted. > > I don't see how it's "religious".
No---just a bias. I have no particular problem with dongles, since most often I use them all on the same computer that has lots of free USB ports in the back. Almost all my analysis tools, as well as IAR ARM and ICC430 run under WinXP, so getting running GCC-ARM, that I was forced to use for another project, means either running GCC-ARM in a VirtualBox Ubuntu emulator, or toting a separate Linux laptop on business trips. I've managed to get the code development done, but I'm still cursing the day I was told to use Linux in a hard real-time system! Only the fact that it runs on a 300MHz StrongArm chip makes it feasible! I may soon see if the Dell Mini-9 running Ubuntu will handle the GCC-ARM toolset and my source files. That would give me a bit of hardware redundancy in the field. Mark Borgerson
> >
In article <81ene4hsatqaphkmp01cikmpk9l7ana9qi@4ax.com>, 
nobody@spam.prevent.net says...
> On Tue, 7 Oct 2008 08:01:31 -0700, "John Speth" <johnspeth@yahoo.com> > wrote: > > >(Not to start a tools war but) > > > >I'm about to start a project that will use the STM32 ARM from ST. IAR and > >Keil both supply high quality tool sets for the STM32. I've used both > >toolsets' evaluation copies. I believe I'd be satisfied buying any one over > >the other. > > > >Can anyone make any comments why one might be better than the other? > > > >At this point, it's a flip of the coin. I'd like to hear some practical > >opinions of current users to help tip the scales. > > > > Keil has been bought by ARM, and AFAIK they now use the compiler from > ARM. Apparently this compiler generates the best code for ARM's CPUs. > GCC Generates quite good code for the ARM these days. The biggest > drawback is the use of newlib. Rowley provides a nice IDE with GCC, > and their own library, which removes the one disadvantage of using > GCC. Their product is also available for Windows and Linux. > >
One of the biggest problems I ran into with GCC-ARM when using the linux libraries for the TRITON boards, is that floating point operations are executed as kernel interrupts (Undefined Instruction generating jumps to a floating point emulator, I think.) I think it turned out to be several times slower than the IAR floating point library that runs in user mode. I suppose it makes a big difference whether your ARM code is going to run under Linux or on the bare silicon. All my IAR experience is on ARM7TDMI without an OS, and all my GCC experience is on a StrongArm chip under linux. I'd love to transition to an RTOS with either system, but haven't found the free time to get either MicroC/OSII or FreeRtos running with either set of hardware. Mark Borgerson
On 2008-10-07, Mark Borgerson <mborgerson@comcast.net> wrote:

>> If the compiler refuses to run after you replace a hard-drive >> or an Ethernet card, everything else is sort of moot. > > Then perhaps the USB dongle licensing would work better for > you. I've used the IAR ARM toolset with usb dongle on three > different computers without problems.
I had been running the IAR demo version under Win2K on a virtual machine using Qemu, but I was unable to get the USB dongle to work with Win2K/Qemu. AFAICT from the documentation, it should have worked, but it just wouldn't. So then I had to go in search of a "real" windows machine into which I could plug the dongle. I ended up using the company printer/scanner server.
> No---just a bias. I have no particular problem with dongles, > since most often I use them all on the same computer that has > lots of free USB ports in the back. > > Almost all my analysis tools, as well as IAR ARM and ICC430 > run under WinXP, so getting running GCC-ARM, that I was forced > to use for another project, means either running GCC-ARM in a > VirtualBox Ubuntu emulator, or toting a separate Linux laptop > on business trips.
All my other tools run on Linux, so being forced to find a Windows machine to run IAR was a similar hassle for me. If the "powers that be" had chosen something like Rowley that wasn't windows-specfic, I wouldn't have had to do so.
> I've managed to get the code development done, but I'm still > cursing the day I was told to use Linux in a hard real-time > system!
Windows would have been a better choice?
> Only the fact that it runs on a 300MHz StrongArm chip makes it > feasible! > > I may soon see if the Dell Mini-9 running Ubuntu will handle > the GCC-ARM toolset and my source files. That would give > me a bit of hardware redundancy in the field.
The ARM/gcc developers kits we ship with our products work on either Windows or Linux hosts (though I must admit they work better on Linux hosts) -- but we're not using Linux as the target OS. -- Grant Edwards grante Yow! I always have fun at because I'm out of my visi.com mind!!!
"Mark Borgerson" <mborgerson@comcast.net> wrote in message news:MPG.2355722479c1065e989919@newsgroups.comcast.net...
> In article <81ene4hsatqaphkmp01cikmpk9l7ana9qi@4ax.com>, > nobody@spam.prevent.net says...
>> Keil has been bought by ARM, and AFAIK they now use the compiler from >> ARM. Apparently this compiler generates the best code for ARM's CPUs. >> GCC Generates quite good code for the ARM these days. The biggest >> drawback is the use of newlib. Rowley provides a nice IDE with GCC, >> and their own library, which removes the one disadvantage of using >> GCC. Their product is also available for Windows and Linux. >> >> > One of the biggest problems I ran into with GCC-ARM when using the > linux libraries for the TRITON boards, is that floating point operations > are executed as kernel interrupts (Undefined Instruction generating > jumps to a floating point emulator, I think.) I think it turned > out to be several times slower than the IAR floating point library > that runs in user mode.
And given that the IAR floating point library is one of the slowest available, that is quite slow indeed. Wilco
In article <DdmdnU0TN83OS3bVnZ2dnUVZ_hqdnZ2d@posted.visi>, 
grante@visi.com says...
> On 2008-10-07, Mark Borgerson <mborgerson@comcast.net> wrote: > > >> If the compiler refuses to run after you replace a hard-drive > >> or an Ethernet card, everything else is sort of moot. > > > > Then perhaps the USB dongle licensing would work better for > > you. I've used the IAR ARM toolset with usb dongle on three > > different computers without problems. > > I had been running the IAR demo version under Win2K on a > virtual machine using Qemu, but I was unable to get the USB > dongle to work with Win2K/Qemu. AFAICT from the documentation, > it should have worked, but it just wouldn't. So then I had to > go in search of a "real" windows machine into which I could > plug the dongle. I ended up using the company printer/scanner > server. > > > No---just a bias. I have no particular problem with dongles, > > since most often I use them all on the same computer that has > > lots of free USB ports in the back. > > > > Almost all my analysis tools, as well as IAR ARM and ICC430 > > run under WinXP, so getting running GCC-ARM, that I was forced > > to use for another project, means either running GCC-ARM in a > > VirtualBox Ubuntu emulator, or toting a separate Linux laptop > > on business trips. > > All my other tools run on Linux, so being forced to find a > Windows machine to run IAR was a similar hassle for me. If the > "powers that be" had chosen something like Rowley that wasn't > windows-specfic, I wouldn't have had to do so. > > > I've managed to get the code development done, but I'm still > > cursing the day I was told to use Linux in a hard real-time > > system! > > Windows would have been a better choice?
For the flight control system??? Not likely. ;-)
> > > Only the fact that it runs on a 300MHz StrongArm chip makes it > > feasible! > > > > I may soon see if the Dell Mini-9 running Ubuntu will handle > > the GCC-ARM toolset and my source files. That would give > > me a bit of hardware redundancy in the field. > > The ARM/gcc developers kits we ship with our products work on > either Windows or Linux hosts (though I must admit they work > better on Linux hosts) -- but we're not using Linux as the > target OS.
I've learned to work with Linux as the host for the compiler and libraries. I don't like it as the target OS for the embedded system. Before I got the GCC-ARM system running in the VirtualBox emulator, I would edit the source on a shared directory using Codewarrior on the PC. I would then open a telnet session to run the make file to compile the code. Having to carry two laptops on trips was a true PITA, since both were fairly low-end HP systems and were not exactly slim and lightweight! Before my next trip I hope to get the GCC-ARM and VirtualBox working on the WinXP laptop and have a $350 Dell Mini-9 as GCC backup and internet appliance. Mark Borgerson