aboutsummaryrefslogtreecommitdiff
path: root/embassy-stm32/src/ospi
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch 'main' of https://github.com/embassy-rs/embassy into xspixoviat2025-11-241-3/+3
|\
| * Rustfmt for edition 2024.Dario Nieuwenhuis2025-10-061-3/+3
| |
* | ospi: properly respect the max DMA transfer size when readingBrian Schwind2025-10-041-16/+20
| |
* | ospi: properly respect the max DMA transfer size when writingBrian Schwind2025-10-041-2/+2
| |
* | ospi: properly configure the transfer sizeBrian Schwind2025-10-041-6/+12
| |
* | ospi: use a named enum variant in place of a literal zeroBrian Schwind2025-10-041-1/+1
|/
* Write data with the Ospi peripheral in chunks to respect the max DMA ↵Brian Schwind2025-09-161-18/+24
| | | | transfer size
* Handle OSPI address errorsgoodhoko2025-09-161-3/+18
| | | | | | | | | | | | | | | | | | | | We were using OSPI in indirect mode via DMA and noticed that the transfer future would never resolve. It was forever busy-looping in `finish_dma()` on the `while !regs.sr().read().tcf() {}` line. After some debugging we noticed that the the `TEF` flag is set. The data sheet says the following about this flag: > The following errors set the TEF flag in OCTOSPI_SR and generates an interrupt if enabled (TEIE = 1 in OCTOSPI_CR): > - in indirect or automatic status-polling mode, when a wrong address has been programmed in OCTOSPI_AR (according to the device size defined by DEVSIZE[4:0]). > - in indirect mode, if the address plus the data length exceed the device size: TEF is set as soon as the access is triggered. Indeed we were configuring our device size to 0 while specifying a non-zero address. Detect this condition and return an error early - as soon as we configure the registers (which, according to the data sheet, should be enough to raise the flag) Also document this behavior on the respective TransferConfig and Config fields. Testing ------- See https://github.com/goodhoko/spi-error-test/blob/main/src/main.rs
* It's "derive" all the way downgoodhoko2025-09-161-0/+8
|
* Unify derivation of Clone, Copy and defmt::format for all *SPI configsgoodhoko2025-09-161-0/+3
|
* Set the alternate bytes register to the correct value when configuring an ↵Brian Schwind2025-09-131-6/+5
| | | | Ospi command
* Typo fixesBrian Schwind2025-09-131-4/+4
|
* OSPI RAM Supportjake-taf2025-09-051-9/+100
| | | | | | | - Make DQSE / SIOO configurable - Make write instruction configurable - Fix bug where the address DTR was using the config for the instruction DTR instead of its own - Configure DQS pin
* Remove Peripheral trait, rename PeripheralRef->Peri.Dario Nieuwenhuis2025-03-271-113/+111
|
* Fix compile error in ospiRasmus Melchior Jacobsen2025-03-201-2/+2
|
* Fix typo.Dario Nieuwenhuis2025-01-071-1/+1
|
* chore: fix buildelagil2025-01-031-10/+16
|
* stm32/(o|q)spi: command naming convention fixPiotr Esden-Tempski2024-12-171-1/+1
| | | | | | The naming convention is to prefix blocking functions with blocking. As both command implementations are blocking the async for the ospi implementation should also be dropped.
* feat(ospi): add ospi exampleHaobo Gu2024-10-261-7/+2
| | | | Signed-off-by: Haobo Gu <[email protected]>
* feat(ospi): add memory mapped modeHaobo Gu2024-10-251-15/+48
| | | | Signed-off-by: Haobo Gu <[email protected]>
* feat: set ospi memory mapped modeHaobo Gu2024-10-231-0/+37
| | | | Signed-off-by: Haobo Gu <[email protected]>
* stm32: Fix build for chips with octospim but not octospi2.Dario Nieuwenhuis2024-10-211-1/+1
|
* Add octospim support for octospi (#3102)HaoboGu2024-10-131-0/+118
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * feat: add octospim to ospi Signed-off-by: Haobo Gu <[email protected]> * feat: make octospim behind feature gate Signed-off-by: Haobo Gu <[email protected]> * refactor: fix fmt issue Signed-off-by: Haobo Gu <[email protected]> * refactor: fix ci failure Signed-off-by: Haobo Gu <[email protected]> * feat: add octospim reg writing code Signed-off-by: Haobo Gu <[email protected]> * feat(octospi): enable rcc for octospim at the initialization Signed-off-by: Haobo Gu <[email protected]> * fix: add octospim feature gate Signed-off-by: Haobo Gu <[email protected]> * fix: fix cfg flag Signed-off-by: Haobo Gu <[email protected]> * fix: fix rcc register on stm32l4 and stm32u5 Signed-off-by: Haobo Gu <[email protected]> * feat(ospi): support OCTOSPI2 in build.rs Signed-off-by: Haobo Gu <[email protected]> * feat(ospi): add OCTOSPI2 pin impls Signed-off-by: HaoboGu <[email protected]> * feat(ospi): support both ospi instances in stm32 OCTOSPIM Signed-off-by: Haobo Gu <[email protected]> --------- Signed-off-by: Haobo Gu <[email protected]> Signed-off-by: HaoboGu <[email protected]>
* Update to Rust 1.80, make check-cfg unconditional.Dario Nieuwenhuis2024-07-251-12/+5
|
* stm32/gpio: refactor AfTypeJan Špaček2024-06-161-69/+99
|
* stm32/rcc: replace generated enable/disable code with runtime infoJan Špaček2024-05-251-3/+3
|
* update to remove dma genericsKarun2024-05-141-380/+437
|
* stm32/ospi: remove unused trait.Dario Nieuwenhuis2024-05-121-11/+0
|
* Fix passing of dual quad param to inner constructorKarun2024-04-031-20/+10
|
* Fix build errorsKarun2024-04-031-31/+62
| | | | Add empty checks/peripheral busy waits
* Configure dual-quad setting by constructorKarun2024-04-031-8/+20
|
* Remove data length from transfer configKarun2024-04-031-75/+16
| | | | | Remove non hal traits Fix function comments
* Address PR commentsKarun2024-04-031-14/+8
|
* Add octospi version dependency for max transfer supportKarun2024-04-021-2/+8
|
* Update to use private supertrait, following PR#2730Karun2024-04-021-15/+12
|
* Resolve rustfmt issue and unused import errorsKarun2024-03-071-3/+3
|
* Update trait definitionsKarun2024-03-072-39/+102
| | | | Make operations generic against valid data widths
* Add get and set config trait implementationsKarun2024-03-071-1/+106
|
* Add constructorsKarun2024-03-072-59/+664
| | | | | | | Add transfer configuration Update command configuration Add peripheral width consideration Add drop impl
* Add user enums for transaction configurationKarun2024-03-071-0/+336
|
* Add transfer config, trait, functional initial configuration and read from ↵Karun2024-03-071-20/+198
| | | | memory
* Add initial octopsi moduleKarun2024-03-071-0/+178