Pin number mismatch

Discussion in 'UDOO NEO' started by matib12, Feb 18, 2016.

  1. matib12

    matib12 New Member

    Joined:
    Feb 9, 2016
    Messages:
    17
    Likes Received:
    7
    I'm developing a code using cross compilation on my PC using Arduino IDE 1.6.5 with the board packet from https://udooboard.github.io/arduino-board-package/package_udoo_index.json. I'm reading pin 11 but its state never changes. I must connect electric signal to the pin 10 in order to obtain change of the value. It is clear to me that there is a mismatch in pin assignment in the library. I'm not able to fix it by myself. Below there is is my Arduino sketch which reproduces the error:

    Code:
    void setup() {
      // put your setup code here, to run once:
      Serial.begin(115200);
      pinMode(11, INPUT);
     
    }
    
    void loop() {
      // put your main code here, to run repeatedly:
      Serial.println(digitalRead(11));
      delay(1000);
    }
     
  2. matib12

    matib12 New Member

    Joined:
    Feb 9, 2016
    Messages:
    17
    Likes Received:
    7
    It seems that pin 10 and 11 are swapped.
     
  3. Andrea Rovai

    Andrea Rovai Well-Known Member

    Joined:
    Oct 27, 2014
    Messages:
    1,703
    Likes Received:
    240
    Dear @matib12
    first of all, welcome in the forum!
    In a second place, we're aware of this issue. It will be fixed soon
     
  4. matib12

    matib12 New Member

    Joined:
    Feb 9, 2016
    Messages:
    17
    Likes Received:
    7
    For those who are eager to fix the problem by their own, you can edit wiring_digital.c file in the board package. First you need to download *.tar file with the board packet and make a local copy of it in the Arduino SDK folder: arduino-1.6.5-r5\hardware\udooboards\udooneo-arduino-solox-1.6.5
     
    Andrea Rovai likes this.
  5. Andrea Rovai

    Andrea Rovai Well-Known Member

    Joined:
    Oct 27, 2014
    Messages:
    1,703
    Likes Received:
    240
    Muchas gratias, I'm implementing your solution in the Troubleshooting session, it will soon be ok.
     

Share This Page