16 lines
336 B
Rust
16 lines
336 B
Rust
|
|
/// Serial communication module.
|
||
|
|
/// Dispatches to native (serialport crate) or web (WebSerial API)
|
||
|
|
/// depending on the target architecture.
|
||
|
|
|
||
|
|
#[cfg(not(target_arch = "wasm32"))]
|
||
|
|
mod native;
|
||
|
|
|
||
|
|
#[cfg(target_arch = "wasm32")]
|
||
|
|
mod web;
|
||
|
|
|
||
|
|
#[cfg(not(target_arch = "wasm32"))]
|
||
|
|
pub use native::*;
|
||
|
|
|
||
|
|
#[cfg(target_arch = "wasm32")]
|
||
|
|
pub use web::*;
|