readmem

Crates.ioreadmem
lib.rsreadmem
version0.1.0
sourcesrc
created_at2020-11-07 09:41:33.011985
updated_at2020-11-07 09:41:33.011985
descriptionRead support for Verilog $readmemb/$readmemh files
homepage
repositoryhttps://github.com/lf-/readmem
max_upload_size
id309584
size11,090
Jade Lovelace (lf-)

documentation

https://docs.rs/readmem

README

readmem

A rust library to read data of the format required by the Verilog system tasks $readmemb and $readmemh.

Example:

let file_content = r#"
    @0 0
    @1 1 // one!
    2
"#;
use readmem::{readmem, ContentType};
assert_eq!(vec![0, 1, 2], readmem::<u8>(file_content, ContentType::Hex).unwrap());
Commit count: 2

cargo fmt