#com #logger #logging #log #serial

com_logger

Serial port logger through COM ports

1 unstable release

0.1.0 Dec 14, 2019

25 downloads per month

MIT license

7KB
99 lines

com_logger

Latest version Documentation License Actions Status

Serial port logger through COM ports.

  • Doesn't require std (no_std)
  • Doesn't require alloc
use log::*;

fn main() {
    com_logger::init();

    info!("Starting");
}

Configuration

use log::*;

fn main() {
    com_logger::builder()
        .base(0x2f8)                  // Use COM2 port
        .filter(LevelFilter::Debug)   // Print debug log
        .setup();

    debug!("Hello");
}

lib.rs:

com_logger is a logger through COM port.

This library is no_std, and doesn't rely on alloc.

use log::*;

fn main() {
   com_logger::init();

   info!("Hello");
}

The serial port base address and logging level filter can be configured.

use log::*;

fn main() {
   com_logger::builder()
       .base(0x2f8)                  // Use COM2 port
       .filter(LevelFilter::Debug)   // Print debug log
       .setup();

   debug!("Hello");
}

Dependencies

~195KB