@hek Hmm, what do you mean? That I build the Ethernet Gateway, and when I want to Serial fw, I compile it with SOFTSPI so I don't need to change pin locations?
Best posts made by codenea
Latest posts made by codenea
Combining Serial and MQTT/Ethernet Gateway
I'm about to make my first gateway and since I want the flexibility to switch controller, since I'm note sure if I want to run Indigo or OpenHAB, I thought of building a gateway that has the Ethernet module installed on the board. Then if I want to use it as a serial gateway for Indigo I can just re-flash the Arduino with the Serial Gateway firmware instead, and if I want to use MQTT or Ethernet - I'll just re-flash with those firmwares.
Now since the radio needs to be soldered differently on the Ethernet/MQTT gateway, is it sufficient to just change the pin locations in the Serial firmware? In other words I'll just change the following line:
MyGateway gw(DEFAULT_CE_PIN, DEFAULT_CS_PIN, INCLUSION_MODE_TIME, INCLUSION_MODE_PIN, 6, 5, 4);
MyGateway gw(5, 6, INCLUSION_MODE_TIME, INCLUSION_MODE_PIN);
Is that correct? I'm not sure what the 6, 5, 4 pins are for though?
Also: Is it possible to hook up the MQTT gateway into the router instead, and still let the controller interact with it?