Navigation

    • Register
    • Login
    • OpenHardware.io
    • Categories
    • Recent
    • Tags
    • Popular
    1. Home
    2. ej3359
    3. Topics
    • Profile
    • Following
    • Followers
    • Topics
    • Posts
    • Best
    • Groups

    Topics created by ej3359

    • ej3359

      How to force ID of a sensor?
      Development • • ej3359  

      3
      0
      Votes
      3
      Posts
      1807
      Views

      ej3359

      Thank's!
    • ej3359

      Software serial Library
      Development • • ej3359  

      2
      0
      Votes
      2
      Posts
      2149
      Views

      adrianmihai83

      I get the same error when using the SoftwareSerial library. More specific, it is a known limitation that you cannot use SoftwareSerial.h and PinChangeInt.h together without altering one or another. Let me give you an example, I was in the same case as you are now, I wanted to use an RF ID reader (125 kHz - RDM6300) on a software serial pin, in my case was A2 (don't ask why, this was the only input pin that I have on an UNO, it is stuffed with keyboard, display, motor actuator for door opening, button for manual door opening, ringer button and NRF24 - this is my all in one entrance sensor ). So, what you have to do: pin A2 is on Port C you have to disable in the SoftwareSerial.h the other intrerupts, except the one associated to PortC, that would be - PCINT1 is for Port C : PCINT0 is for Port B PCINT2 is for Port D PCINT3 - it is not the case of 328P so you can leave it uncommented so in SoftwareSerial.h comment the following for PCINT0 and 2: #if defined(PCINT0_vect) ISR(PCINT0_vect) { ReceiveOnlySoftwareSerial::handle_interrupt(); } #endif The other thing that you have to do now is to tell PinChangeInt.h that you use Port C for other purpose. To do this, in MyGateway.cpp, ahead of the #include "utility/PinChangeInt.h" you should include the following: #define NO_PORTC_PINCHANGES Save, upload, enjoy... And don't forget to modify back what you altered. This assumes that you don't use intrerupts on pins...