Convenience method - write multiple lanes in parallel (variadic template)
- Template Parameters
-
- Parameters
-
| lanes | Lane data as spans (can be 1-8 lanes) |
- Returns
- WriteResult with ok=true on success, or ok=false with error message
- Note
- Automatically waits for previous transmission, then starts new one asynchronously
-
Call wait() to block until transmission completes
-
IMPORTANT: All lanes MUST have identical sizes. Operation fails if sizes differ.
-
Users must handle chipset-specific padding at application level before calling write()
auto result = spi->write(lane0, lane1, lane2, lane3);
}
spi->write(lane0, lane1, lane2, lane3);
spi->wait();
A fixed-size array implementation similar to std::array.
expected< T, E > result
Alias for expected (Rust-style naming)
Definition at line 169 of file multi_lane_device.h.
169 {
170
173
174
175 for (size_t i = 0; i < sizeof...(lanes); i++) {
177 }
178
179
181 }
void push_back(const T &value) FL_NOEXCEPT
WriteResult writeImpl(fl::span< const fl::span< const u8 > > lane_data)
Internal implementation - write all lanes atomically.
constexpr T && forward(typename remove_reference< T >::type &t) FL_NOEXCEPT
constexpr size_t MAX_SPI_LANES
Maximum number of SPI lanes supported (hardware: 1-8, software: up to 32)
References fl::fl::forward(), fl::MAX_SPI_LANES, fl::FixedVector< T, N >::push_back(), and writeImpl().