Comments (5)
@9names thanks a lot, that works! Time to mess around with it :D
from rp-hal.
Might be related: I'm trying to build an example and I get this error
error: linking with `rust-lld` failed: exit code: 1
<lots of arguments>
\target\thumbv6m-none-eabi\debug\build\cortex-m-rt-eb0715ff362a68a0\o
ut\link.x:23: cannot find linker script memory.x
>>> INCLUDE memory.x
>>> ^
from rp-hal.
Might be, hard to say. I'm having trouble reproducing it or @jonathanpallant's issue with it only building from the root of the repo.
I just tried doing clean builds of blinky on linux and windows
- in the root
- in the rp2040-hal directory
- in the rp2040-hal/examples directory
And builds of pico_blinky
- in the boards directory
- in the boards/pico/
- in the boards/pico/examples directory
Successfully built and linked every time.
Can you provide any more information on OS, how you're building, rust version, etc?
from rp-hal.
Windows 10, cargo 1.56.0 (4ed5d137b 2021-10-04)
I copied .cargo/config
to my project, and the pico_blinky.rs
example to my main.rs
, then ran cargo run
from the root of the project.
dependencies mostly copied from pico/Cargo.toml
:
[dependencies]
pico = { git = "https://github.com/rp-rs/rp-hal.git" }
cortex-m = "0.7.2"
rp2040-hal = "0.2"
cortex-m-rt = { version = "0.7"}
embedded-time = "0.12.0"
usb-device= "0.2.8"
usbd-serial = "0.1.1"
usbd-hid = "0.5.1"
panic-halt= "0.2.0"
embedded-hal ="0.2.5"
cortex-m-rtic = "0.6.0-alpha.5"
rp2040-boot2 = "0.2"
nb = "1.0"
i2c-pio = { git = "https://github.com/ithinuel/i2c-pio-rs", rev = "fb6167d02b7fbc46a83f344f5242823bcd16e271" }
from rp-hal.
oh, in that case you will need a copy of memory.x in your project folder.
if you just want to run an example from the HAL, use this command from inside your rp-hal folder:
cargo build --release --example blinky
If you want something you can copy the examples into, can I suggest looking at https://github.com/rp-rs/rp2040-project-template?
It's configured by default to use a debugger (a second Pico will do, if you have one), but you could strip out a bunch of the dependencies and use the .cargo/config from the hal with it if you want to program over the USB bootloader.
from rp-hal.
Related Issues (20)
- Timer from cvr register (SysTick) HOT 3
- Configure TransmittedWord for PIO SM DMA HOT 2
- DynPin not usable with ADC HOT 1
- How to use the USB Slot for data transmission? HOT 3
- PWM is not atomic/sync with WFI and cleared `clk_sys_pwm` HOT 10
- Substract with overflow not detected at build time ? HOT 2
- Provide functions to safely halt or reset the RP2040 HOT 3
- No way to set a StateMachine's execctrl HOT 2
- Should Timer::new() make sure clocks are initialized? HOT 7
- Suggestion: Re-export foreign types from extern crates in public APIs HOT 5
- Support for placing functions/statics in ram HOT 28
- Current defmt version is broken HOT 7
- Allow enabling DMA byte swapping HOT 2
- rp2040_hal I2CPeripheralEventIterator usage HOT 2
- Make `bad::Never` public HOT 5
- Fix / document on-target tests HOT 6
- How to use different pins when using spi? HOT 5
- rp2040-e5 feature can randomly panic if not using gpio::Pins HOT 1
- Generic inter-core FIFO HOT 3
- DMA unsound - Simultaneous write to identical address possible HOT 12
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from rp-hal.