aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2020-04-22Merge #306bors[bot]
306: Retain cfg-attributes on resources r=korken89 a=AfoHT When rust 1.43 lands as stable this will resolve #301 and allow for the kind of conditional compilation exemplified in the issue. Tested on beta and nightly. Co-authored-by: Henrik Tjäder <henrik@tjaders.com>
2020-04-22Retain cfg-attributes on resourcesHenrik Tjäder
2020-04-21Merge #307bors[bot]
307: Use build.rs for conditional compilation r=korken89 a=AfoHT Extend the current test suite to allow for running tests on newer rustc-versions than current MSRV. Required by #306 to add special tests for future MSRV. To exclude an example from the regular non-nightly testing: ``` #![no_main] #![no_std] #[cfg(rustc_is_nightly)] mod example { use panic_halt as _; #[rtfm::app(device = lm3s6965)] const APP: () = { <more code> } } ``` Co-authored-by: Henrik Tjäder <henrik@tjaders.com>
2020-04-21Temporarily disable extra test stub since tests are not merged yetHenrik Tjäder
2020-04-21Remove reference to exampleHenrik Tjäder
This example will be reintroduced in #306 instead
2020-04-20Use buildrs for conditional compilationHenrik Tjäder
2020-04-14Merge #305bors[bot]
305: Updated dead links to SLEEPONEXIT reference on developer.arm.com r=korken89 a=FluenTech Co-authored-by: Peter Taylor <40178570+FluenTech@users.noreply.github.com>
2020-04-13fix SLEEPONEXIT reference link in Russian versionPeter Taylor
2020-04-13correct SLEEPONEXIT reference linkPeter Taylor
2020-01-28Merge #297bors[bot]
297: Reference the correct example in the by-example book r=japaric a=AfoHT closes #298 Co-authored-by: Henrik Tjäder <henrik@tjaders.com>
2020-01-24Merge #294bors[bot]
294: use the safe DWT::unlock API r=korken89 a=japaric instead of a unsafe write_volatile call Co-authored-by: Jorge Aparicio <jorge@japaric.io>
2020-01-24Reference the correct exampleHenrik Tjäder
2020-01-24Merge #295bors[bot]
295: docs: do not use Instant::now in #[init] r=korken89 a=japaric Co-authored-by: Jorge Aparicio <jorge@japaric.io>
2020-01-21docs: do not use Instant::now in #[init]Jorge Aparicio
2020-01-21use the safe DWT::unlock APIJorge Aparicio
instead of a unsafe write_volatile call
2019-12-04Merge #284bors[bot]
284: book, Russian lang: fix "idle not defined" typo r=burbull a=kolen Fix typo in Russian translation of book, was "When idle function is declared", should be "When no idle function is declared" "не" means "not". Corresponding text in English: ```markdown When no `idle` function is declared, the runtime sets the [SLEEPONEXIT] bit and then sends the microcontroller to sleep after running `init`. ``` Co-authored-by: Konstantin Mochalov <incredible.angst@gmail.com>
2019-12-04book, Russian lang: fix "idle not defined" typoKonstantin Mochalov
Fix typo in Russian translation of book, was "When idle function is declared", should be "When no idle function is declared"
2019-12-03Merge #283bors[bot]
283: Include DWT enable in migration guide r=korken89 a=MabezDev Makes note of the fact the DWT has to be enabled manually in rtfm 0.5.0; an easy one to miss considering debuggers generally enable the DWT automatically. Co-authored-by: Scott Mabin <scott@mabez.dev>
2019-12-03Update migration guide to include the enabling of the the DWT peripheral. ↵Scott Mabin
Also makes note of enable trace with the DCB to allow the DWT to work without a debugger connected.
2019-11-19Merge #280bors[bot]
280: Fixed link to API reference r=TeXitoi a=korken89 Co-authored-by: Emil Fresk <emil.fresk@gmail.com>
2019-11-19Fixed link to API referenceEmil Fresk
2019-11-19Merge #279bors[bot]
279: Preparation for v0.5.1 r=perlindgren a=korken89 Co-authored-by: Emil Fresk <emil.fresk@gmail.com>
2019-11-19Preparation for v0.5.1Emil Fresk
2019-11-19Merge #277bors[bot]
277: TimerQueue.dequeue: don't set SYST reload to 0 r=korken89 a=mpasternacki ARM Architecture Reference Manual says: "Setting SYST_RVR to zero has the effect of disabling the SysTick counter independently of the counter enable bit." If Monotonic's ratio is less than one, the timeout calculations can compute zero if next task is scheduled after current instant, but before next timer tick. This results in disabling SYST and freezing the timer queue. The division by ratio's denominator rounds downward and the dequeue condition is `if instant < now`. If ratio is small enough, this results in unnecessary interrupts: Let's say `instant - now` is 99 and ratio is 1/25. Then, `dur` will equal 3 and the next tick will happen at `now + 75`. In the next interrupt, `instant > now` and additional tick needs to be scheduled (which doesn't happen, because now `instant - now` is less than 25, so reload will be set to 0 and timer queue will stop). Adding one to computed duration will prevent both freezing and additional interrupts. When ratio is 1 or close, timer queue code overhead will prevent this from happening. I am working with a chip where CPU is clocked at 600MHz and SysTick is 100kHz and the freeze happens quite often. Co-authored-by: Maciej Pasternacki <maciej@3ofcoins.net>
2019-11-19TimerQueue.dequeue: don't set SYST reload to 0Maciej Pasternacki
ARM Architecture Reference Manual says: "Setting SYST_RVR to zero has the effect of disabling the SysTick counter independently of the counter enable bit." If Monotonic's ratio is less than one, the timeout calculations can compute zero if next task is scheduled after current instant, but before next timer tick. This results in disabling SYST and freezing the timer queue.
2019-11-18Merge #278bors[bot]
278: Cyccnt r=texitoi a=perlindgren The subtractions in `elapsed` and `duration` may cause an overflow panic in debug mode. This is solved by using wrapping arithmetics. Co-authored-by: Per Lindgren <per.lindgren@ltu.se>
2019-11-18Bumped version to 0.5.1, cyccntr bugfixPer Lindgren
2019-11-18Fixed internal overflow on subtraiton in elapsed and durationPer Lindgren
2019-11-15Merge #274bors[bot]
274: remove references to 'beta' from the docs r=perlindgren a=japaric Co-authored-by: Jorge Aparicio <jorge@japaric.io>
2019-11-14Merge #275bors[bot]
275: fix CI r=perlindgren a=japaric after caching was enabled binary install through the trust/install.sh script stopped working (due to permissions?). This updates crate installation to use `cargo-install` iff the requested version of a crate is not already installed Co-authored-by: Jorge Aparicio <jorge@japaric.io>
2019-11-14fix CIJorge Aparicio
after caching was enabled binary install through the trust/install.sh script stopped working (due to permissions?). This updates crate installation to use `cargo-install` iff the requested version of a crate is not already installed
2019-11-14remove references to 'beta' from the docsJorge Aparicio
2019-11-14Merge #273bors[bot]
273: CI: fix caching mechanism r=perlindgren a=japaric Co-authored-by: Jorge Aparicio <jorge@japaric.io>
2019-11-14CI: fix caching mechanismJorge Aparicio
2019-11-14Merge #272bors[bot]
272: v0.5.0 final release r=perlindgren a=japaric Co-authored-by: Jorge Aparicio <jorge@japaric.io>
2019-11-14v0.5.0 final releaseJorge Aparicio
2019-11-13Merge #271bors[bot]
271: Minor docs update to monotonic r=japaric a=korken89 Co-authored-by: Emil Fresk <emil.fresk@gmail.com>
2019-11-13Minor docs update to monotonicEmil Fresk
2019-11-13Merge #268 #270bors[bot]
268: CI: replace compiletest-rs with trybuild r=japaric a=japaric We use compiletest to run compile-fail tests but compiletest depends on compiler internals so it breaks every now and then and requires nightly. With trybuild we can also run compile-fail tests but it works on stable and it already has reached version 1.0 270: Added struct de-structure-ing example in tips & tricks r=japaric a=korken89 As per last meeting, a bare-bones added that we can improve Co-authored-by: Jorge Aparicio <jorge@japaric.io> Co-authored-by: Emil Fresk <emil.fresk@gmail.com>
2019-11-07Added struct de-structure-ing example in tips & tricksEmil Fresk
2019-11-06fix bash comparisonJorge Aparicio
2019-11-06run cfail tests only when rustc --version == $MSRVJorge Aparicio
this version is more or less fixed so new releases of Rust (stable or nightly channel) are unlikely to break to build due to changes in diagnostic messages
2019-11-06CI: replace compiletest-rs with trybuildJorge Aparicio
We use compiletest to run compile-fail tests but compiletest depends on compiler internals so it breaks every now and then and requires nightly. With trybuild we can also run compile-fail tests but it works on stable and it already has reached version 1.0
2019-11-06Merge #266bors[bot]
266: CI: build 0.4 docs from the v0.4.x branch r=korken89 a=japaric instead of using a specific tag; this way documentation changes done to the v0.4.x branch will show up on the site as soon as they land -- right now they require publishing a new v0.4.x release on crates.io Co-authored-by: Jorge Aparicio <jorge@japaric.io>
2019-11-06Merge #267bors[bot]
267: fix CI: use an older nightly on the x86_64 build r=korken89 a=japaric Co-authored-by: Jorge Aparicio <jorge@japaric.io>
2019-11-06fix CI: use an older nightly on the x86_64 buildJorge Aparicio
2019-10-25CI: build 0.4 docs from the v0.4.x branchJorge Aparicio
instead of using a specific tag; this way documentation changes done to the v0.4.x branch will show up on the site as soon as they land -- right now they require publishing a new v0.4.x release on crates.io and manually updating the `after-success.sh` build script on master
2019-10-23Merge #259bors[bot]
259: Fixed peripherals -> device typo r=japaric a=korken89 Co-authored-by: Emil Fresk <emil.fresk@gmail.com>
2019-10-23Fixed peripherals -> device typoEmil Fresk
2019-10-22Merge #257bors[bot]
257: do not zero late resource memory on boot r=korken89 a=japaric this is done using the `.uninit` linker section; this optimization was already being applied to message buffers but I forgot to also apply it to late resources Co-authored-by: Jorge Aparicio <jorge@japaric.io>