• Sun 2017.02.19

    Attempting to connect to an ESP8266-12 using the browser. Always getting error "This site can’t be reached 192.168.1.71 refused to connect"

    Windows 10 Home ver 10.0.14393 Build 14393 laptop running Chrome ver 56.0.2924.87 Firefox ver 51.0.1 WebIDE ver 0.65.9 Espruino ver 1v89

    1v89 Copyright 2016 G.Williams
    

    Have modified the @MaBe example to add wrapper functions to quickly access status detail (see below)

    It appears I am able to connect at the transport layer, just can't gain access at the application layer

    I am able to determine the IP addr using gateway access 192.168.1.254 and locate the device detail beneath Home Network Devices (in this case I.P. is 192.168.1.71)

    I am able to ping the device from the command line

    I am able to connect through the WebIDE calling wrapper funtions in the left panel to display the status as a station i.e. wifi.getAPIP(), wifi.getAPDetails(), wifi.getIP(), wifi.getStatus()

    wifi.getStatus()
    {
      "mode": "sta",
      "station": "connected",
      "ap": "disabled",
      "phy": "11n",
      "powersave": "none",
      "savedMode": "off"
     }
    wifi.getIP()
    {
      "ip": "192.168.1.71",
      "netmask": "255.255.255.0",
      "gw": "192.168.1.254",
      "mac": "5c:cf:7f:88:f4:a0"
     }
    wifi.getAPIP()
    {
      "ip": "0.0.0.0",
      "netmask": "0.0.0.0",
      "gw": "0.0.0.0",
      "mac": "5e:cf:7f:88:f4:a0"
     }
    wifi.getAPDetails()
    {
      "status": "disabled",
      "authMode": "open",
      "hidden": false, "maxConn": 4,
      "ssid": "2WIRE113",
      "password": "",
      "savedSsid": null
     }
    =undefined
    

    Confirmed through network settings not using a proxy server

    Viewed LMHOSTS file to make sure no garbage had been deposited there

    Fiddler also confirms the issued request and captures the resultant error

    [Fiddler] The connection to '192.168.1.71' failed. 
    Error: ConnectionRefused (0x274d). 
    System.Net.Sockets.SocketException No connection could be made because the target machine actively refused it 192.168.1.71:80
    

    Have even attempted adding this snippet in the left panel of the WebIDE

    http.createServer(pageHandler).listen(80­80);
    

    and typing 192.168.1.71 or 192.168.1.71:8080 in the browser address bar

    [Fiddler] The connection to '192.168.1.71' failed. 
    Error: TimedOut (0x274c). 
    System.Net.Sockets.SocketException A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond 192.168.1.71:80
    

    Any ideas, code snippets, would be appreciated. Thank you Robin

    Edit Sun 2017.02.19

    Even in AP mode a request to 192.168.4.1 results in:

    [Fiddler] The connection to '192.168.4.1' failed. 
    Error: TimedOut (0x274c). 
    System.Net.Sockets.SocketException A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond 192.168.4.1:80
    
About

Avatar for Robin @Robin started