Announcement

Collapse
No announcement yet.

Problem with Special Characters

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Problem with Special Characters

    Hi,
    There is a problem with special characters when sending topics that is added to MQTT list

    Example, if i add to MQTT Device a topic called verisure/doorLock/Ytterdør47/set , it becomes verisure/doorLock/Ytterd%C3%B8r47/set
    But if i add same Topic to an Event, it stays like this verisure/doorLock/Ytterdør47/set and send the correct message.

    Is there some UTF8-without BOM problem or something?
    Here you can see that message sent from Event are recieved back nice, but not Topic sent from MQTT device list.
    Click image for larger version

Name:	2019-04-24_1809.png
Views:	3
Size:	196.0 KB
ID:	1300981

  • #2
    So I understand...
    You have a lock that publishes the message shown on row 4. You entered the topic that contains the special characters so that when device 767 changes it delivers the set message to the lock.
    When mcsMQTT does publish the message it encodes the special character so the MQTT broker sends back what is seen in row 0.
    If you use the MQTT event action action to send the message then mcsMQTT does not encode the special character so the MQTT broker sends back row 2 topic.

    What do you believe should happen? I believe there is an option on General tab to not encode the published topics. There are now no provisions to decode a subscribed topic.

    Comment


    • #3
      Yes, if i send a topic from device 767 it gets encoded instead of sending it like i have written it, which also means that i Get wrong message to the endpoint in node red. (Row one is just to see what I receive back)
      But if I create an event MQTT message and send the same topic, then it is sent like it was written, as you can see in Row three.
      So something is converting letter ø -> %C3%B8 when it is sent from device, but it is ok when sent from event.

      Comment


      • #4
        On the General tab "URI Encode Topic" will allow you to not have it encoded.

        Comment


        • #5
          Aha, great, thank you

          Comment

          Working...
          X