<re_irc>
<@adamgreig:matrix.org> it's not often documented as literally "mode 0" because it could be a bit ambiguous but the timing diagram usually tells the story
<re_irc>
<@adamgreig:matrix.org> sigh
<re_irc>
<@dirbaio:matrix.org> 2 does sample on falling edge, but it seems the device needs the initial dummy rising edge
<re_irc>
<@adamgreig:matrix.org> no easy way to change cpha
<re_irc>
<@firefrommoonlight:matrix.org> I can relate re mild frustration on Spi mode documentation across periphs. Also, some use mode terminology; others pol and phase. If you have multiple devices on a bus, hope there's a mode they all support
<re_irc>
<@firefrommoonlight:matrix.org> MCU-side, I've set up the API so the mode is a struct of polarity and phase tuples, with optional constructors of `mode0()`, `mode1()` etc. If I'm confused by a datasheet's description of mode, I try modes and see which work
<re_irc>
<@firefrommoonlight:matrix.org> I recall sometimes the terminology re phase and polarity is sometimes inconsistent, but can't recall what's confused me in the past
<re_irc>
<@adamgreig:matrix.org> multiple devices on a bus don't need to use the same mode
<re_irc>
<@adamgreig:matrix.org> they'll ignore anything while nto selected
<re_irc>
<@adamgreig:matrix.org> (does mean you have to reconfigure the spi peripheral between devices though)
<re_irc>
<@firefrommoonlight:matrix.org> Oh - reconfiguring the periph could be an option - good point
<re_irc>
<@firefrommoonlight:matrix.org> I should probably add a method to do that
<re_irc>
<@firefrommoonlight:matrix.org> I have a comment in one of my projects along the line of "Device A seems to work with modes A and B. Device B works with all modes except B. So, we use A
<re_irc>
<@dirbaio:matrix.org> even different freqs! neat!
<re_irc>
<@almindor:matrix.org> yeah it works fine with my usb host on 100khz and display at 54mhz
<re_irc>
<@almindor:matrix.org> there are timing issues outside of SPI tho e.g. if the display resets (even soft reset) and you don't give it a delay it might register some stuff and go wonky even if CS is high