Doubt about a concept in GatewayESP8266



  • Hello everyone!
    I have a doubt here. I has uploaded GatewayESP8266 sketch to my NodeMCU. Ok, it's getting IP and NRF is working fine. Second step was add a hardware in Domoticz controller, running on my Linux desktop. I can see my NodeMCU receiving ping. So, I uncommented this in sketch:
    #define MY_CONTROLLER_IP_ADDRESS 192,168,1,7
    Above, you see the IP of machine which Domoticz is running. Then, I tried upload the sketch again, but I got a error related to this macro:

    In file included from /home/djames/.arduino15/packages/esp8266/hardware/esp8266/2.3.0/libraries/ESP8266WiFi/src/ESP8266WiFi.h:39:0,
    from /home/djames/Arduino/GatewayESP8266/GatewayESP8266.ino:132:
    (a lot of directories).../WiFiClient.h:123:36: error: request for member 'available' in 'source', which is of non-class type 'char
    '
    size_t left = source.available();
    *

    I know that it's related to IP declaration, but I have no idea how to fix it. So, my main doubt is if I need to change any other parameter in this sketch to fix it. And, after that, does Domoticz will receive data from my ESP gateway, right?

    Sorry my terrible english and I hope you can understand me.


  • Mod

    @Djames-Suhanko thanks for reporting this problem. I get the same result. I have created https://github.com/mysensors/MySensors/issues/918 to figure out why.

    However, to my knowledge Domtoticz does not support being a gateway server, so I don't think you should use MY_CONTROLLER_IP_ADDRESS.



  • Hello, @mfalkvidd ! Thanks to answer.
    I'm a Linux user. Could you recommend me another controler which supports my gateway server?


  • Mod

    That define is not necessary to be used with domoticz.


  • Mod

    @Djames-Suhanko is there a reason you can't use the gateway in normal mode?



  • Shouldn't that be 192.168.1.7, not 192,168,1,7?


  • Mod



  • @wallyllama Yes, I did a mistake when I wrote that.



  • @mfalkvidd I confess you I have a lot of doubts about the data colection. My scenary is Arduinos sending data from sensors. I just need colect this data to insert in a database. Could you suggest some documentation or tutorial related to?


  • Mod

    @Djames-Suhanko perhaps the MySensors getting started guide? https://www.mysensors.org/about



  • I have been using Domoticz with MySensors nodes in several different configurations.

    The closest I have done to what you are asking is to use the GatewayESP8266MQTTClient version, with one or more sensors connected directly to the ESP8266 running the above client software, so there is no separate Arduino. This is of course wifi only transport from the sensor node via the LAN to Domoticz controller, and it requires a MQTT broker (server).

    Similarly I also use Domoticz with ESP8266 running ESPEasy which also transports by wifi, no Arduino. I strongly recommend this combination to get started as the only hardware is a ESP8266 like NodeMCU, Wemos Mini, etc. and your controller host (Linux computer or RPi), and the only software is Domoticz and ESPEasy, both of which require configuration but no customizing code. Of course you can as many sensor nodes as you like.

    From reading on this site I got the impression that the ESP8266 is NOT an ideal choice for a general purpose MySensors gateway-to-LAN solution using radio-equipped Arduino sensor nodes, and the W5100 Ethernet Gateway is far better. But I am not using this myself.

    Finally I also use MySensors with Arduino and attached radio link to a radio-equipped gateway on a RaspBerry Pi. This is a more complicated solution as you are now dealing with two radios, and both sensor node and gateway software you must configure/customize. It works well, however, and there is the opportunity to wire custom code at the sensor node if you require this.

    If you do not have an existing working Domoticz or Mysensors installation, and you simply need data from common sensors, I strongly recommend trying Domoticz + ESPEasy. It is MUCH easier to set up and get running with supported software, as you simply install it on the ESP and configure via a webpage. It is a great help to learn Domoticz without too much complication.

    Domoticz is a pretty easy package to get working compared to the others I looked at.



  • Hello,

    i send a command at git, can any one test this fix?

    regards
    ThomasD



  • @Grubstake Hello! I thank you to this tip.
    I already have a broker MQTT to many other tasks and I'm trying to collect data to automatically decisions. I would like to have the data so simple as possible and I thinking that MQTT would be like a bridge to my own interaction. I can see already data incoming in my MQTT broker, but it's no so clear as I want. In true, the only thing that i want is the mesh network and data sending as a string json or something like that - for this reason I choose MQTT, but MySensors has a protocol behind and nor MQTT messages are clear to me.
    I will think a bit more about what I can do, but if you have some suggestion to only use mesh without other layers, please, let me know.


Log in to reply
 

Suggested Topics

  • 3
  • 10
  • 4
  • 2
  • 3
  • 2

0
Online

11.2k
Users

11.1k
Topics

112.5k
Posts