lucysrausch / hoverboard-firmware-hack

New Hoverboard Firmware Hack. Now written from scratch and generally much better.
GNU General Public License v3.0
702 stars 407 forks source link

What software do you guys use!?? #48

Closed SpacePokemon closed 6 years ago

SpacePokemon commented 6 years ago

First of all, thank you guys for your work!

I am new to embedded and I was wondering what software you guys use to program STM32.

I tried to use Atollic TrueSTUDIO but I am getting thousands of errors from the original code which I am having hard time to resolve.

However, I successfully flashed/unlocked my board using ST-Link Utility with the hex file that you guys provided.

Thanks in advance!!

drbytes commented 6 years ago

I use Keil, it talks to the STLINKv2 and compiles and flashes (called download) the board.

LeoDJ commented 6 years ago

Normally, on Linux, I use VS Code as an editor and just the plain make with arm-none-eabi-gcc installed.

Even on Windows, I use the Linux subsystem and compile it using make there too. Together with VS Code and ST-Link Utility.

Just make sure you don't run on gcc version 6, because nothing will compile correctly (you will get a binary, but the board will do weird things or nothing at all, better to not try it). Either verison 4 or 7 is tested to work okay.

I for my part installed gcc 7 using from the team-gcc-arm-embedded PPA like this, because my Ubuntu 18.04 came with the incompatible version 6:

sudo add-apt-repository ppa:team-gcc-arm-embedded/ppa 
sudo apt update 
sudo apt install gcc-arm-embedded 

There are currently efforts of compiling this project with platform.io too (#43), so I'll probably use that in the future. But for now, make works fine enough for me.

PS: as far as I am aware, Niklas is using just plain make too, so that's what this project is optimized for.

SpacePokemon commented 6 years ago

Thank you all!!! I will try them out and find the one that fits me!!

btsimonh commented 6 years ago

platform.io also works; look at the latest pull request. It's really easy to use (on windows) - does pretty much everything for you; although debugging alludes me as yet.

SpacePokemon commented 6 years ago

@btsimonh I just gotta say, platform.io is awesome!!! Btw did you have any luck debugging with this?

btsimonh commented 6 years ago

not yet; and I've now moved to an RPiZeroW inside the board, so it gets more complex.
When I tried to debug in platformio, it said I had to login to platform.io. did that, then it failed with something else.... However, do check my repo - i've just pushed a pretty updated version with in an easy ascii protocol for examining internals.