ESP Easy not receiving MQTT messages (but can send)

Hi!

So I set up ESP easy together with PN532 to read NFC tags and then open doors with it.

Opening the dore works perfectly when triggering on a MQTT state but I can’t send any messages / commands from HA to ESP Easy.

This is the configuration of ESP easy:


And that’s how I try it in HA:

HA config:
mqtt:
broker: core-mosquitto
username: XXXX
password: XXXXX

Does anyone know what’s wrong with this?

Thanks!

I think you might be having trouble with the leading /
I use mqttfx to monitor my mqtt transactions to see what I am sending & receiving.

Thanks for your input!

Well the trailing slash seamed to be a problem as only after I deleted it, MQTT lens was able to see the messages:
Capture_3

But still: The value doesn’t change on ESP Easy

any reason your ESP config isn’t using a username?

Your post shows ESP subscribing to home/doorlock without leading slash
HA is publishing /home/doorlock with leading slash

@forsquirel: it’s just deleted for the screenshot
@cyn: yeah, I changed that (see screen from my second post)

OK I got confused by your response when you said trailing, but I think we are in sync now. On my esp devices I use rules to do an action when the ESP device receives a command. Hope this helps

HA publishes: ESP/cmd event,retrieveStatus
in rules I have
On retrieveStatus do
Publish sendOut/UTIL/Unit22/Status,{ “temp”: [DS18B20#Temperature] }
endon

Setup Rules by going to Tools, Advance, & check Rules

Hi @smi

How did you setup your pn532 with esp8266? I have got my pn532 from China but cannot find the correct arduino code and libraries to download and test.

Can you please guide me ?

Thanks.

your topics are not the same in both the screenshots.
“/home/…” =/= “home/…”

EDIT: Sorry, I see you’ve already adjusted for this mistake.