V5 Controller Screen - Clearing issues

  1. 5 weeks ago

    robonxt

    Dec 9 In a room where there are bots...

    Has anyone ran into the problem of clearing the controller screen and it doesn't completely clear the screen?
    Also does .Screen.clear() resets the cursor back to the top of the screen, and if I have to manually set it, what command would that be?

  2. Edited 5 weeks ago by John TYler

    The clearScreen method was written before the 50ms limit on messages to the handheld controller screen was added to the firmware. In Robot Mesh Studio, VCS, and PROS' equivalent, clearScreen tries to send three clearLine messages in rapid succession, two of which always fail because of the firmware messaging limit change.

    Short version, don't use clearScreen for now. As for the cursor, it's good practice to set location before you write rather than after you clear. That should be through the void setCursor (int32_t row, int32_t col) method.

  3. jpearman

    Dec 10 Moderator, ROBOTC Tech Support, V5 Beta Moderator Los Angeles 8888
    Edited 5 weeks ago by jpearman

    @John TYler The clearScreen method was written before the 50ms limit on messages to the handheld controller screen was added to the firmware.

    Not true with VCS, with VCS 1.0 we still have original SDK and send three clear line commands, but 50mS message requirement should be handled ok. In the next VCS release it will be more efficiant as we added a special clear screen message for the controller.

  4. robonxt

    Dec 11 In a room where there are bots...

    I end up writing my own clear screen function and GUI....

  5. last week

    13666A

    Jan 3 13666A

    @robonxt I end up writing my own clear screen function and GUI....

    Would you mind sharing your functions? I'm looking into making my own as well.

  6. robonxt

    Jan 3 In a room where there are bots...

    @13666A Would you mind sharing your functions? I'm looking into making my own as well.

    Here's the system I wrote before Christmas:
    https://www.vexforum.com/index.php/36507-introducing-access-os-an-v5-controller-gui-system

 

or Sign Up to reply!