Scott Mabin
a6bbb130c5
make set_config concrete methods public again
2023-10-12 23:03:33 +01:00
pbert
ecdd7c0e2f
enable clock first
2023-10-12 11:04:44 +02:00
pbert
f65a96c541
STM32: combine RccPeripherals reset() and enable() to reset_and_enable()
2023-10-12 11:04:19 +02:00
xoviat
05218a52e6
stm32: update set_config
2023-10-01 09:39:10 -05:00
Dario Nieuwenhuis
5d8817d109
stm32/usart: return error instead of panicking on bad baudrate.
2023-09-26 00:19:27 +02:00
Scott Mabin
88eb5cca71
stm32: Implement set_config
for Uart structs
2023-09-17 18:38:03 +01:00
Mathias
49847ff432
Implement blocking embedded-io::Write for Uart & UartTx
2023-09-14 10:09:09 +02:00
xoviat
274f63a879
stm32: fix refcounts for usart, spi, and i2c
2023-09-04 15:47:33 -05:00
Dario Nieuwenhuis
f26dd54f63
Update embedded-hal to 1.0.0-rc.1 ( #1783 )
2023-08-16 00:40:56 +02:00
Dario Nieuwenhuis
5d5cd23715
Update to embedded-io 0.5 ( #1752 )
2023-08-07 13:43:09 +02:00
Dario Nieuwenhuis
036e6ae30c
Rename embassy-hal-common to embassy-hal-internal, document it's for internal use only. ( #1700 )
2023-07-28 13:23:22 +02:00
Dario Nieuwenhuis
558918651e
stm32: update stm32-metapac.
2023-06-19 03:22:12 +02:00
Peter Gibson
b4f96e192c
Don't read data register to clear flags on usart v3 ^& v4
2023-06-18 08:45:58 +10:00
Peter Gibson
d236f3dbf9
actually fix formatting
2023-06-15 18:35:58 +10:00
Peter Gibson
d23717904b
fix formatting
2023-06-15 18:33:01 +10:00
Peter Gibson
837950cd74
ensure DR is read to clear idle/overflow interrupt when they occur independently of the rxne
2023-06-15 13:24:49 +10:00
Dario Nieuwenhuis
921780e6bf
Make interrupt module more standard.
...
- Move typelevel interrupts to a special-purpose mod: `embassy_xx::interrupt::typelevel`.
- Reexport the PAC interrupt enum in `embassy_xx::interrupt`.
This has a few advantages:
- The `embassy_xx::interrupt` module is now more "standard".
- It works with `cortex-m` functions for manipulating interrupts, for example.
- It works with RTIC.
- the interrupt enum allows holding value that can be "any interrupt at runtime", this can't be done with typelevel irqs.
- When "const-generics on enums" is stable, we can remove the typelevel interrupts without disruptive changes to `embassy_xx::interrupt`.
2023-06-08 18:00:48 +02:00
Dario Nieuwenhuis
404aa29289
cortex-m: remove owned interrupts.
2023-06-01 03:25:19 +02:00
xoviat
316be179af
stm32: move to bind_interrupts
...
disable lora functionality for now
2023-05-24 17:29:56 -05:00
Dario Nieuwenhuis
a61701b756
stm32/usart: add OVER8 and PRESC support, update PAC
2023-05-02 19:36:00 +02:00
Mathias
472dc6b7d1
Fix interrupt handling so it is similar to before the rework, and fix examples
2023-03-31 15:57:35 +02:00
Mathias
cfbe93c280
Rework bufferedUart to get rid of PeripheralMutex in a similar fashion as nrf & rp. Also adds embedded-hal traits to bufferedUart
2023-03-31 10:43:30 +02:00
Mathias
14f6bc88ea
Remove unnecessary lifetime
2023-03-28 14:34:36 +02:00
Mathias
2d7f35cf57
Add embedded-io blocking Read + Write for BufferedUart
2023-03-28 14:28:44 +02:00
Dario Nieuwenhuis
10c9cc31b1
Remove unnecessary use of atomic-polyfill.
...
Only use it when CAS is actually needed.
2022-12-23 20:46:49 +01:00
Vincent Stakenburg
236d104844
embassy-stm32: add rs485 driver enable to uart
2022-12-09 14:26:09 +01:00
Matous Hybl
e1d7d8d841
stm32: Enable fifo for buffered uart
2022-11-30 22:17:51 +01:00
Dario Nieuwenhuis
1e2fb0459d
Switch to async-fn-in-trait
2022-11-25 21:02:06 +01:00
Guillaume MICHEL
79b49c6fae
embassy-stm32: remove duplicated code for USART general configuration
2022-10-28 09:32:05 +02:00
Guillaume MICHEL
f053bf742c
embassy-stm32: Add support for hardware flow control for BufferedUart
2022-10-28 09:04:36 +02:00
Guillaume MICHEL
9cac649fcf
stm32: Add support for read_until_idle on UART
2022-10-26 19:06:18 +02:00
Dario Nieuwenhuis
eeb072d9cb
Update Rust nightly.
2022-10-26 16:47:29 +02:00
Guillaume MICHEL
daf2744716
Rework STM32 BufferedUart internals so we can split into Rx and Tx like embassy-nrf
2022-09-26 15:32:29 +02:00
Dario Nieuwenhuis
a0487380da
Replace futures::future::poll_fn -> core::future::poll_fn.
2022-09-22 16:42:49 +02:00
Vincent Stakenburg
c4d5c047d7
make State::new()
const, consistent with others
2022-09-15 12:34:17 +02:00
Dario Nieuwenhuis
21072bee48
split embassy-util
into embassy-futures
, embassy-sync
.
2022-08-22 22:18:13 +02:00
Vincent Stakenburg
a833e02363
implement support for LPUART
2022-08-19 12:05:19 +02:00
Dario Nieuwenhuis
a0f1b0ee01
Split embassy crate into embassy-executor, embassy-util.
2022-07-29 23:40:36 +02:00
Dario Nieuwenhuis
4901c34d9c
Rename Unborrowed -> PeripheralRef, Unborrow -> Peripheral
2022-07-23 14:00:19 +02:00
Dario Nieuwenhuis
a8703b7598
Run rustfmt.
2022-06-12 22:22:31 +02:00
Dario Nieuwenhuis
5085100df2
Add embassy-cortex-m crate.
...
- Move Interrupt and InterruptExecutor from `embassy` to `embassy-cortex-m`.
- Move Unborrow from `embassy` to `embassy-hal-common` (nothing in `embassy` requires it anymore)
- Move PeripheralMutex from `embassy-hal-common` to `embassy-cortex-m`.
2022-06-12 21:45:38 +02:00
Dario Nieuwenhuis
db344c2bda
common/PeripheralMutex: remove unsafe API. ( #802 )
...
Following the project's decision that "leak unsafe" APIs are not marked as "unsafe",
update PeripheralMutex to accept non-'static state without unsafe.
Fixes #801
2022-06-09 21:28:13 +02:00
chemicstry
1d951a54be
Reimplement BufRead for BufferedUart
2022-05-26 14:02:55 +03:00
Dario Nieuwenhuis
931a137f8c
Replace embassy::io with embedded_io.
2022-05-07 01:45:54 +02:00