Shop Learn
Sumobot WX tutorial code for Ir takes 20 sec to update - problem??? — Parallax Forums

Sumobot WX tutorial code for Ir takes 20 sec to update - problem???

From this tutorial: learn.parallax.com / tutorials / sumo WX / Ir detect, using this download file: SumoBot-Front-IR-Terminal.svg.

Values displayed on terminal are correct. But update is every 20+ seconds. In code I can only see delays of about 100 ms. (Contents of the green "User Defined Code" are a mystery.) Then after first few displays, the boilerplate labels don't appear correct. Then only some or both values appear.

Problem is worse for lower values (close reflector) than higher values (no reflector).

Any idea of how to get sensing down to < 1 sec?

I once had something like this where baud did not match and every now and then they came into phase to transmit. But I don't see buad setting for terminal blocks or for terminal.

I re-seated both Tx and Rx components.

Thanks.

Comments

  • I can't seem to duplicate those symptoms. The function IR Front Terminal block has 350 ms pauses, and I'm guessing function IR Front takes about 50 ms. So, the updates should happen at around 2.25 Hz.

    If you have a Windows Machine, a quick test to check if your bot or BlocklyProp Solo is the cause would be to try displaying the data with Parallax Serial Terminal. The baud rate is 115200, and here's a link to the download:
    https://www.parallax.com/package/parallax-serial-terminal/

    Also, let's rule out some of the basics:

    • Try new alkaline batteries.
    • Check if you have BlocklyProp Launcher v1.0.1. If you have an older version, go to solo.parallax.com with BlocklyProp Launcher closed, and then click the shaded pinkish link in the upper-left that says: "Unable to contact the BlocklyProp Launcher. Click for more information." That should give you the latest download links.
    • Connect through USB and not WX module. If a WX or XBee module is in the socket, remove it. (Wireless is okay, but we need to remove it from the equation in initial troubleshooting.)
    • Re-download the file from the link below, open it with BlocklyProp Launcher, and load it into the FLiP (unmodified):
      https://learn.parallax.com/tutorials/robot/sumobot-wx/ir-sumobot-wx-opponent-detection-and-tracking/terminal-ir-distance

    • Make sure to open BlocklyProp Solo by using the blue BlocklyProp Solo button in the BlocklyProp Launcher.

    • Check the top of the FLiP and verify that the 5-9V light is green.
    • While the terminal is open, the red COM tx light should turn on briefly a couple times per second.
    • Check if the rate changes (again without a module in the WX socket) with the PROG SER2 switch in 31/30 vs. 25/24 positions.
Sign In or Register to comment.