Finding mqtt topic

So now we’re dealing with PIG/relay/0?

I ask again, where did this new topic come from? What has changed (that you haven’t told us about)?

We really need a screen capture of the output of MQTT Explorer when subscribed to all topics as I said above. I think that might be the only way to sort any of this out.

We need to see what the results are of:

Operating the switch from the manufacturer/device web console
Operating the switch from the HA front end toggle switch
Operating the switch from the HA MQTT service.

In order to try and get some wher forward I renamed relay as PIG , so nothing has changed apart from the name of the relay.
The hostname of the relay was changed and the command_state changed in line with this.
the documentation showed the manufacturer used “LED”, but that wouldn’t work with the hostname as IOT4SH01RELAY_D431D.
I’ve tried LED , but no change I’ve used PIG for obvious reasons and also the writer of the software just happens to use Littlepig as a password, and I’ve tried littlepig as well.

I cant run MQTT Explorer as it windows s/w , I’m searching for a native linux similar beast.

I have posted the mosquitto log of all those events Finity, I have mosquitto set to log everything.
definitely something in the middle
here’s an excert from the mosquitto log showing an incoming packet from the temperature sensor, it goes to mosqsub|2122-odroid as well as HA

1554325633: Received PUBLISH from esp8266a03625 (d0, q0, r1, m0, '/iot4/IOT4SH01DS_A03625/temperature', ... (4 bytes))
1554325633: Sending PUBLISH to mosqsub|2122-odroid (d0, q0, r0, m0, '/iot4/IOT4SH01DS_A03625/temperature', ... (4 bytes))
1554325633: Sending PUBLISH to home-assistant (d0, q0, r0, m0, '/iot4/IOT4SH01DS_A03625/temperature', ... (4 bytes))

If you know of a linux mqtt debug tool , it will save a lot of searching for one
Richard

I don’t know what MQTT Explorer you’ve been looking at but the one we mean is this one and it most definitely is available for Linux (and Windows):

It is not Windows only.

MQTT Explorer, MQTTLens (Chrome extension), MQTT.FX

… and everything we’ve established as baseline information over the course of the last 40+ posts.

So, did changing the relay’s name fix anything?

My guess is, no.

OK I was relying on the listing for it, that said windows, but I downloaded MQTTFX

and changing the name did absolutly nothing, but Sods law predicts if you dont try something , it what you didn’t try, or something like thast

Irony alert.

Let’s get back to solving the problem systematically as opposed to randomly throwing things at the wall and seeing what sticks.

Follow Finity’s suggestion to connect MQTT Explorer to the broker and observe all the topics it is currently handling. Turn the relay on/off and observe the payloads published to the topics.

You can use MQTT Explorer to publish 1 to PIG/relay/0 and if that fails to activate the relay then it is simply not subscribed (listening) to that topic.

Yes but the mosquitto logs are messy. The output of the sniffer tool will show exactly which topics/payloads are traveling around your MQTT network without all of the other fluff.

OK I’ve got MQTTFX running , never used it before, but I listed all the topics
interestingly there is this one

/iot4/IOT4SH01RELAY_D34IDE/relay/set

I haven’t seen that before.
So I’ll go back and set all the relay names back to the original state.
and clear the lists down and see what MQTTFX displays
when its in its old state.
and I may get some answers from Robi in Budapest over night , which may help.
( he wrote the sloppy s/w)

so a few hours delay
Richard

Before reprogramming the relay’s name again, publish 1 to PIG/relay/set and see if it activates the relay.

I’ve just changed most of it back ,
but I’ll do that with the original name

Actually you only listed one.

We are going to need to see them all.

sorry getting confused with topics
bear with me, I’m trying to get my head around MQTTFX,
I;ve downloaded MQTT explorer from github, but I’m not familiar with what looks like json
so really haven’t a clue , yet, what to do with it.
Not sure if I have to compile or what at the moment

Seeing that you’re having trouble getting one or more MQTT clients operational, for now just use Home Assistant’s MQTT page to publish 1 to /iot4/IOT4SH01RELAY_D34IDE/relay/set

that suffix has dissapeared off the list
publishing 1 to the relay shows 1 has been sent om MQTTFX
the same from the overview page switch

Dont you just love software that has a help pulldown, that only says check for updates.
what on earth is a switch fountain .
I think time to escape to bed

no, seriously… you really do need to post a screen shot of all the stuff i said that we need in my post above.

telling us isn’t enough. We need to see it for ourselves.

Almost completely irrelevant. Disconnecting/reconnecting with an MQTT client will only show topics that receive payloads while you’re connected (the exception is if the payloads were originally published with the retain option).

publishing 1 to the relay shows 1 has been sent om MQTTFX

Which topic did you publish 1 to? The one I had specified? What did the relay do?

Do you see how abbreviated responses aren’t helping the people who are trying to help you?

Dont you just love software that has a help pulldown, that only says check for updates.

What I’d love is a detailed response to what happens when you publish 1 to /iot4/IOT4SH01RELAY_D34IDE/relay/set

MQTT Explorer will be much easier to master than MQTTfx

1 Like

I have got MQTT-Exporer running
there is a little gotcha , another application I have on the laptop thinks its a .img and thinks it wants installing on a SD card.
But I’ve shut that app down
I also have MQTT-FX installed
Mosquitto 1.4.15 has been nuked and Mosquitto 1.5.8 downloaded, built and installed.
I need to get the logging enabled to everything
I have run tcpdump on the interface that HA and mqtt are on and toggle the relay locally
at the end of the sequnce I also published from HA to the relay
ALL the mqtt packets from the relay are recieved and ack’d
NOT one of the packets published from HA were sent to the relay
I have just published from MQQT-Explorer a string of "1"s to the relay
the tcp dump shows nothing sent
the relay is sending ping requests to the mqtt server and it responding
but it does not seem to be pinging in the other direction
I’m uploading screenshots , or attempting to


Richard