feat(profiler-display): add std feature

This commit is contained in:
Yandrik 2024-11-18 16:34:44 +01:00
parent ef99d64d08
commit 6446310023
3 changed files with 7 additions and 1 deletions

View File

@ -3,6 +3,9 @@ name = "embedded-graphics-profiler-display"
version = "0.1.0"
edition = "2021"
[features]
std = []
[dependencies]
atomic = "0.6.0"
embassy-time = "0.3.2"

View File

@ -1,4 +1,4 @@
#![no_std]
#![cfg_attr(not(feature = "std"), no_std)]
#![no_main]
mod profiler;

View File

@ -1,4 +1,7 @@
use atomic::Atomic;
#[cfg(feature = "std")]
use std::time::{Duration, Instant};
#[cfg(not(feature = "std"))]
use embassy_time::{Duration, Instant};
use embedded_graphics::draw_target::DrawTarget;
use embedded_graphics::{Drawable, Pixel};