Encoder and Atmega

For questions and comments on programming in general. And for any items that don't fit into the forums below.

Moderators: Benj, Mods

Post Reply
OlegK
Posts: 2
Joined: Wed Nov 22, 2017 10:24 am
Been thanked: 1 time
Contact:

Encoder and Atmega

Post by OlegK »

Hello
Can't deal with the work of the encoder on ATmega (8 or 64). The value of "Count" even in the simulation can be jumped randomly. I used the scheme from EB073-30-1.pdf. The behavior of circuit similar to the simulation.
Regards
Attachments
ATMEGA8__OLED_ENCODER_INT.fcfx
(12.87 KiB) Downloaded 147 times

User avatar
LeighM
Matrix Staff
Posts: 2178
Joined: Tue Jan 17, 2012 10:07 am
Has thanked: 481 times
Been thanked: 699 times
Contact:

Re: Encoder and Atmega

Post by LeighM »

Hi,
Try running simulation at full speed, it works OK for me.
Although Flowcode simulation of interrupts is not as accurate as target.

Also, you will need to clear the area of screen before printing the number,
otherwise if you print 99 after printing 100 you will get 990, which I suspect is causing the appearance of random jumping

OlegK
Posts: 2
Joined: Wed Nov 22, 2017 10:24 am
Been thanked: 1 time
Contact:

Re: Encoder and Atmega

Post by OlegK »

Thank You. All works good.

Post Reply