ChanServ changed the topic of #rust-embedded to: Welcome to the Rust Embedded IRC channel! Bridged to #rust-embedded:matrix.org and logged at https://libera.irclog.whitequark.org/rust-embedded, code of conduct at https://www.rust-lang.org/conduct.html
crabbedhaloablut has quit []
notgull has quit [Ping timeout: 260 seconds]
notgull has joined #rust-embedded
IlPalazzo-ojiisa has joined #rust-embedded
emerent has quit [Ping timeout: 258 seconds]
emerent_ has joined #rust-embedded
emerent_ is now known as emerent
crabbedhaloablut has joined #rust-embedded
<FlixtheNewbie[m]> Oh, I just discovered that when I reject() an USB control, the host cuts contact with the device
<FlixtheNewbie[m]> I thought it was a way to say "Not Implemented"
emerent has quit [Read error: Connection reset by peer]
emerent has joined #rust-embedded
Shellhound has quit [Quit: ZNC 1.8.2+deb2+b1 - https://znc.in]
<thejpster[m]> Got stopped by a guy at Eurorust - "hey you're from the embedded working group right? It's so good, you did great stuff!
<thejpster[m]> * great stuff!"
Shell has joined #rust-embedded
Shell has quit [Client Quit]
Shell has joined #rust-embedded
<ryan-summers[m]> Hmm... Becoming extremely suspicious. I have a USB device that's failing enumeration on Windows, so I'm injecting debug logging into usb-device, and after adding enough logging, suddenly enumeration passed
Shell has quit [Quit: ZNC 1.8.2+deb3.1 - https://znc.in]
Shell has joined #rust-embedded
Shell is now known as Shellhound
<JamesMunns[m]> <ryan-summers[m]> "Hmm... Becoming extremely..." <- What would embedded development be without a little "oops timing related bugs"?
<ryan-summers[m]> I just loathe debugging USB interfaces.... None of the tools work that well :(
tamme[m] has quit [Quit: Idle timeout reached: 172800s]
<ryan-summers[m]> Huh, got it. There's a bug in usb-device where it basically forgets that it just sent an EP0-IN packet, so when it gets the EP0-IN complete status, it throws an internal error. Surprised this hasn't hit more people (I think it probably has, but eh)
<TomB[m]> <ryan-summers[m]> "Hmm... Becoming extremely..." <- I think mciantyre hit that with the teensy or something like it a bit back
<ryan-summers[m]> Yeah I think a lot of devices hit it quite often, but operating systems have retry mechanisms to work around it
<ryan-summers[m]> At least I saw booster hitting it with the exact same code, but managed to get through the second or third time around
<ryan-summers[m]> As an aside, I should probably re-release usb-device since there's some breaking changes there. It's been a while and might take some time to flow through the ecosystem (i.e. synopsys-usb-otg, various HALs, etc.)
<ryan-summers[m]> Could also just patch this into a v0.2.10 release, but don't want to abandon the hard work by others on the other changes
<dav1d> Any idea why the wifi doesnt work on my esp-32-s3 devkit when I am connected via the USB port (cargo run ...) but it does work when I am connected via the UART?
<dav1d> Hangs in WifiController#start
notgull has quit [Ping timeout: 240 seconds]
notgull has joined #rust-embedded
<ryan-summers[m]> Does WFI/WFE affect RTT logging?
<ryan-summers[m]> I'm seeing logging/processing within usb-device get a little weird when WFE/WFI is used, and not entirely certain why that would be the case
<ryan-summers[m]> Ah indeed, there is a restriction on the H7 chips where you shouldn't use the sleep state if USB isn't in suspend
<dav1d> Seems to be related to the phy-enable-usb feature, RTFM helps
<ryan-summers[m]> Yeah that fixed it. Kind of a strange requirement on WFI, but I get it
<ryan-summers[m]> The synopsys USB peripheral feels really.... Kind of shoved onto the stm32 silicon. It doesn't quite behave like everything else
adamgreig[m] has joined #rust-embedded
<adamgreig[m]> It really does. The memory interface especially is odd
Guest7221 has left #rust-embedded [Error from remote client]
<TomB[m]> <ryan-summers[m]> "The synopsys USB peripheral..." <- synopsys blocks are like that
darknighte has joined #rust-embedded
korken89[m] has joined #rust-embedded
<korken89[m]> Does anyone know of a tool to create these kind of diagrams that's not manually using inkscape? :)
<ryan-summers[m]> Github Markdown mermaid supports sequence diagrams and it's pretty nice
<dav1d> mermaid, draw.io
<dav1d> plantuml
<korken89[m]> Nice! Thanks for the tips!
<ryan-summers[m]> Being able to draw that stuff in markdown is a game changer for me personally. Can keep it all version controlled nicely
<korken89[m]> Yeah, that's the main point I was thinking about as well :)
Guest7221 has joined #rust-embedded
darknighte has left #rust-embedded [#rust-embedded]
Guest7221 has left #rust-embedded [Error from remote client]
Guest7221 has joined #rust-embedded
Noah[m] has quit [Quit: Idle timeout reached: 172800s]
notgull has quit [Ping timeout: 255 seconds]
notgull has joined #rust-embedded
d3zd3z[m] has joined #rust-embedded
<d3zd3z[m]> Any tips on using #[test] in my embedded project? I was wondering if I need to move major functionality into its own crate so that cargo test will build and test it on my host, where I have std and test available.
<TomB[m]> not sure if still relevant, but do remember reading this nice post awhile ago
<d3zd3z[m]> So that is useful for on-target testing, but I'd actually like to do some testing just on the host. So, perhaps a separate crate for it would be good.
<TomB[m]> Ah yeah sorry misread
Urhengulas[m] has quit [Quit: Idle timeout reached: 172800s]
<TomB[m]> You might be able to simply set the target for cargo test? perhaps could be done with an alias
<TomB[m]> cargo test_host could be an alias then
<TomB[m]> but right if you want to run some set of tests on a host, and some other set (perhaps overlapping) on the target that would probably require some additional filtering setup
Guest7221 has left #rust-embedded [Error from remote client]
<TomB[m]> could probably be done with features, #[cfg(feature=target_test)] and enabling the feature by default for cargo test, disabling it for cargo test_host or something
<TomB[m]> I'm sure some fun things could be done
<TomB[m]> would make a nice write up if you figure it out I'm sure
<dngrsspookyvisio> you can make a workspace
<dngrsspookyvisio> might be worth looking at how defmt does it, there's a decent amount of tests ran on qemu for example
<TomB[m]> * <del>could probably be done with features, #\[cfg(feature=target\_test)\] and enabling the feature by default for cargo test, disabling it for cargo test\_host or something</del>
<TomB[m]> * <del>could probably be done with features, #\[cfg(feature=target\_test)\] and enabling the feature by default for cargo test, disabling it for cargo test\_host or something</del> probably better ways than a feature, e.g. test filters, target_feature/instruction_set attributes, etc
gauteh[m] has joined #rust-embedded
<gauteh[m]> I tend to do it like this: #![cfg_attr(not(test), no_std)] (https://github.com/gauteh/sfy/blob/main/sfy-buoy/src/lib.rs#L7)
<gauteh[m]> Even easier if you keep the host testable code in a lib crate. Otherwise you have to feature gate your main fn and entry point usually
Guest7221 has joined #rust-embedded
sourcebox[m] has quit [Quit: Idle timeout reached: 172800s]
Guest7221 has left #rust-embedded [Error from remote client]
Guest7221 has joined #rust-embedded
crabbedhaloablut has quit []
crabbedhaloablut has joined #rust-embedded
Guest7221 has left #rust-embedded [Error from remote client]
Guest7221 has joined #rust-embedded
Guest7221 has left #rust-embedded [Error from remote client]
Guest7221 has joined #rust-embedded
<d3zd3z[m]> I ended up splitting stuff off into separate crate(s). I'm not using a workspace, because now I can have a .cargo/config.toml for the build project for the target, and then the rest are easy to cargo test on the host.
IlPalazzo-ojiisa has quit [Remote host closed the connection]
notgull has quit [Ping timeout: 255 seconds]
notgull has joined #rust-embedded