After anxiously awaiting arrival of the Embedded Pi board, I was (unfortunately) not able to take a look at it for quite some time. The description of the board piqued my interest -- I can see all sorts of possibilities for it. My initial task was to use the examples provided to exercise the ePi and get a feel for the development flow required.
The Embedded Pi has three modes of operation:
- The STM32 Standalone Mode, where the ePi is configured strictly as an STM32 board. In this configuration, the STM32 is mapped to the pinout for Arduino shields.
- The RasPi mode, where the ePi serves as a bridge between the RasPi and the Arduino shield;
- The ST/Adapter Mode with the RasPi communicating to the STM32 via UART, and the STM32 is mapped to the Arduino shield.
I will be evaluating the ePi in all three modes, but first I need to set up the environment required to program it ..
Unboxing the Embedded Pi, the package contained
- The Embedded Pi board
- A USB Cable for linking it to a PC
- A CDROM with the CooCox tools.
I opted to download the CooCox software from there website (here) using their CoCenter tool. By using CoCenter, all that I had to do was click on "Install" and the product was downloaded and installed automatically. Hard to beat that for easy installation.
However, there are a couple of "gotchas" in their software: First, it's Windows-only. This was somewhat disappointing as most of the larger semiconductor companies - TI, Microchip, and NXP to name a few -- are offering Linux and Mac versions of there development tools. Yes, there is plenty of literature available regarding developing for the STM32 on Linux or Mac -- but I have never been able to get anything to work correctly yet. The second issue, and it's a minor one, is that CoIDE requires a separate installation of GCC/Arm to function. Embest did provide an appropriate link, and I was able to get the CoIDE tool setup and configured fairly quickly.
The next hurdle was to actually get a program into the board. I initially followed the directions here to program the ePi via the RasPi serial port. Note that the article says towards the end:
"If a prompt of “None” always appears, redo step 1 (press BOOT0 to reset the STM32)."; this is incorrect .. it should be "Hold BOOT0 while resetting the board" or words to that effect.
Unfortunately, no matter what I tried (different baud rates, attaching a ground, etc) I could not get the ePi to reliably program. In fact, the board had to be repeatedly reset to get it to program at all.Once I got frustrated with that approach, I re-read the User Guide, which very clearly states: "Since Embedded Pi has no debugger onboard, an external JTAG/SWD debugger is needed to
program Embedded Pi in the External Debugger Mode, like J-Link and CoLinkEx.". It would have been nice to have included the SWD on-board (not uncommon) but Oh, well.
So, I ordered the CoLinkEx from Newark (here); the product arrived and functioned as designed and I was able to get a test program onto the board fairly quickly.
With that done, I was ready to try the CooCox examples; Part 2 will cover programming the ePi in STM32 Standalone Mode.
Note: In the interest of completeness, I attempted to examine the CD-ROM that was included with the ePi; nothing I had (Windows, Linux, or Mac) would read it ... my conclusion is that the CD-ROM was defective.