Skip to content
  • Blog
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo

Community Forum

  1. Home
  2. Categories
  3. Téléinfo
  4. Téléinfo
  5. Interruptions extérieures ?

Interruptions extérieures ?

Scheduled Pinned Locked Moved Téléinfo
2 Posts 1 Posters 613 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • G Offline
    G Offline
    Géryko
    wrote on last edited by Géryko
    #1

    Bonjour à tous,
    J'utilise la bibliothèque LibTeleinfo.h et comme j'ai de l'espace disponible, je voudrais ajouter
    une fonction gadget en utilisant une interruption extérieure sur pin 15. (sur ESP32)
    Je voudrais éviter de modifier le xx.h et le xx.CPP. Comment se sortir de là ?
    Bien évidemment je ne suis pas programmeur pro.

    Voici ce que j'ai fait (raccourci) :
    boolean drapeau = 0;
    void setup() {
    pinMode(15, INPUT_PULLUP); //Configuration du pin en entrée pullup
    attachInterrupt(15, fonction_ISR, FALLING);
    }

    void IRAM_ATTR fonction_ISR() {
    drapeau = 1; // Code de la fonction (traitement par la suite)
    }

    Me donne :
    error: 'fonction_ISR' was not declared in this scope

    Merci d'avance à qui pourrait m'aider.

    1 Reply Last reply
    • G Offline
      G Offline
      Géryko
      wrote on last edited by Géryko
      #2

      Bonjour à tous,

      Je pense avoir trouvé la solution !
      La fonction void IRAM_ATTR fonction_ISR() { ... } doit se trouver en amont du setup en non après.

      Qu'on se le dise.
      ça peut paraitre évident mais ... il faut le savoir et personne n'en parle.
      A+

      1 Reply Last reply

      Hello! It looks like you're interested in this conversation, but you don't have an account yet.

      Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

      With your input, this post could be even better 💗

      Register Login
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      0

      Online

      5.8k

      Users

      565

      Topics

      5.3k

      Posts

      Top Topics

      Popular Tags

      teleinfo
      25 topics
      arduino
      19 topics
      remora
      16 topics
      esp8266
      10 topics
      arduipi
      10 topics
      raspberry
      8 topics
      wifinfo
      7 topics
      broadcast
      7 topics
      Copyright © 2022 Charles-Henri Hallard | Return to blog page | Powered by NodeBB
      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Blog
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups