Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Setting up a Project #22

Open
mtthw-meyer opened this issue May 18, 2021 · 4 comments
Open

Setting up a Project #22

mtthw-meyer opened this issue May 18, 2021 · 4 comments

Comments

@mtthw-meyer
Copy link
Owner

When creating a new libdaisy-rust project you'll need to copy or create your own memory.x and .cargo/config files to tell the compiler how to build the binary image.

@x37v
Copy link
Collaborator

x37v commented May 18, 2021

a template for cargo-generate could be nice

@Spstolar
Copy link

I'm working on this. Trying to base it off of https://github.com/rust-embedded/cortex-m-quickstart

Two questions here:

  • Does it matter what repository I'm storing it in? We'll just copy it over to a more official one if I get it working, right? I am working out of https://github.com/Spstolar/libdaisy-rust-quickstart right now.
  • Do we have an idea for what main.rs should do? My current idea is just to fill it with blinky.rs.

@mtthw-meyer
Copy link
Owner Author

Yes, we'll find a place to put it if you get something working. Any of the examples would be a reasonable base for main.rs, blinky is fine.

@Spstolar
Copy link

OK, got it running: https://github.com/Spstolar/libdaisy-rust-quickstart . The steps for use are in the README, which can be cleaned up more if needed.

Assuming cargo-generate and the other precursor steps are done

  1. cargo generate --git https://github.com/Spstolar/libdaisy-rust-quickstart
  2. cargo objcopy --release -- -O binary template.bin
  3. Then (if you're using dfu-util): dfu-util -a 0 -s 0x08000000:leave -D template.bin

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants