
New to ARM? Here you can take a look over the actual ARM development scenario and find the cheap way to start learning about this amazing 32 bit powerful microcontroller based in my own experience.
Introduction
As always I will try to be direct and simple, ARM is so widely used due to some factors, like: low energy consumption (vital for mobile devices), high performance and easily found in the market, allied with a good price compared to any other 32 bit microcontroller.
Due to this characteristics, with the time, ARM was being adopted by the industry, like cellphones manufacturers and so many others. The popularity made the world focus over it, and then things like Linux passed to be supported, as well as its open-source tools and so on. Now, we can find models with dual, quad or even eight cores! and if you still reading this, is because by some way, the ARM convinced you to take a look too.
ARM Model Choice
The board in particular is this, it's small, simple and has all you need, 3.3v voltage regulator, 8 Mhz crystal and the whole chip pins mapped on 2.54" DIP pin headers, so I could easily access all the chip pins, using wires and a breadboard. I recommend you to start with an ARM Cortex-M3 too, because it's very popular and has a lot of information on internet. The Cortex-M0 is "weak", Cortex-M4 expensive and Cortex-M1 seems to be unpopular. So luckily I did the right choice.
ARM Programmer

So to start I need order a programmer/debugger too? no! now the strong point of STM, they ship every ARM Cortex-M3 with an embedded bootloader, then you can program it using a serial connection, through the UART1 peripheral, here you can se how. But, of course, if you wish debug your system, soon or later you will need more than a bootloader.
ARM Development

But luckily in the ARM field it's a little better, due the popularity and Linux support, there are many open-source libraries, which provides easy ways to use the ARM peripherals and external chips or modules, like LCD screen, bluetooth, wifi and RTC.
ARM and CMSIS

The STM CMSIS library is called "Standard Peripheral Library", and to use it in your project, first you need set the USE_STDPERIPH_DRIVER define on the compiler flags. The content of the CMSIS library is simple, each function basically has a series of direct registers operations (bare metal), so if you want learn how to program using the registers directly, the CMSIS libraries can be a good start point, just get the desired function and look how it's implemented.
The STM CMSIS library comes with documentation and examples, furthermore, they provides the STM32Cube tool, which allows through a graphical user interface, the selection of peripherals to be used and set the function of the configurable pins, then it generates the starting code to start develop your application, but unluckily it not support the STM32 F103 series yet, that was my ARM model choice.
The STM CMSIS library comes with documentation and examples, furthermore, they provides the STM32Cube tool, which allows through a graphical user interface, the selection of peripherals to be used and set the function of the configurable pins, then it generates the starting code to start develop your application, but unluckily it not support the STM32 F103 series yet, that was my ARM model choice.
Conclusion
For starters I recommend use and read about CMSIS libraries and Keil MDK, that consist of compiler and IDE called uVision, the full features can be seen here, as said, it's free, just with a 32k of flash/program limit, it's CMSIS compliant, has a package manager, which automatically gets the latest libraries from the manufacturer, plus a simulator and user-friendly interface. FreeRTOS can be used within the 32k limit and you can see how, on this link. And think about a debugger too, I recommend the Ulink2.
0 comentários :
Post a Comment