how do I limit the display to only display the first four characters of the parameter to level enough space for the value?

Hi, I am not entirely new to arduino or OSC, but I am very much at the modifying scripts stage and slowing working things out. So any help is great appreciated

I am using a 128x128 tft screen.

Looking at the script the parameter OSC field is used for OSC and for the display.

This is great when it comes to Pan,Tilt, Zoom etc but becomes a mess once I get beyond 4 characters.

is there a way to limit the number of characters displayed, so Diff of Diffusion.

Alternatively could the labelling be done so that the display is separate to the parameter? so Gobo_Wheel_1 is Go 1 and GoR 1 for example?

Parents
  • There are several ways to deal with this but all of them are going to require a better processor than a nano.  You can build a table of parameter names to look for and then change the display bases on that but it is going to eat up ram as sstaub has pointed out.  There isn't a complete list of parameters readily available.  If you look in the CIA you can see a what parameters are in the patched fixtures but it won't be all the possible parameters.  I would suggest just dealing with the parameters you need and change the code in the  future when necessary.  There are some ways to make text scroll so you could include the entire parameter name but those will also eat up ram.  

  • Is it not already built in to the script, to display a different parameter label.

    struct Parameter {
    String name;
    String display;
    float value;
    float lastDisplayed;
    };
    const uint8_t PARAMETER_MAX = 6;
    struct Parameter parameter[PARAMETER_MAX] =
    {
    // {"empty", "--"},

    the part after the comma in the {

    emtpy being displayed as -- in that example?

    Looking through your modifiation sstaub eg

    {"thrust_A", "ThrustA"},

    Is that not what that does, use thrust_A as the OSC parameter but display ThrustA to the display?

Reply
  • Is it not already built in to the script, to display a different parameter label.

    struct Parameter {
    String name;
    String display;
    float value;
    float lastDisplayed;
    };
    const uint8_t PARAMETER_MAX = 6;
    struct Parameter parameter[PARAMETER_MAX] =
    {
    // {"empty", "--"},

    the part after the comma in the {

    emtpy being displayed as -- in that example?

    Looking through your modifiation sstaub eg

    {"thrust_A", "ThrustA"},

    Is that not what that does, use thrust_A as the OSC parameter but display ThrustA to the display?

Children
No Data