aboutsummaryrefslogtreecommitdiff
path: root/src/main.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/main.rs')
-rw-r--r--src/main.rs10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/main.rs b/src/main.rs
new file mode 100644
index 0000000..419e7f7
--- /dev/null
+++ b/src/main.rs
@@ -0,0 +1,10 @@
+fn main() {
+ // It is necessary to call this function once. Otherwise, some patches to the runtime
+ // implemented by esp-idf-sys might not link properly. See https://github.com/esp-rs/esp-idf-template/issues/71
+ esp_idf_svc::sys::link_patches();
+
+ // Bind the log crate to the ESP Logging facilities
+ esp_idf_svc::log::EspLogger::initialize_default();
+
+ log::info!("Hello, world!");
+}