Skip to content

YushiOMOTE/com_logger

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

41 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

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
        .formatter(|buf, record| writeln!(buf, "{}", record.args())) // Define own format
        .setup();

    debug!("Hello");
}