Commit Graph

1010 Commits

Author SHA1 Message Date
d990740dd5 Restore F1 example chip 2022-08-04 03:07:42 +03:00
5f01e56728 Merge v1, v2 DAC and update register definitions 2022-08-04 03:02:57 +03:00
a0f1b0ee01 Split embassy crate into embassy-executor, embassy-util. 2022-07-29 23:40:36 +02:00
046778fc53 Improve ADC configuration options 2022-07-27 01:17:26 +03:00
b5ff7c5d60 rename PwmPin::new_chX, update examples. 2022-07-23 16:16:29 +02:00
4901c34d9c Rename Unborrowed -> PeripheralRef, Unborrow -> Peripheral 2022-07-23 14:00:19 +02:00
8a9d2f59af Update embassy-stm32 2022-07-23 02:40:13 +02:00
92505f53e2 Get wifi credentials from envvars in example. 2022-07-21 23:50:40 +02:00
54269a0761 Switch default log to debug.
Trace is very VRYY verbose.
2022-07-17 00:34:27 +02:00
13c88a9ca3 Obtain the firmware blobs from the user instead of hardcoding magic flash addrs. 2022-07-17 00:33:30 +02:00
4dc800710d Merge #853
853: Add embedded_hal_async support for embassy-rp r=Dirbaio a=danbev

This commit adds support for embedded-hal-async to the Embassy
Raspberry PI crate.

Co-authored-by: Daniel Bevenius <daniel.bevenius@gmail.com>
2022-07-16 16:11:37 +00:00
931e3d7ee0 Switch to 32bit SPI. 2022-07-16 18:06:57 +02:00
7dfdea8797 Switch to embedded-hal SPI, GPIO traits. 2022-07-16 08:26:54 +02:00
0b70cc554e Fix unused imports 2022-07-14 21:45:44 +03:00
5a265661bb Fix erasing across banks 2022-07-14 20:58:01 +03:00
039acda3a8 Fix writing to last sector of F4 flash 2022-07-14 19:41:39 +03:00
8979959dd1 Add embedded_hal_async support for embassy-rp
This commit adds support for embedded-hal-async to the Embassy
Raspberry PI crate.
2022-07-14 13:52:22 +02:00
ce7353fba4 Hook up embassy-net. IT WORKS. 2022-07-12 07:52:16 +02:00
4070a375c7 fix typo 2022-07-11 21:29:01 -06:00
e1fd7dfc40 wpa2 join... still nothing. 2022-07-12 04:17:07 +02:00
3ffdbd2ca3 stuff 2022-07-11 22:44:42 +02:00
30b7800f9a add event printing, add join but not working yet. 2022-07-11 05:19:31 +02:00
2adee4af38 Merge #858
858: embassy-stm32: Simplify time r=Dirbaio a=GrantM11235

- Remove unused `MilliSeconds`, `MicroSeconds`, and `NanoSeconds` types
- Remove `Bps`, `KiloHertz`, and `MegaHertz` types that were only used
for converting to `Hertz`
- Replace all instances of `impl Into<Hertz>` with `Hertz`
- Add `hz`, `khz`, and `mhz` methods to `Hertz`, as well as
free function shortcuts
- Remove `U32Ext` extension trait

Co-authored-by: Grant Miller <GrantM11235@gmail.com>
2022-07-11 02:51:06 +00:00
5ecbe5c918 embassy-stm32: Simplify time
- Remove unused `MilliSeconds`, `MicroSeconds`, and `NanoSeconds` types
- Remove `Bps`, `KiloHertz`, and `MegaHertz` types that were only used
for converting to `Hertz`
- Replace all instances of `impl Into<Hertz>` with `Hertz`
- Add `hz`, `khz`, and `mhz` methods to `Hertz`, as well as
free function shortcuts
- Remove `U32Ext` extension trait
2022-07-10 21:46:45 -05:00
99f4fd33b4 Merge #859
859: Add F4 flash driver r=Dirbaio a=chemicstry

Pending on https://github.com/embassy-rs/stm32-data/pull/152

Co-authored-by: chemicstry <chemicstry@gmail.com>
2022-07-11 01:37:19 +00:00
734c38eb9c Add F4 flash driver 2022-07-11 03:57:46 +03:00
9753f76794 Merge #810
810: Takes care of power for nRF USB devices r=Dirbaio a=huntc

Modifies the usb-serial example to illustrate how to setup USB for situations where the USB power can be detected and removed.

Gaps:

