MQTT-Gateway - some questions
-
Hi,
Being new to mysensores, I´m trying to build a MQTT-Gateway for OpenHAB using an arduino nano clone and a W5100 ethernet shield.
I followed the instructions to connect the shield and the nano using dupont wires.
The instructions for ethernet gateways tell me to use soft-SPI due to the W5100, which has to be done in myconfig.h via "#define SOFTSPI".Building a MQTT-Gateway, I am using the sketch for MQTT on mysensors.org. I don´t know if I have to #define SOFTSPI in myconfig.h, too, like using a ethernet gateway without MQTT.
One more question, please:
My router uses DHCP. That´s why I can´t setup static IPs. But, I have the possibility to add devices using the mac adress by myself. The sketch containing "byte TCP_MAC[] = { 0x06, 0xDE, 0xAD, 0x00, 0x00, 0x42" means, I have to add the MAC adress 06-DE-AD-00-00-42 to the specific IP ? Is this correct ?Thanks a lot.
-
@blebbens It's been a while. But if I remeber it correctly you have to set #define SOFTSPI in MyConfig.h too. Don't forget to comment it back when you're compiling a sketch for a node.
My router uses DHCP as well. But I can assign a static IP in the sketch. Shouldn't be a problem.
I'm not sure, but I think the arduino can't handle DHCP, it's a really simple ethernet card. So you need to assign an IP in the sketch.