Git Product home page Git Product logo

espudptrigger's Introduction

EspUdpTrigger

UDP trigger for ESP8266 / ESP-WROOM-02.

Dependency

  • Arduino core for ESP8266 WiFi chip

https://github.com/esp8266/arduino-esp8266fs-plugin

  • Arduino ESP8266 filesystem uploader

https://github.com/esp8266/Arduino

Usage

  1. Download to your sketch folder for Arduino.
  2. Open the EspUdpTrigger.ino.
  3. Upload sketch data directory using arduino-esp8266fs-plugin.
  4. Upload the sketch file via serial from UART mode.
  5. Switch to the Flash mode.
  6. Reboot the ESP.
  7. Join the ESP AP.(SSID="esp", PASSWORD="12345678")
  8. Access to http://192.168.4.1/
    ( If you have "stack" error, please try access to http://192.168.4.1/init first for initialization the EEPROM. )
  9. Set to the [Device Name] and [SSID], [PASS] for your Wi-Fi router.
  10. Access to http://<Device Name>.local/ or IP Address after Reboot.

If SSID or password can not be found, AP mode. When it is found, it starts up in STA mode.

API

No URL Name
1 http://<Device Name>.local/ Root Menu. This page.
2 http://<Device Name>.local/pin Set GPIO pin value.
ex) http://Controller_01.local/pin?no=5&value=255
3 http://<Device Name>.local/config Set device name, SSID, PASS.
ex) http://Controller_01.local/config?name=servo&ssid=wifi_router&pass=12345678&triggers_0_pin=12&triggers_0_ip=192.168.0.100&triggers_0_port=20000
4 http://<Device Name>.local/init Restore the default settings.

UDP Trigger

UDP Message Example:

Controller_01/12/1;
[Device Name]/[Pin Number]/[Flag];

Screenshot

Screenshot01 Screenshot02 Screenshot03 Screenshot04 Screenshot04

Author

Teruaki Tsubokura http://teruaki-tsubokura.com/

@kohack_v

License

MIT

espudptrigger's People

Contributors

tsubokulab avatar

Stargazers

ToyoshiMorioka avatar yuichi miyagi avatar Masafumi Okada avatar

Watchers

James Cloos avatar  avatar YAMAZAKI, *Haruki avatar Rudy avatar  avatar

espudptrigger's Issues

Crashes when I try to access 192.168.4.1

I am trying to set it up but it crashes when I connect. The following is what I get from the serial port.
--------[ EEPROM ]--------
deviceName : š™™™™™¹?
ssid :
pass :
triggers[ 0 ] : / :
triggers[ 1 ] : 80029 / :
triggers[ 2 ] : / :ÿÿÿÿÿÿÿÿÿÿÿESP8266
triggers[ 3 ] : ÿÿÿESP8266 / P8266:2345678
triggers[ 4 ] : ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ���2�4qwerty / ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ���2�4qwerty:ÿÿÿ���2�4qwerty
triggers[ 5 ] : 4qwerty / ty:ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ|Tÿ?Ï�
triggers[ 6 ] : ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ|Tÿ?Ï� / ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ|Tÿ?Ï�:ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ|Tÿ?Ï�
triggers[ 7 ] : ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ|Tÿ?Ï� / ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ|Tÿ?Ï�:ÿÿÿÿÿÿÿÿ|Tÿ?Ï�

[ Setup Client Mode ]
SSID :
PASS :
Connecting to Access Point
......................
[ Setup Server Mode ]
SSID: esp
PASS: 12345678
HTTP server started.
http://192.168.4.1/
MDNS responder started
http://š™™™™™¹?.local/

show index.html
File Size OK:9459

Exception (28):
epc1=0x40216070 epc2=0x00000000 epc3=0x00000000 excvaddr=0x00000000 depc=0x00000000

ctx: cont
sp: 3fff3af0 end: 3fff4030 offset: 01a0

stack>>>
3fff3c90: 00000005 3fff3e9d 3fff3ebc 4020e08d

And the following is the decoded stack trace information. Not that it helps me as I don't know what to do with it.

