Skip to content
Parallax Learn

Parallax Learn

  • Welcome
  • Tutorials
        • Tutorial Series head tag

          Tutorial Series
        • Tutorial Series

          The special, classroom-ready series pages are organized collections of tutorials for our most popular hardware and/or languages. The tutorials for each topic are conveniently accessible from a single page, shown in the order it is recommended that they be completed.
        • Robotics Series Head tag

          Robotics Series
        • Robotics Series

          • Artificial Intelligence
          • Cybersecurity: Radio Data tutorialCybersecurity
          • cyber:bot + Python
          • cyber:bot + MakeCode
          • Boe-Bot Tutorial SeriesBoe-Bot
          • Arduino Shield-Bot
          • ActivityBot with C TutorialsActivityBot + C
          • ActivityBot with BlocklyProp Tutorial SeriesActivityBot + BlocklyProp
          • Scribbler 3 Tutorial SeriesScribbler 3
        • Electronics & Programming Series Head tag

          Electronics & Programming Series
          • BS2 Board of Education Tutorial SeriesBS2 Board of Education
          • Propeller C-Language BasicsPropeller C Basics
          • FLiP Try-It Kit C Tutorial SeriesFLiP Try-It Kit + C
          • FLiP Try-It Kit BlocklyProp TutorialsFLiP Try-It Kit + BlocklyProp
          • Badge WX Tutorial SeriesBadge WX
          • Propeller BlocklyProp Basics and ProjectsPropeller BlocklyProp Basics
          • View All Tutorial Series »
        • Browse Tutorials
        • Browse Tutorials

          Individual tutorials sorted by robot or kit, and language.
        • By Robot or Kit
          • ActivityBot
          • SumoBot WX
          • Boe-Bot
          • Shield-Bot
          • cyber:bot
          • Badge WX
          • ELEV-8
          • ARLO
        • By Language
        • By Language

          • Propeller C
          • Arduino
          • BlocklyProp
          • PBASIC
          • Python
          • MakeCode
          • View All Tutorials »
  • Educators
  • Reference
  • Downloads
  • Home
  • All Courses
  • Arlo with an Activity Board Brain

Arlo with an Activity Board Brain

Activity Board Arlo Control System Adjustments

Activity Board Arlo Control System Adjustments

Integration KI and deadzone DZ are part of a group of values called control system constants that may need to be tuned to accommodate certain payload weights, and gearbox play.  This example program is actually setting the default values, but you can change them, and then test the responses under the conditions you need the Arlo to perform. 

If your battery is charged, and the payload is small, the default settings should be fine.  If payloads increase and decrease during runtime, you may wish to programmatically adjust those constants, either to give it some extra push to get to each final goal, or to apply less push toward the final goal to prevent oscillations (repeated over corrections).  For more information, see the DHB-10 command set for information on KI, KIT, KIP, and DZ. 

Code for making the changes semi-permanent by writing them to the DHB-10’s EEPROM have been commented out.  As long as you keep the lines with STORE commented, the changes only affect performance until the DHB-10 is restarted.  You can restart the DHB-10 by pressing and releasing its Reset button or turning the Motors power off, and then back on.

NOTE: No need to run this program unless you want to observe different possible Arlo behaviours as it approaches its final distance destination.

/*
  Arlo - Control System Adjustments.c
*/

#include "simpletools.h"
#include "arlodrive.h"

char *reply;

int main()
{
  print("CHECK CONSTANTS\n\n");
  print("To DHB-10      From DHB-10\n");
  print("-----------    ----------------\n");

  print("KI\\r           ");
  reply = dhb10_com("KI\r");
  if(*reply == '\r') print("\\r\n");
  else print("%s", reply);
 
  print("DZ\\r           ");
  reply = dhb10_com("DZ\r");
  if(*reply == '\r') print("\\r\n");
  else print("%s", reply);

  print("\n\nSET CONSTANTS\n\n");
  print("To DHB-10      From DHB-10\n");
  print("-----------    ----------------\n");
 
  print("KI 65\\r        ");
  reply = dhb10_com("KI 65\r");
  if(*reply == '\r') print("\\r\n");
  else print("%s\n", reply);
 
  print("DZ 1\\r         ");
  reply = dhb10_com("DZ 1\r");
  if(*reply == '\r') print("\\r\n");
  else print("%s\n", reply);

 
  print("\n\nSTORE CONSTANTS\n\n");
  print("To DHB-10      From DHB-10\n");
  print("-----------    ----------------\n");

  print("STORE KI\\r     ");
  reply = dhb10_com("STORE KI\r");
  if(*reply == '\r') print("\\r\n");
  else print("%s\n", reply);
 
  print("STORE DZ\\r     ");
  reply = dhb10_com("STORE DZ\r");
  if(*reply == '\r') print("\\r\n");
  else print("%s\n", reply);
 
  print("\nAll done!\n");
}

Printer-friendly version
Control the Activity Board Arlo with Serial Messages
Prev
Troubleshooting Your Arlo + Activity Board
Next

DISCUSSION FORUMS | PARALLAX INC. STORE

About | Terms of Use | Feedback: learn@parallax.com | Copyright©Parallax Inc. 2024

© 2025 Parallax Learn • Built with GeneratePress