Build demo application from source?


(Alain Mosnier) #1

Hi,
I could not find a precise answer to this question in the forum.
I received by board about six months ago (if that makes any difference). I haven’t had time to use it so far.
How exactly would I go if I wanted to build the application preloaded on my board from source code?
Basically, what is the exact repo, where are the build instructions and where do I find the main() function?
Note that I can adapt to whatever build tools have been used (Arduino, Eclipse, Make, CMake, etc.).
Thanks in advance.
Best regards,
Alain Mosnier


(Alain Mosnier) #2

Hi,
It looks like I could answer that question myself by RTFM (pardon my French, but after all, I am French) and a little Googling.
Without taking too many risks, I am guessing that the demo application on my HiFive1 is pretty much contained in the file led_fade.c, together with the board’s BSP.
Thanks to SiFive for making so much so easily available.
Best regards,
Alain


(Bruce Hoult) #3

Yes, exactly, led_fade is the preloaded program.

cd freedom-e-sdk
make software PROGRAM=led_fade
make upload PROGRAM=led_fade

The instructions say to use “screen” to monitor the serial port, but I find “minicom” works better.

sudo minicom -b 115200 -D /dev/ttyUSB1

(Alain Mosnier) #4

Thanks Bruce.


(John Burke) #5

I just got the HiFive1 myself recently to play around with, so the timing of this is really nice! Thanks for asking and following up to both of you!