Pages: [1]   Go Down
Author Topic: Rotary enconder, interrupts and LCD Display  (Read 418 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Karma: 0
Posts: 1
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi all,

Probably this will be a stupid question, but I'm a real newbie in this "electronic world"...

I have developed a very simple sketch to receive digital input through a rotary encoder (24 steps by turn). This sketch, by the moment, is only able to send the position of the encoder to serial console, but I need to print this position also to a LCD display.

I have a standard LCD display controlled by LiquidCrystal library, that works properly.

The problem is that I have to use digital pin 2 as "interrupt 0", and this pin is used also by library as D7 pin in LCD display...

By the way, I'm using a Duemilanove board, but I have also a Mega 328.

How to solve this? Could I change the way that library uses D7 pin and assign it to another free pin on my arduino board another than digital pin 2? Or on the other hand, could I use an "interrupt" function with a different digital pin apart from digpin 2?

Thanks to all!

Global Moderator
Offline Offline
Shannon Member
Karma: 220
Posts: 13836
In theory there is no difference between theory and practice, however in practice there are many...
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

start with posting your code ...

Rob Tillaart

Nederlandse sectie -,77.0.html -
(Please do not PM for private consultancy)

Pages: [1]   Go Up
Jump to: