Open m3x1m0m opened 4 years ago
In the BSP directory there is an update-targets.sh script that may need to be run.
I have not looked at the recent updates on the freedom SDK so I would have to perform the updates to try and replicate.
What are the exact steps that you performed?
Thanks for the comment.
cd freedom-metal
git checkout master
cd ..
make PROGRAM=sifive-welcome TARGET=lofive-r1 software
This is what I have done before. I also ran
bash update-targets.sh
as you suggested and ...
update-targets.sh: line 107: dtc: command not found
update-targets.sh: Failed to compile freedom-e310-arty//design.dts to dtb
...
Seems like my toolchain is not setup correctly.
You will need the devicetree compiler. Also notice that even the mainline freedom-e-sdk doesn't use the master branch.
Maybe it is about time to attempt merging lofive to the upstream repository.
Plus one for merging the lofive to the upstream repository. I'm currently trying to program my first LoFive board and running into issues. Would love to contribute as I do this.
@Layke heads up!
When SiFive switched silicon revision they depracated openocd support.
It works but only after the very first programming of the flash. If you are one of the unlucky people that didn't get the flash programmed this will effect you
Switching to JLINK is the easy way out: https://github.com/mwelling/lofive/issues/5#issuecomment-565856885
I have not updated the SDK in years so maybe they fixed it by now but I doubt it.
Contributions are always welcome so if you get something working, document it and upstream where possible.
For collaboration I have a channel on discord: https://discord.gg/n6CnKFFg
@mwelling I just got couple of lofive boards today. would like to know if the FE310-G002 in the lofive has the same init code in OTP and jumps into flash as it happens in Hifive1-rev B board? What is the best way to quickly bringup the board with gdb & load the code into ram and execute? I assume the openocd script that works on hifive1-revb Board should work for this as well.
OTP and Mask ROM are the same in all -G002 versions. After brief checks to confirm presence of an external xSPI memory device, execution will go to 0x20000000.
Perhaps the easiest and quickest way to load into and run from RAM is as follows: make -f myprog.mk ramload make -f myprog.mk ramrun riscv-project-toolchain.pdf
Just tried out to get a newer version of freedom-metal running. I switched to the master branch in the freedom-metal submodule.
Compilation works, but it cannot find the correct library file (apparently). I am sure this is possible. I did not find any documentation on that subject.