Gateway question
-
Not quite.
The device that converts between one protocol (rs485, nrf, rfm) and another protocol (serial, wifi, wired ethernet) is called a gateway in MySensors vocabulary.
So the esp would be a gateway. The esp talks wifi to the controller and rs485 to the Arduinos.
-
The naming in the MySensors examples can be a bit confusing though.
GatewaySerialRS485 uses rs485 to talk to sensors and (rs232) serial to talk to the controller
GatewayESP8266 Uses nrf or rfm to talk to sensors and wireless ethernet to talk to the controller
GatewayW5100 Uses nrf or rfm to talk to sensors and wired ethernet to talk to the controller -
The naming in the MySensors examples can be a bit confusing though.
GatewaySerialRS485 uses rs485 to talk to sensors and (rs232) serial to talk to the controller
GatewayESP8266 Uses nrf or rfm to talk to sensors and wireless ethernet to talk to the controller
GatewayW5100 Uses nrf or rfm to talk to sensors and wired ethernet to talk to the controller -
Not quite.
The device that converts between one protocol (rs485, nrf, rfm) and another protocol (serial, wifi, wired ethernet) is called a gateway in MySensors vocabulary.
So the esp would be a gateway. The esp talks wifi to the controller and rs485 to the Arduinos.
@mfalkvidd
So there isn't really any combination that would work for me?I would need a ESP8266Gateway that would talk RS485 to my Arduino with all the sensors?
-
@mfalkvidd
So there isn't really any combination that would work for me?I would need a ESP8266Gateway that would talk RS485 to my Arduino with all the sensors?
@raptorjr no here is no example. It might be really easy to make one though. There is very little difference between the sketches. This might be all that's needed to create a rs485 to wifi:
Enable RS485 transport layer #define MY_RS485 // Define this to enables DE-pin management on defined pin #define MY_RS485_DE_PIN 2 // Set RS485 baud rate to use #define MY_RS485_BAUD_RATE 9600 #define MY_GATEWAY_ESP8266 #define MY_ESP8266_SSID "MySSID" #define MY_ESP8266_PASSWORD "MyVerySecretPassword" -
You might want to join forces with @hausinger who wanted to build the same thing just a few days ago at the end of this thread: https://forum.mysensors.org/topic/1947/rs485-rs232-serial-transport-class-for-mysensors-org/94
https://forum.mysensors.org/topic/3451/serial-gateway-with-several-sensors-connected-to-it/10 explains the main difference between rs232 and rs485
-
for side note, I just would like to confirm that esp8266(nodemcu in my case) mqtt client gw works ok with rfm69 ;) with a nice rgb led using indication api :) but I use serial gw as regular.
I'm not using rs485 sorry :disappointed: unfortunately there are some work I think to make what you want working (and that would need software serial stuff, not the greatest thing imho but that's useful sometimes..)
A bit too bad that you need to use wifi with rs485..but I guess you have your reason ;) I just mean with rs485 you can have long wire so you could reach a simple rs485 gw connected to controller, but maybe you can't reach your controller with wire? -
Well, it is not so much about having to use a wire although I think that when possible things should be wireless. It is more about that I don't have a NRF card but only a ESP card and I would like to get something working since it takes a few weeks to get the NRF cards.
Arduino+NRF can be used as a node, Arduino+ESP can't. Wasn't even thinking that no one had done that before and that there wasn't any support for it. The only difference in my mind is that the ESP have to be configured to connect to a wireless network first. After that there shouldn't have to be any difference with the communication. But maybe the example above could work?
But as I said, I have no experience about this and just got my first Arduino a few days ago, so I have no clue about these things.
-
for side note, I just would like to confirm that esp8266(nodemcu in my case) mqtt client gw works ok with rfm69 ;) with a nice rgb led using indication api :) but I use serial gw as regular.
I'm not using rs485 sorry :disappointed: unfortunately there are some work I think to make what you want working (and that would need software serial stuff, not the greatest thing imho but that's useful sometimes..)
A bit too bad that you need to use wifi with rs485..but I guess you have your reason ;) I just mean with rs485 you can have long wire so you could reach a simple rs485 gw connected to controller, but maybe you can't reach your controller with wire?