You are reading a single comment by @Gordon and its replies. Click here to read the full conversation.
  • Hi,

    Great! It might be worth reading the Build Process Readme if you haven't already.

    1) What is the boardname_af.csv used for?

    This is for STM32 boards, and you can ignore it (at least initially). It's part of the pin definitions stuff that works out jspininfo.c.

    On STM32, to get a certain peripheral to work on a certain pin, you have to set that pin's 'alternate function' register to the right number. The CSV file helps the STM32's board.py file fill in the correct numbers for each peripheral on each pin.

    2) Right now the target compiles, but the output binary is 0 bytes. Any pointers to what might have happened?

    On other platforms you generally have some assembly code that gets pulled in that contains the real entrypoint. That initialises the stack pointer, sets up memory, etc, and then finally calls main. It's possible you didn't include that? If so, GCC would have just optimised everything out.

    I'd focus on trying to get a simple 'hello world' EFM32 project compiling and working with a Makefile and arm-none-eabi-gcc. Once that's done it's probably a lot easier to get the same thing working with the Espruino Makefile, and to then modify your main.c to start to initialise Espruino itself.

    3) Which IDE are you guys usually using when developing the target code?

    I use Eclipse, and build just by running make (using arm-none-eabi-gcc) on Linux.

    I'd do the same if I were you (using your favourite editor) - trying to use some other toolchain you're just making life a lot harder for yourself!

About

Avatar for Gordon @Gordon started