Recent Posts

Pages: 1 [2] 3 4 ... 10
Software development / Re: Programing Balanduino code
« Last post by Lauszus on February 20, 2017, 04:45:44 PM »
Hi Sten,

You need to be more specific. What exactly do you want to do? Do you want to move the Balanduino from your own application?

Kristian Sloth Lauszus
Software development / Programing Balanduino code
« Last post by Sten on February 16, 2017, 11:18:36 AM »

I am trying to program the Balanduino code so that the Balanduino can move forward a certain distance and then stop. I have some problem to understand the Balanduino code, mainly because I am used to program in java and not in c. Could someone please explain how the code should look like and which methods I should call in the different classes and what theses methods do? Thanks for any help  :)


Hardware mods / Re: MEGA2560
« Last post by ulmtn on February 04, 2017, 10:09:12 AM »
Thank you for the reply. The priority  is highest in PortB. I am happy, that there is a solution using four external interrupts of the Mega2560 to count encoder :
 #define leftEncoder1Pin   2  // Used for attachInterrupt
 #define leftEncoder2Pin  19 // Used for attachInterrupt
 #define rightEncoder1Pin 3  // Used for attachInterrupt 
 #define rightEncoder2Pin 18 // Used for attachInterrupt

  attachInterrupt(digitalPinToInterrupt(leftEncoder1Pin), leftEncoder, CHANGE);
  attachInterrupt(digitalPinToInterrupt(rightEncoder1Pin), rightEncoder, CHANGE);
  attachInterrupt(digitalPinToInterrupt(leftEncoder2Pin), leftEncoder, CHANGE);
  attachInterrupt(digitalPinToInterrupt(rightEncoder2Pin), rightEncoder, CHANGE);

This gives the same performance as Revision 1.2 with separate encoder functions. Not sure if it really better than Rev 1.2.
The defines for PIN_CHANGE_INTERRUPT_VECTOR can be deleted, but all the #if defined statements must be deleted, too
Hardware mods / Re: MEGA2560
« Last post by Lauszus on February 03, 2017, 10:52:29 AM »
Hmm I don't really know. Maybe those interrupts has a lower priority? Unfortunately I don't know anyway to solve your problem. Please keep me posted if you find a solution.

Kristian Sloth Lauszus
Hardware mods / MEGA2560
« Last post by ulmtn 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?
Getting Started / Re: Controlling the Balanduino with regular 2 ch TX/Receiver
« Last post by Lauszus on June 04, 2016, 01:50:19 AM »
Yes you can. Please read the following section of the readme:

Kristian Sloth Lauszus
Getting Started / Controlling the Balanduino with regular 2 ch TX/Receiver
« Last post by Jimmy on June 03, 2016, 06:59:28 PM »
Is there a way to connect or use a regular 2 CH Transmitter and receiver to control the balanduino bot?

Getting Started / Re: Wheels go in opposite directions at full speed
« Last post by Lauszus on June 02, 2016, 11:59:31 AM »
I would recommend the following motors:

Kristian Sloth Lauszus
Getting Started / Re: Wheels go in opposite directions at full speed
« Last post by stevep on June 01, 2016, 03:05:44 PM »
Revision is correct. can you point me to a good source for motors and encoders?...I suspect the ones that I have (Chinese) might be the issue? What do you think?
Software development / Re: PID loop time
« Last post by Lauszus on May 29, 2016, 01:05:42 PM »
The loop time is about 10 ms.

Kristian Sloth Lauszus
Pages: 1 [2] 3 4 ... 10