Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Topics - ulmtn

Pages: [1]
Hardware mods / MEGA2560
« on: January 28, 2017, 01:43:31 PM »
My Balanduino clone is based on an Arduino Mega 2560 ADK (works also with the Mega 2560 and USB host shield). For encoder interrupts the Ports B, K and J corresponding to interrupt vectors PCINT0, PCINT1 and PCINT2 can be used as on the original Mega 1284P .But the most stable balancing is achieved with PCINT0 (PCINT0, pin 13 and pin 10). When switching to PCINT1 (pin 14 and 15) or PCINT 2 (A8, A9 analog pins) the reaction to pushing the robot is much weaker. Is there a reason, that other Pin Change interrupts behave differently than PCINT0?
The only configuration that shows the same performance as the original Balanduino robot is using the attachInterrupts 0 and 1 (pin2 and 3) together with PCINT0 on PortB pins, like in Balanduino Revision 1.2. However, I wanted to implement the improvements of Revision 1.3 with different Ports for each encoder. How is this possible on the Mega2560 without loss in performance?

Pages: [1]