GithubHelp home page GithubHelp logo

progranism / stm32f4-gcc-template Goto Github PK

View Code? Open in Web Editor NEW
17.0 5.0 16.0 492 KB

A project template for using GCC with the STM32F4Discovery Kit.

Shell 0.01% Perl 0.06% C 95.11% Assembly 4.84%

stm32f4-gcc-template's Introduction

This project provides a template for getting up and running with GCC and the STM32F4Discovery kit.

It is also compatible with Eclipse. Set up Eclipse as explained here: http://embeddedprogrammer.blogspot.com/2012/09/stm32f4discovery-development-with-gcc.html

Just disable Makefile generation in the Eclipse project (since we already have a Makefile).

To compile the project: make or for parallel compilation: make -j4

To load the program into the STM32F4: make program

Debugging is accomplished with openocd, which supports the stm32f4discovery natively. Run this to start openocd: openocd-0.6.1.exe -f board/stm32f4discovery.cfg

And then start GDB: arm-none-eabi-gdb build/main.elf

And in GDB: target remote :3333 monitor halt load monitor reset init

Set some breakpoints, etc, and then run the program: continue

NOTE: On Windows, do not install libusb drivers for the ST-Link. Use ST's native drivers. Openocd works just fine with the native drivers. NOTE: On Windows, run arm-none-eabi-gdb from a normal Command Prompt (not within cygwin), otherwise Ctrl+C won't work (it'll close gdb instead of sending SIGINT to the program being debugged).

stm32f4-gcc-template's People

Contributors

fpgaminer avatar progranism avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

stm32f4-gcc-template's Issues

fpu should not soft or hard, but softfp

#CFLAGS += -mfloat-abi=hard -mfpu=fpv4-sp-d16
CFLAGS += -mfloat-abi=soft 
# TODO: hard float was causing an exception; see what's up.

should instead be

CFLAGS += -mfloat-abi=softfp

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.