Hello, i'm new with this node-red things and need some guidance regarding my problem.
I'm using google VM as my server with mosquitto and esp32 as publisher and subscriber.
right now, i start using 2 esp32 to communicate with publish and subscribe things.
the first one esp32 i'm using it for publisher and the others for subscribe.
I have seen a repeated messages debug is coming all the time even i'm not powering the esp32 publisher.
Is it normal or i have done something wrong?
when i check to my subscriber esp, those data always coming even i don't power up my publisher esp32
Assuming the subscribe nodes and publish nodes are all connected to the same broker, it looks like you have created an MQTT loop.
You should never publish to the topic you are subscribed to. The message just goes round and round your network, usually ending up in crashing node-red.
If you subscribe to hello you need to publish to hello
If you publish to esp1/temperature you should subscribe to esp1/temperature
You dont even need node-red in this at all. The ESPs will simply talk to the broker as 2 clients.
You can do something like this...
ESP2 → ESP1
ESP1 - subscribe to esp2/send/esp1
ESP2 - publish to esp2/send/esp1
ESP1 → ESP2
ESP2 - subscribe to esp1/send/esp2
ESP1 - publish to esp1/send/esp2
Use whatever topics you like but they should make sense and should be unique.
Without meaning to be cheeky, I think you should spend an hour reading up on MQTT - there are tonnes of videos on youtube and lots of info around the web. Get familiar with the basics before you continue.