mirror of
https://github.com/mytechnotalent/Embedded-Hacking.git
synced 2026-07-07 21:18:10 +02:00
Add // comments to all use statements in driver .rs files
- Add // comments above top-level use imports in uart.rs, blink.rs, button.rs - Add // comments above test module use imports (use super::*, Infallible, ErrorType) in all 8 driver .rs files - All 8 drivers build, all 75 tests pass
This commit is contained in:
@@ -25,12 +25,19 @@
|
||||
//! OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
//! SOFTWARE.
|
||||
|
||||
// Rate extension trait for .Hz() baud rate construction
|
||||
use fugit::RateExtU32;
|
||||
// Non-blocking I/O helper for UART read/write
|
||||
use nb::block;
|
||||
// Alias our HAL crate
|
||||
use rp235x_hal as hal;
|
||||
// Clock trait for accessing system clock frequency
|
||||
use hal::Clock;
|
||||
// UART configuration and peripheral types
|
||||
use hal::uart::{DataBits, Enabled, StopBits, UartConfig, UartPeripheral};
|
||||
// GPIO pin types and function selectors
|
||||
use hal::gpio::{FunctionNull, FunctionUart, Pin, PullDown, PullNone};
|
||||
// UART0 peripheral singleton type
|
||||
use hal::pac::UART0;
|
||||
|
||||
/// Type alias for the configured TX pin (GPIO 0, UART function, no pull).
|
||||
@@ -158,6 +165,7 @@ impl UartDriver {
|
||||
|
||||
#[cfg(test)]
|
||||
mod tests {
|
||||
// Import all parent module items
|
||||
use super::*;
|
||||
|
||||
#[test]
|
||||
|
||||
Reference in New Issue
Block a user