Exception 28: LoadProhibited: A load referenced a page mapped with an attribute that does not permit loads
Decoding 26 results
0x40216070: strstr at /Users/igrokhotkov/e/newlib-xtensa/xtensa-lx106-elf/newlib/libc/string/../../../.././newlib/libc/string/strstr.c line 55
0x4020e08d: String::operator=(char const*) at C:\Program Files (x86)\Arduino\hardware\esp8266com\esp8266\cores\esp8266/WString.cpp line 519
0x4020e0ca: String::String(unsigned char, unsigned char) at C:\Program Files (x86)\Arduino\hardware\esp8266com\esp8266\cores\esp8266/WString.cpp line 519
0x40207aae: showIndex() at C:\Users\Rudy\Documents\Arduino\esp8266\udp\EspUdpTrigger/EspUdpTrigger.ino line 238
0x4010053d: _umm_realloc at C:\Program Files (x86)\Arduino\hardware\esp8266com\esp8266\cores\esp8266\umm_malloc/umm_malloc.c line 1491
: (inlined by) realloc at C:\Program Files (x86)\Arduino\hardware\esp8266com\esp8266\cores\esp8266\umm_malloc/umm_malloc.c line 1709
0x4020de9b: String::changeBuffer(unsigned int) at C:\Program Files (x86)\Arduino\hardware\esp8266com\esp8266\cores\esp8266/WString.cpp line 519
0x4020dee7: String::reserve(unsigned int) at C:\Program Files (x86)\Arduino\hardware\esp8266com\esp8266\cores\esp8266/WString.cpp line 519
0x4020ab38: FunctionRequestHandler::handle(ESP8266WebServer&, HTTPMethod, String) at C:\Program Files (x86)\Arduino\hardware\esp8266com\esp8266\libraries\ESP8266WebServer\src\detail/RequestHandlersImpl.h line 56
0x4020f7ce: std::_Function_handler ::_M_invoke(std::_Any_data const&) at c:\program files (x86)\arduino\hardware\esp8266com\esp8266\tools\xtensa-lx106-elf\xtensa-lx106-elf\include\c++\4.8.2/functional line 2073
0x4020ab2e: std::function ::operator()() const at C:\Program Files (x86)\Arduino\hardware\esp8266com\esp8266\libraries\ESP8266WebServer\src\detail/RequestHandlersImpl.h line 56
0x4020ab6a: FunctionRequestHandler::handle(ESP8266WebServer&, HTTPMethod, String) at C:\Program Files (x86)\Arduino\hardware\esp8266com\esp8266\libraries\ESP8266WebServer\src\detail/RequestHandlersImpl.h line 56
0x4020e048: String::String(String const&) at C:\Program Files (x86)\Arduino\hardware\esp8266com\esp8266\cores\esp8266/WString.cpp line 519
0x4020abfd: ESP8266WebServer::_handleRequest() at C:\Program Files (x86)\Arduino\hardware\esp8266com\esp8266\libraries\ESP8266WebServer\src\detail/RequestHandlersImpl.h line 56
0x40209390: WiFiClient::~WiFiClient() at C:\Program Files (x86)\Arduino\hardware\esp8266com\esp8266\libraries\ESP8266WiFi\src/WiFiClient.cpp line 151
0x401048a2: wdt_feed at ?? line ?
0x40104b30: ets_timer_arm_new at ?? line ?
0x4020adec: ESP8266WebServer::handleClient() at C:\Program Files (x86)\Arduino\hardware\esp8266com\esp8266\libraries\ESP8266WebServer\src\detail/RequestHandlersImpl.h line 56
0x4020e8b0: esp_yield at C:\Program Files (x86)\Arduino\hardware\esp8266com\esp8266\cores\esp8266/core_esp8266_main.cpp line 57
0x40201382: delay at C:\Program Files (x86)\Arduino\hardware\esp8266com\esp8266\cores\esp8266/core_esp8266_wiring.c line 54
0x40201377: delay at C:\Program Files (x86)\Arduino\hardware\esp8266com\esp8266\cores\esp8266/core_esp8266_wiring.c line 51
0x40208353: loop at C:\Users\Rudy\Documents\Arduino\esp8266\udp\EspUdpTrigger/EspUdpTrigger.ino line 414
0x4020e8fc: loop_wrapper at C:\Program Files (x86)\Arduino\hardware\esp8266com\esp8266\cores\esp8266/core_esp8266_main.cpp line 57
0x4010070c: cont_norm at C:\Program Files (x86)\Arduino\hardware\esp8266com\esp8266\cores\esp8266/cont.S line 109

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.