I just got a RobotDyn ATMega 2560 with embedded ESP8266.
Just installed ESPEasy on the ESP8266 part and RFLink sw on the ATMega.
I would like to use it via TCP, but don’t understand how to expose the USB/Serial interface to TCP as detailed in the manual https://www.home-assistant.io/components/rflink/
I don’t know how to send command “socat” if this is necessary or if there is another way.
Thanks @phileep
So now it seems to work, I’ve loaded ESPEasy Build 20100 - Mega (core 2_3_0) on the ESP8266 side and latest version of RFLink firmware in the ATMega side of the board.
After initial configuration of ESPEasy (Wifi and other stuff), I’ve added into the Devices tab a “Communication - Serial Server” setting a TCP port and choosing RFLink as Event Processing".
Then in the configuration.yaml I just added:
Set the dipswitches of the Robotdyn to
a. 1: off, 2:off, 3:on, 4:on, 5:off, 6:off, 7:off, 8:off
b. This will enable sketch uploading for the ATmega2560
Connect the Robotdyn to the computer with an usb cable
Extract the RFLink zip, and open the ‘RFLinkLoader.exe’
Open the ‘RFLink.cpp.hex’ from the select firmware to load box
Select the right COM port on which the Robotdyn is connected or just press the ‘Scan Available Ports’ button
Press the ‘Upload/Program Firmware to device’ button to upload the firmware, be cautious, do not disconnect the device now.
When it is ready close the RFLinkLoader
ESP8266 part
Set the dipswitches of the Robotdyn to
a. 1: off, 2: off, 3: off, 4: off, 5: on, 6: on, 7: on, 8:off
b. This will enable sketch uploading for the ESP8266
Check if the Robotdyn is still connected to the computer with an usb cable
Extract the ESPMega zip file, and open ‘FlashESP8266.exe’
Select the right COM port (which should be the same as in the RFLink uploading part) and select the right Firmware (ESP_Easy_mega-20180809_normal_ESP8266_4096.bin)
Press ‘Flash’ to upload the file to the Robotdyn, be cautious, do not disconnect the device now.
When it is ready close the flashing tool
The ESP8266 will now emit a wifi signal, connect with it with the following password: ‘configesp’ (more information at h-ttps://www.letscontrolit.com/wiki/index.php/ESPEasy#Introduction)
After connection a screen opens in which you can let the ESP8266 connect to your WIFI, if succesfull its new IP address will be shown.
Go to this IP address in your browser and click on devices
Click on Edit of the first task and select ‘Communication - Serial Server’ from the dropdown list
Fill in the form as following:
a. Name: RFLINK
b. Enabled: checked
c. TCP Port: a number between 1000 and 9999
d. Baud Rate: 57600
e. Data bits: 8
f. Parity: No Parity
g. Stop bits: 1
h. Reset target after boot: - none –
i. RX receive timeout: 0
j. Event processing: RFLINK
Press Submit
Home Assistant
• Go to the configuration file and add:
rflink:
host: ipaddress of the ESP8266
port: TCP port you added in the devices tab of the ESP8266
• Restart Home Assistant
• More information at h-ttps://www.home-assistant.io/components/rflink/
Wiring
• Disconnect the Robotdyn from power.
• Wire as following:
o Transmitter
VCC to D14
DATA to D15
GND to GND
o Reciever
VCC to D16
DATA to D19
GND to GND
Finishing
Set the dipswitches of the Robotdyn to
a. 1: on, 2: on, 3: on, 4: on, 5: off, 6: off, 7: off, 8:off
b. This will enable communication between the ATmega2560 and the ESP8266
Is this still “the way to go”? I’ve spend all day, trying to get ESP Easy to work, as i wanted. However, after it’s connected to my wifi, i find it very unstable - so bad, what i can’t even connect to the web-interface, from time to time.
I tried the latest build, but also the one you mentioned - but with the same result.
I can reach the webinterface, if i’m lucky - but only for a few minutes or so. Hereafter, it’s becoming unavailable.
Yes, i couldn’t get it stable, and ended up, just switching to another solution. The device is still flashed with RFLink and ESPEasy. I’m unsure if it should been anything related to how i flashed the device or so.
I know this is two years later, but for anyone running into this like I did, the unstable wifi all went away after I swapped to an external antenna. You do need to remove an SMD to activate the antenna - just plugging one in doesn’t work.