~~* No support for the nrf-softdevices as yet, although this should be possible via another constructor.~~
* No support for the nrf5340, although this should be possible via USBREG.

The change is tested and appears to work. Some notes:

* There's an existing field named self_powered as a UsbDevice field. It doesn't ever appear to get set. I'm wondering if this field is intended to signal that a device has the nRF VBUS power situation or not. I'm not presently using it.
* The new PowerDetected event is generated on the bus initially in situations where just new is used i.e. without power management, including on STM. We can therefore rely on this event always being generated.

Old description:

~~EnabledUsbDevice is a wrapper around the `UsbDevice` where its enablement is also subject to external events, such as `POWER` events for nRF. It is introduced generically to support other platforms should they also require external signaling for enablement.~~

Co-authored-by: huntc <huntchr@gmail.com>
2022-07-11 00:01:41 +00:00
069a57fcf8 async ioctls working. 2022-07-11 00:25:35 +02:00
d7d1e46a5f Use u32 instead of Duration for IWDG 2022-07-11 00:00:33 +03:00
bd741a4019 Add comments to watchdog example 2022-07-10 21:08:30 +03:00
e560415fde 🌈 2022-07-10 19:45:26 +02:00
bd01e90bfa Implement IWDG timeout calculation 2022-07-10 20:38:30 +03:00
8785fbc6f1 Trait for UsbSupply
Eliminated a signal by using a simpler trait method that returns whether VBus power is available. Also includes a UsbSupply that can be signalled for use with the nRF softdevice. Includes the requirement for waiting for power to become available.
2022-07-09 17:57:31 +10:00
4a8f117f25 Puts in the machinery to handle power detected/removed 2022-07-07 10:08:57 +10:00
c46e9b6cfc Introduces EnabledUsbDevice
EnabledUsbDevice is a wrapper around the UsbDevice where their enablement is also subject to external events, such as POWER events for nRF. It is introduced generically to support other platforms should they also require external signalling for enablement.
2022-07-07 10:08:57 +10:00
6f425d7721 Use correct chip family name for example 2022-07-05 13:17:55 +02:00
daf3ea24d7 Document configuration options and handle optional downlink 2022-07-04 10:33:29 +02:00
7b35b4ebee Fix RAM origin copy paste from nrf 2022-06-29 19:14:07 +02:00
f1f90b17b5 Add build.rs to detect armv6 2022-06-27 14:24:19 +02:00
776be79f7b Move bootloader main to examples
This should remove some confusion around embassy-boot-* being a library
vs. a binary. The binary is now an example bootloader instead.
2022-06-24 19:56:15 +02:00
84628d36cf Merge #826
826: Bump bxcan version r=chemicstry a=chemicstry



Co-authored-by: chemicstry <chemicstry@gmail.com>
2022-06-22 23:48:45 +00:00
88c3737722 Simplify example 2022-06-23 02:30:55 +03:00
3cdd8c1aeb Fix PWM for advanced timers 2022-06-23 02:27:39 +03:00
31177d994f Fix example 2022-06-23 02:01:23 +03:00
9721b2bf5b Merge #817
817: Added a pubsub channel implementation r=lulf a=diondokter

This is similar to Tokio's Broadcast channel, except that it doesn't allocate.

The publishers and subscribers are dynamic. They use an &dyn channel reference because it's really annoying to have to specify the mutex and const generics every time.
Do we need fully generic types as well?

Co-authored-by: Dion Dokter <diondokter@gmail.com>
Co-authored-by: Dion Dokter <dion@tweedegolf.com>
2022-06-21 20:04:27 +00:00
78c546f356 Added example and some defmt 2022-06-21 15:47:20 +02:00
6852e05c59 Merge pull request #822 from embassy-rs/remove-authors
Remove the authors field from Cargo.tomls
2022-06-18 17:33:29 +02:00
3fd4ee34ec Merge pull request #821 from embassy-rs/defmt-trace
Add env DEFMT_LOG=trace to all examples.
2022-06-18 02:24:25 +02:00
1f746e0939 Remove the authors field from Cargo.tomls
It currently contains whoever was first to write some code for the crate,
even if many more people have contributed to it later.

The field is "sort of" deprecated, it was made optional recently:
https://rust-lang.github.io/rfcs/3052-optional-authors-field.html

Due the the reasons listed there I believe removing it is better than
setting it to generic fluff like "The Embassy contributors".
2022-06-18 02:16:40 +02:00
88e36a70bd Update to 2021 edition. (#820) 2022-06-18 02:15:48 +02:00