All Projects → antoinevg → hello-daisy

antoinevg / hello-daisy

Licence: MIT license
Rust starter project for the @electro-smith Daisy Seed

Programming Languages

rust
11053 projects
GDB
78 projects

hello-daisy

Rust starter project for the @electro-smith Daisy Seed.

Dependencies

Install arm target for Daisy

rustup target add thumbv7em-none-eabihf

Install gdb

# install via macports (TODO homebrew, linux, windows)
sudo port install arm-none-eabi-gdb

Install openocd

Install from source or get it from: https://xpack.github.io/openocd/install/

Generate project

cargo install cargo-generate

cargo generate \
    --git https://github.com/antoinevg/hello-daisy \
    --name your-project-name

Flash and run

  1. Plug a 2x10 mini adapter into the Daisy Seed with the red stripe facing up towards the white stripe.

  2. Connect the other end to a ST-Link or similiar programmer.

  3. Start openocd in one terminal:

     cd /path/to/{{project-name}}
     /path/to/openocd
    
  4. Run program in another terminal:

     cd /path/to/{{project-name}}
     cargo build
    
     # some programmers may need you to hit the reset button on the Daisy Seed at this point
    
     cargo run
    

ITM logging support (optional)

  1. Enable the "log-itm" feature for the daisy_bsp create in Cargo.toml:

    daisy_bsp = { version = "0.3.0", features = ["log-itm"] }

  2. Edit the following files to enable ITM support:

  • openocd.cfg
  • openocd.gdb
  1. Then run:

    touch /tmp/itm.fifo itmdump -F -f /tmp/itm.fifo

More information: https://github.com/stm32-rs/stm32h7xx-hal/blob/master/examples/ITM.md

Discussion

https://forum.electro-smith.com/t/rust-starter-for-daisy-seed/

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].