---
title: "Discussion on \"ESP32 Standard Library Embedded Rust: GPIO Interrupts\" | Hashnode"
description: "Discussion on \"ESP32 Standard Library Embedded Rust: GPIO Interrupts\". This blog post is the eighth of a multi-part series of posts where I explore various peripherals in the ESP32C3 using standard library embedded Rust and the esp-idf-hal. Please be aware that certain c"
url: "https://hashnode.com/posts/esp32-standard-library-embedded-rust-gpio-interrupts/64f9e579c9aab703dd159b34"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [ESP32 Standard Library Embedded Rust: GPIO Interrupts](https://blog.theembeddedrustacean.com/esp32-standard-library-embedded-rust-gpio-interrupts?utm_source=hashnode&utm_medium=feed)

This blog post is the eighth of a multi-part series of posts where I explore various peripherals in the ESP32C3 using standard library embedded Rust and the esp-idf-hal. Please be aware that certain c

Sep 7, 2023 · 11 min read · blog.theembeddedrustacean.com  
Updated Jul 1  
Read the article

-   [#rust](https://hashnode.com/tag/rust)
-   [#esp32](https://hashnode.com/tag/esp32)
-   [#embedded](https://hashnode.com/tag/embedded)
-   [#beginners](https://hashnode.com/tag/beginners)

## Written by

[Omar Hiari](https://hashnode.com/@omarhiari)

@omarhiari

  
[View profile](https://hashnode.com/@omarhiari)

I am an 📟 Embedded Engineer with years of experience in both industry 🏭 and academia 🏫. Passionate Mentor 👨‍💼 and Instructor 👨‍🏫. Rustacean 🦀

## Responses 1

Markdown supported · ⌘↵ to post

[Ant Skelton](https://hashnode.com/@blowback)

[Nov 14, 2023](https://hashnode.com/posts/esp32-standard-library-embedded-rust-gpio-interrupts/64f9e579c9aab703dd159b34/comment/65536c27fbdaaf31319ed323)

Great example, thank you! I found I had to call `button.enable_interrupt().unwrap()` inside the loop, or I'd only get precisely one interrupt. This is noted in the most recent docs for `subscribe()` where they note that you must call it from non-ISR context.

[Omar Hiari](https://hashnode.com/@omarhiari)

[Nov 14, 2023](https://hashnode.com/posts/esp32-standard-library-embedded-rust-gpio-interrupts/64f9e579c9aab703dd159b34/comment/65536c27fbdaaf31319ed323#reply-6553af8ffbdaaf31319edd3e)

Thanks for reading! To your comment, there has probably been a change in the interface, however, it makes sense. Resetting the interrupt enable is not unusual.
