At the moment I try to get a connection between this boards - because later I will send information from one board to another one.
I read this two tutorials before:
https://docs.micropython.org/en/latest/ ... k_tcp.html
https://docs.micropython.org/en/latest/ ... asics.html
I have load the example of the "Simple HTTP server" on the board#1.
After the import the server seems to be active - open with the browser (192.168.4.1:80) I can see a table with the ESP8266 Pins and the values.
This part works perfect.
But I can not make a HTTP GET request with the board#2.
Code: Select all
>>> import network
>>> sta_if = network.WLAN(network.STA_IF)
>>> sta_if.connect("MicroPython-627bt1","micropythoN") ###board#1
>>> sta_if.isconnected()
True
>>> import socket
>>> s = socket.socket()
>>> ai = socket.getaddrinfo("192.168.4.1",80)
>>> addr = ai[0][-1]
>>> s.connect(addr)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
OSError: [Errno 103] ECONNABORTED
>>>
the REPL of the board#1 told me:
Code: Select all
client connected from ("192.168.4.3", 53807)
client connected from ("192.168.4.3", 53808)
_________________________________________[/color]
what is the meaning of "ECONNABORTED"...?
Is it possible to get information from another board with this method in generally?
(My vision is, that board#1 should be something like a measuring station, and board#2 should be connected with an lcd or something else which should show the information of board#1)