I am using fingerprint module r307 and LCD together. In that, I am using 2,3 digital pins of arduino for data transfer to the fingerprint.(I tried other pin configurations for this but it didn't work) But as I am connecting LCD, it also requires same 2,3 digital pins of arduino and it is not possible for me to use 2 and 3 pins of Arduino for both lcd and fingerprint sensor for data transfer. Can you please suggest an alternative to this. Can we use analog pins of arduino as digital ones and if so the how?? PLEASE HELP... Thank you!!

  • 2
    Please add which libraries you are using. You could also add your sketch so far. – Mikael Patel Dec 20 '18 at 13:10
  • When you instantiate an instance of the LCD code, likely you will have a choice of pins to use. But even with this flexibility (if the library programmer was thoughtful enough & was able to include it), the limits of the particular Arduino and processor you have chosen may make the project difficult or impossible. As @MikaelPatel has asked, let us know the libraries you are using so we can inspect its possibilities. – st2000 Dec 20 '18 at 15:11

Can we use analog pins of arduino as digital ones and if so the how??

Yes. You just treat them the same as any other digital pin. On an Arduino all pins are digital. It's just that some have additional functionality, like analog input, or PWM, or serial, or SPI, etc.

  • ADC pin on esp8266? – Juraj Dec 20 '18 at 15:15
  • @Juraj No one said anything about an ESP8266. Which, incidentally, is NOT an Arduino. – Majenko Dec 20 '18 at 15:18
  • I know, but I would not wonder if OP had one and called it Arduino – Juraj Dec 20 '18 at 15:20
  • @Juraj Unlikely, since they talk of analog "pins"", (plural) and the ESP8266 only has one. They'd then talk about "the analog pin". – Majenko Dec 20 '18 at 15:24
  • 1
    @DaveNewton It's Juraj. You're never quite sure what goes through his mind sometimes ;) – Majenko Dec 20 '18 at 16:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.