Displaying string instead of input

Forum Home Forums Understanding the Software Displaying string instead of input

Viewing 9 posts - 16 through 24 (of 24 total)
  • Author
    Posts
  • #9587
    Mikhail
    Moderator

    Hi,

    It’s possible. But the subject of this topic is not appropriate the question. Please create a new topic to discuss.

    #15689
    Ashashash
    Participant

    Hello Mikhail,
    I use 6.2.1.1 version,
    I need to display text values instead of input numberic value,
    But tried Formats, also Units. Seems all options are limited to text size 1000 symbols.
    Is there an option to use 20000 or more symbol formula?

    #15693
    Mikhail
    Moderator

    Hello,
    Probably, another solution is needed in that case. Please provide screenshots of your settings for better understanding.

    #15694
    Ashashash
    Participant

    Ok, for example:
    if input 1001 value is:
    434.081, I need text to be displayed “Error +10V ref. sensor system : I/O board control cabinet”;
    233.001 -General warning message : software update required;
    62.031 -Feeding fault : System circuit breaker off;
    60.010 -Mains failure : Overvoltage L1+L2+L3;
    60.028 -Mains failure : Overfrequency (restart).

    And so on. Few hundred lines like this.
    Also for different equipment different set of texts

    #15703
    Mikhail
    Moderator

    For such long messages, create a function that returns a string and use it for an input channel.
    For example:

    public string MyString()
    {
      if (Cnl < 0) return "Abc";
      else return "Cde";
    }

    In the channel input formula: MyString()

    #15820
    Jorge
    Participant

    Hi, I have a similar question. I am receiving data via MQTT and getting an 8-bit binary that I want to convert to an ASCII character. I am doing the conversion in the JS file, but when I try to put the character in a view table, I get an error.

    Communication line error:
    line error

    js file:
    js file

    #15821
    Mikhail
    Moderator

    Hello,
    The MQTT client driver supports only numbers.

    #15828
    rsepulve
    Participant

    Hi Mikhail,
    This is Rodrigo Sepulveda, from Chile.
    I have an issue.

    I have the folowing payload from UG56 Milesight Lora gateway.

    {“adc_1”: 4, “adc_2”: 4, “applicationID”: 1, “devEUI”: “24e124445d182905”,
    “deviceName”: “VDBT-TDC-03”, “gpio_counter_1”: 4018, “gpio_input_2”: 0,
    “gpio_input_3”: 0, “gpio_input_4”: 1, “gpio_output_1”: 0, “gpio_output_2”: 0,
    “modbus_chn_2_alarm”: 1}

    but the original from field, from Milesight UC300 device is:

    {“adc_1”: 4, “adc_2”: 4, “gpio_counter_1”: 4018, “gpio_input_2”: 0, “gpio_input_3”: 0, “gpio_input_4”: 1, “gpio_output_1”: 0, “gpio_output_2”: 0,
    “modbus_chn_2_alarm”: 1}

    But, I can´t take off this 3 elements thats UG56 gateways add:

    “applicationID”: 1, “devEUI”: “24e124445d182905”, “deviceName”: “VDBT-TDC-03”

    This cause an error in MQTT communications lines.

    2024-12-20 11:31:38 Receive biocorneche/vdbt/pla/gbtes/24e124445d183109/up = {“adc_1″:4,”adc_2”:0…
    Subscribed devices: 3
    Hello from JS. Topic: biocorneche/vdbt/pla/gbtes/24e124445d183109/up
    Error: The input string ’24e124445d183109′ was not in a correct format.

    How can I fix or ignore those strings?
    Thanks.

    #15830
    Mikhail
    Moderator

    Hi Rodrigo,
    Your question is about MQTT, not related the current topic of displaying strings.
    Please start a new topic to discuss the question. Provide screenshots of the MQTT configuration and logs.

Viewing 9 posts - 16 through 24 (of 24 total)
  • You must be logged in to reply to this topic.