probe-rs / rtt-target

Target side implementation of the RTT (Real-Time Transfer) I/O protocol
MIT License
122 stars 30 forks source link

Add flush function to `UpChannel` #46

Closed diondokter closed 6 months ago

diondokter commented 6 months ago

I'm trying to make a defmt encoder on top of rtt target since I can't use defmt_rtt because I need other RTT channels. The defmt impl wants a flush function and that's implemented here.

They also do a check whether the host is connected by looking if the mode is BlockingIfFull. However, that's only done for defmt channels. So I've skipped that step to generalize it better.