├── Makefile ├── README.md ├── app ├── .output │ └── eagle │ │ └── debug │ │ └── image │ │ └── eagle.app.v6.out ├── Makefile ├── driver │ ├── .output │ │ └── eagle │ │ │ └── debug │ │ │ ├── lib │ │ │ └── libdriver.a │ │ │ └── obj │ │ │ ├── gpio16.d │ │ │ ├── gpio16.o │ │ │ ├── i2c_master.d │ │ │ ├── i2c_master.o │ │ │ ├── key.d │ │ │ ├── key.o │ │ │ ├── pwm.d │ │ │ ├── pwm.o │ │ │ ├── sensor_lp.d │ │ │ ├── sensor_lp.o │ │ │ ├── spi.d │ │ │ ├── spi.o │ │ │ ├── uart.d │ │ │ └── uart.o │ ├── Makefile │ ├── gpio16.c │ ├── i2c_master.c │ ├── key.c │ ├── pwm.c │ ├── sensor_lp.c │ ├── spi.c │ └── uart.c ├── gen_misc.bat ├── gen_misc.sh ├── include │ ├── driver │ │ ├── gpio16.h │ │ ├── i2c_master.h │ │ ├── key.h │ │ ├── pwm.h │ │ ├── sensor_lp.h │ │ ├── spi.h │ │ ├── spi_register.h │ │ ├── uart.h │ │ └── uart_register.h │ ├── ssl │ │ ├── cert.h │ │ └── private_key.h │ ├── user_config.h │ ├── user_devicefind.h │ ├── user_esp_platform.h │ ├── user_esp_platform_timer.h │ ├── user_iot_version.h │ ├── user_json.h │ ├── user_light.h │ ├── user_plug.h │ ├── user_sensor.h │ └── user_webserver.h └── user │ ├── .output │ └── eagle │ │ └── debug │ │ ├── lib │ │ └── libuser.a │ │ └── obj │ │ ├── user_devicefind.d │ │ ├── user_devicefind.o │ │ ├── user_esp_platform.d │ │ ├── user_esp_platform.o │ │ ├── user_esp_platform_timer.d │ │ ├── user_esp_platform_timer.o │ │ ├── user_json.d │ │ ├── user_json.o │ │ ├── user_light.d │ │ ├── user_light.o │ │ ├── user_main.d │ │ ├── user_main.o │ │ ├── user_plug.d │ │ ├── user_plug.o │ │ ├── user_sensor.d │ │ ├── user_sensor.o │ │ ├── user_webserver.d │ │ └── user_webserver.o │ ├── Makefile │ ├── user_devicefind.c │ ├── user_esp_platform.c │ ├── user_esp_platform_timer.c │ ├── user_json.c │ ├── user_main.c │ ├── user_sensor.c │ └── user_webserver.c ├── bin ├── blank.bin ├── boot_v1.1.bin ├── boot_v1.2.bin ├── devicekeys_ULP_sensor │ ├── 1312fe7b287025955266ba5642164d8e34c58825.bin │ ├── 19d81ed280cfe426afbe22d8849277364c5fb652.bin │ ├── 1a674b0abf5da778c74e07e66e88e89787724dfc.bin │ ├── 1d8c1d2efaac55f427c575029d5c3dc37162c6c0.bin │ ├── 1e6223eda2891355611fe69153a296910d69bfe1.bin │ ├── 2c4fd723c2f16f5f0a0ccdee42bfc051af32f198.bin │ ├── 2e0ecd31473113d7b927db1c159e634004c18d9c.bin │ ├── 2e3eb8d817e448a6e0562538d96f0fe3b7491523.bin │ ├── 30a72d0e002420d71adce5eeecea99dbbe89f6d9.bin │ ├── 3150be56bb829794243c8d3c96810b3980f69a2b.bin │ ├── 355b424b5b04a54e5febcad8642f9087062f10e6.bin │ ├── 3739445d260abc7ceafcffeb498c86fadd778292.bin │ ├── 379bcbfc0e8def10d8bd57fd7c5cd79538ff367f.bin │ ├── 3b6e892cd723eaac4b9a3662feb9cb87645dc468.bin │ ├── 3ca045eedf039ccd04dd7ca90ff95fc8eac0a042.bin │ ├── 41dc1061b28c4675a7759444b866eb6578224c02.bin │ ├── 4321bd99bf2054db74531f0aac217c0f3352ac98.bin │ ├── 4640b8c31ced78d2f207c7a8f0dfe4d67d516e08.bin │ ├── 4cf8e02c2de23041c163a04fc86ec502884c4fb7.bin │ ├── 503864dae691f7ee1d430d75e4fcb154b0cc36c7.bin │ ├── 511416f189ca81b6643ccbab6fbfae0a959328aa.bin │ ├── 53c4098f9594a200e63841a189f6d4e93e0bcdcd.bin │ ├── 55b9358e85ac07cd909f608041575b7653b26ade.bin │ ├── 590aab2e9ff28cbe0c9f892d5eab5ae7ad9c1fd1.bin │ ├── 59f92d8cd90534985a7716388d61699c1e84fd11.bin │ ├── 5b522ef53c1b5773f3e9f3e48d0f91efd122d7b4.bin │ ├── 5cc010bc9ba7d6cc7c7d6638d5ad8284a56d2935.bin │ ├── 5e0b40b7b300192e829fe64e3f0f8953103209ad.bin │ ├── 611291ac0776e7a247000747a3894e6a90b1a195.bin │ ├── 68a45ac41ef3675eafc0fe2dae742c3273ce96fa.bin │ ├── 69c62bbf28d73f36eb7daf11eafa4aee01d05f7c.bin │ ├── 6bca1801e38dd3e18472e1f46b06487e2626924f.bin │ ├── 6d1a8612ad1828155b8e1502ce824920c92c316d.bin │ ├── 6dd15dfb944a858cc5f5a8379d0c21c7cb089d7c.bin │ ├── 6ea6964ca9a5004a1a9377022699bd11ffe1f5a7.bin │ ├── 70d75e4857873f6b940da6633a85e676cbe17c41.bin │ ├── 720e6ca904675a596ba312a73e469f03ebcf601a.bin │ ├── 72260589053fe1d6d0515840ff6f2a01d870ccbe.bin │ ├── 72791acb4a18362947a51743e991c5b1b33747c2.bin │ ├── 72847c1aafce98cd38b092268986fcfcd1a1b214.bin │ ├── 729023461ad9fb78df70b8e4cad8041b4f20aafe.bin │ ├── 748f1f3627e174f39d5560049a7d868a44f6d2a8.bin │ ├── 78597104387b72ca6fa55a99ae8e929a573d1de7.bin │ ├── 7aec77fc2f5ea6df2fa43687d21892dbd0f76f1e.bin │ ├── 7bc280151e08ad01df088605e0da5e6921db0f3b.bin │ ├── 7bf23a6b947c7c78e20385ed5b488c4e48de6e5a.bin │ ├── 7e3281674b5e0357e26c326339f3289fb8390938.bin │ ├── 7ef3d1657c4f7a87e842c85659e65923cef54b74.bin │ ├── 802a985ea3565252593981b46f8863ff6445f545.bin │ ├── 8158807b97609ed17cb2045cc58f05b82c14eff9.bin │ ├── 81dcf7eaedfd0e532fc2d268d6ef02cd8a96751e.bin │ ├── 850300c1cd6601bd5b58dbfb43c09d1898c3b122.bin │ ├── 8ac740272ae313ef700a587f9a2fe0cbdc1bf91d.bin │ ├── 8b8a5aa14d367efdd496c5f828b34159e57a7274.bin │ ├── 8c5090b11698b8b59d53e8f9dd77a822cb064d50.bin │ ├── 8cc9ca7a3bfe8f95ae35b5103dae81a2c55be913.bin │ ├── 8f78ffed9b81d044d66caca8cc8217f85ebb08aa.bin │ ├── 9065a1530500e46fc32011cb45c96aedc96f875f.bin │ ├── 9119e7322671ca416dd04bd792599bea62435a0f.bin │ ├── 92fcc03fceb0c015a5552722fe6ffc7eb6474916.bin │ ├── 94be6e380a6f6108347d2a271ba621b32dc359da.bin │ ├── 9884d87c487de6f2738f67776575a8f1e19e9428.bin │ ├── 993f41e99283dfe8159fe0ade55402ddbcaffc00.bin │ ├── 99f9b0b9c7a58ca38627c7819884bdf2cdc85b60.bin │ ├── 9a711512de3b3dd0a545de9cc7b3078a988983fb.bin │ ├── 9d7a138d6ac6bca768dbc5ed5a121ebabf18eed7.bin │ ├── 9e09b6e9af56780b01c3bf65a48e090fe4450a65.bin │ ├── 9efac19539d5dbea2b9fdebe14a0245f0a6470f6.bin │ ├── a04d3ba05ff1fc431dff0a1ac80c53e6f5527cd1.bin │ ├── a1d201f61615839136e30925c907d7d6691ffdf4.bin │ ├── a3005d343bc938997141bf38c33efa6bc9cad014.bin │ ├── a8cb4171813ed2099c3aa9a230c145efd333c759.bin │ ├── b03c9946c691da09f0ab710dad04247df53d014c.bin │ ├── b0aad3f5edbda92681ba248707b7a470b8645c93.bin │ ├── b2e85ad12e1b3ada64bee5966b290e81478829bb.bin │ ├── bbef8d57547e9607b58242a576e214cf0fcb63f6.bin │ ├── bc5215ebce7de8a96f3b9d2e8cae22ca4a05610f.bin │ ├── c17299ecc6a7e3bf6a1984d0c71f78aee89fa673.bin │ ├── c37ba3d2c494fcf82d0f37f616f2febeb0257f2c.bin │ ├── c63e137fae7ac2bfa04b785a33ce4b6d615856dc.bin │ ├── c6937b888053cf7798e26d3c9522e3d6f0b628e2.bin │ ├── c82cea3be5695b9b63165015813f1021810f5f09.bin │ ├── cd29d4071bf14cbee09f68e62dac9191acd91c25.bin │ ├── ce9c4ba672fe888beaf00fcdb753f068c64634e7.bin │ ├── d0f059bb651bc87680730539d19bbb5131f7cab7.bin │ ├── d4665eabfaa39f9d1b3bdcd00c35cc39cc42ebf5.bin │ ├── dcc3aba22f77141f3e390cca58e270c3b5f14b67.bin │ ├── devices_generate.txt │ ├── e2f353aad73aade9e3816f2789a1727664268573.bin │ ├── ef9d837492ad9b8781e8b14061895cea3fc02ea2.bin │ ├── f2dada5d39f0aad7f3073e8689abb141dc854d0b.bin │ ├── f38e3770958f99399f0340829880503973b77301.bin │ ├── f3ea80726e8e72b45c2d76fea236ce4b368afa13.bin │ ├── f62b940b69d713a1a743456bffe4937e59075560.bin │ ├── f72acba76e156ad425dc6b6fe030908dd223d36a.bin │ ├── fa98d6d8367de32e4977f4bc246835529d2aee8b.bin │ ├── ff34d55ac4c39070d88551e57929aef9a4865139.bin │ └── ff9ab573d9c48d60c8084759db323e79b93b2db5.bin ├── eagle.S ├── eagle.dump ├── eagle.flash.bin ├── eagle.flash_disable_rf.bin ├── eagle.irom0text.bin ├── esp_init_data_default.bin ├── esp_init_data_vdd33.bin ├── esp_init_data_vdd33.bin_40M ├── gen_key_bin.py ├── key.bin ├── low_power_sensor_default_bin │ ├── blank.bin │ ├── eagle.flash_disable_rf.bin │ ├── eagle.irom0text.bin │ ├── esp_init_data_vdd33.bin │ ├── esp_init_data_vdd33.bin_40M │ ├── readme.txt │ └── write_flash.sh ├── master_device_key.txt ├── upgrade │ ├── user1.512.old.S │ ├── user1.512.old.bin │ ├── user1.512.old.dump │ └── user1.512.old_disable_rf.bin └── write_flash.sh ├── include ├── at_custom.h ├── c_types.h ├── eagle_soc.h ├── espconn.h ├── ets_sys.h ├── gpio.h ├── ip_addr.h ├── json │ ├── json.h │ ├── jsonparse.h │ └── jsontree.h ├── mem.h ├── os_type.h ├── osapi.h ├── ping.h ├── queue.h ├── smartconfig.h ├── spi_flash.h ├── upgrade.h └── user_interface.h ├── ld ├── eagle.app.v6.ld ├── eagle.app.v6.new.1024.app1.ld ├── eagle.app.v6.new.1024.app2.ld ├── eagle.app.v6.new.512.app1.ld ├── eagle.app.v6.new.512.app2.ld ├── eagle.app.v6.old.1024.app1.ld ├── eagle.app.v6.old.1024.app2.ld ├── eagle.app.v6.old.512.app1.ld ├── eagle.app.v6.old.512.app2.ld └── eagle.rom.addr.v6.ld ├── lib ├── lib.rar ├── libat.a ├── libjson.a ├── liblwip.a ├── libmain.a ├── libmain.rar ├── libmain_lowpowermode.rar ├── libnet80211.a ├── libphy.a ├── libphy.rar ├── libpp.a ├── libsmartconfig.a ├── libssl.a ├── libupgrade.a └── libwpa.a ├── readme.txt ├── scripts ├── get_sensor_voltage.py ├── plot_sensor_voltage.py └── setup_AP_information.py └── tools ├── add_disable_rf_cmd.py ├── esptool.py └── gen_appbin.py /README.md: -------------------------------------------------------------------------------- 1 | # Low Power Voltage Measurement 2 | 3 | This is a project for ESP8266 for low power sensor applications. 4 | The chip powers on once every 1 minute to measure it's own power supply, 5 | and sends the data to the server, once every 20 minutes. Of course, you 6 | can configure the chip to do other things such as measuring temperature or 7 | humidity, etc. 8 | 9 | The project is now based on Espressif's SDK version 1.0.1b. More details 10 | about the project can be found in the Wiki. 11 | -------------------------------------------------------------------------------- /app/.output/eagle/debug/image/eagle.app.v6.out: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/app/.output/eagle/debug/image/eagle.app.v6.out -------------------------------------------------------------------------------- /app/Makefile: -------------------------------------------------------------------------------- 1 | ############################################################# 2 | # Required variables for each makefile 3 | # Discard this section from all parent makefiles 4 | # Expected variables (with automatic defaults): 5 | # CSRCS (all "C" files in the dir) 6 | # SUBDIRS (all subdirs with a Makefile) 7 | # GEN_LIBS - list of libs to be generated () 8 | # GEN_IMAGES - list of object file images to be generated () 9 | # GEN_BINS - list of binaries to be generated () 10 | # COMPONENTS_xxx - a list of libs/objs in the form 11 | # subdir/lib to be extracted and rolled up into 12 | # a generated lib/image xxx.a () 13 | # 14 | TARGET = eagle 15 | #FLAVOR = release 16 | FLAVOR = debug 17 | 18 | #EXTRA_CCFLAGS += -u 19 | 20 | ifndef PDIR # { 21 | GEN_IMAGES= eagle.app.v6.out 22 | GEN_BINS= eagle.app.v6.bin 23 | SPECIAL_MKTARGETS=$(APP_MKTARGETS) 24 | SUBDIRS= \ 25 | user \ 26 | driver 27 | 28 | endif # } PDIR 29 | 30 | APPDIR = . 31 | LDDIR = ../ld 32 | 33 | CCFLAGS += -Os 34 | 35 | TARGET_LDFLAGS = \ 36 | -nostdlib \ 37 | -Wl,-EL \ 38 | --longcalls \ 39 | --text-section-literals 40 | 41 | ifeq ($(FLAVOR),debug) 42 | TARGET_LDFLAGS += -g -O2 43 | endif 44 | 45 | ifeq ($(FLAVOR),release) 46 | TARGET_LDFLAGS += -g -O0 47 | endif 48 | 49 | COMPONENTS_eagle.app.v6 = \ 50 | user/libuser.a \ 51 | driver/libdriver.a 52 | 53 | LINKFLAGS_eagle.app.v6 = \ 54 | -L../lib \ 55 | -nostdlib \ 56 | -T$(LD_FILE) \ 57 | -Wl,--no-check-sections \ 58 | -u call_user_start \ 59 | -Wl,-static \ 60 | -Wl,--start-group \ 61 | -lc \ 62 | -lgcc \ 63 | -lhal \ 64 | -lphy \ 65 | -lpp \ 66 | -lnet80211 \ 67 | -llwip \ 68 | -lwpa \ 69 | -lmain \ 70 | -ljson \ 71 | -lupgrade\ 72 | -lssl \ 73 | $(DEP_LIBS_eagle.app.v6) \ 74 | -Wl,--end-group 75 | 76 | DEPENDS_eagle.app.v6 = \ 77 | $(LD_FILE) \ 78 | $(LDDIR)/eagle.rom.addr.v6.ld 79 | 80 | ############################################################# 81 | # Configuration i.e. compile options etc. 82 | # Target specific stuff (defines etc.) goes in here! 83 | # Generally values applying to a tree are captured in the 84 | # makefile at its root level - these are then overridden 85 | # for a subtree within the makefile rooted therein 86 | # 87 | 88 | #UNIVERSAL_TARGET_DEFINES = \ 89 | 90 | # Other potential configuration flags include: 91 | # -DTXRX_TXBUF_DEBUG 92 | # -DTXRX_RXBUF_DEBUG 93 | # -DWLAN_CONFIG_CCX 94 | CONFIGURATION_DEFINES = -DICACHE_FLASH 95 | 96 | DEFINES += \ 97 | $(UNIVERSAL_TARGET_DEFINES) \ 98 | $(CONFIGURATION_DEFINES) 99 | 100 | DDEFINES += \ 101 | $(UNIVERSAL_TARGET_DEFINES) \ 102 | $(CONFIGURATION_DEFINES) 103 | 104 | 105 | ############################################################# 106 | # Recursion Magic - Don't touch this!! 107 | # 108 | # Each subtree potentially has an include directory 109 | # corresponding to the common APIs applicable to modules 110 | # rooted at that subtree. Accordingly, the INCLUDE PATH 111 | # of a module can only contain the include directories up 112 | # its parent path, and not its siblings 113 | # 114 | # Required for each makefile to inherit from the parent 115 | # 116 | 117 | INCLUDES := $(INCLUDES) -I $(PDIR)include 118 | PDIR := ../$(PDIR) 119 | sinclude $(PDIR)Makefile 120 | 121 | .PHONY: FORCE 122 | FORCE: 123 | 124 | -------------------------------------------------------------------------------- /app/driver/.output/eagle/debug/lib/libdriver.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/app/driver/.output/eagle/debug/lib/libdriver.a -------------------------------------------------------------------------------- /app/driver/.output/eagle/debug/obj/gpio16.d: -------------------------------------------------------------------------------- 1 | .output/eagle/debug/obj/gpio16.o .output/eagle/debug/obj/gpio16.d : gpio16.c ../../include/ets_sys.h ../../include/c_types.h \ 2 | ../../include/eagle_soc.h ../../include/osapi.h \ 3 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/string.h \ 4 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/_ansi.h \ 5 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/newlib.h \ 6 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/config.h \ 7 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/machine/ieeefp.h \ 8 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/features.h \ 9 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/xtensa/config/core-isa.h \ 10 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/reent.h \ 11 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/_ansi.h \ 12 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/_types.h \ 13 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/machine/_types.h \ 14 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/machine/_default_types.h \ 15 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/lock.h \ 16 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/lib/gcc/xtensa-lx106-elf/4.8.2/include/stddef.h \ 17 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/cdefs.h \ 18 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/string.h \ 19 | ../include/user_config.h ../include/driver/gpio16.h 20 | -------------------------------------------------------------------------------- /app/driver/.output/eagle/debug/obj/gpio16.o: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/app/driver/.output/eagle/debug/obj/gpio16.o -------------------------------------------------------------------------------- /app/driver/.output/eagle/debug/obj/i2c_master.d: -------------------------------------------------------------------------------- 1 | .output/eagle/debug/obj/i2c_master.o .output/eagle/debug/obj/i2c_master.d : i2c_master.c ../../include/ets_sys.h \ 2 | ../../include/c_types.h ../../include/eagle_soc.h ../../include/osapi.h \ 3 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/string.h \ 4 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/_ansi.h \ 5 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/newlib.h \ 6 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/config.h \ 7 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/machine/ieeefp.h \ 8 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/features.h \ 9 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/xtensa/config/core-isa.h \ 10 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/reent.h \ 11 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/_ansi.h \ 12 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/_types.h \ 13 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/machine/_types.h \ 14 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/machine/_default_types.h \ 15 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/lock.h \ 16 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/lib/gcc/xtensa-lx106-elf/4.8.2/include/stddef.h \ 17 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/cdefs.h \ 18 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/string.h \ 19 | ../include/user_config.h ../../include/gpio.h \ 20 | ../include/driver/i2c_master.h 21 | -------------------------------------------------------------------------------- /app/driver/.output/eagle/debug/obj/i2c_master.o: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/app/driver/.output/eagle/debug/obj/i2c_master.o -------------------------------------------------------------------------------- /app/driver/.output/eagle/debug/obj/key.d: -------------------------------------------------------------------------------- 1 | .output/eagle/debug/obj/key.o .output/eagle/debug/obj/key.d : key.c ../../include/ets_sys.h ../../include/c_types.h \ 2 | ../../include/eagle_soc.h ../../include/os_type.h \ 3 | ../../include/ets_sys.h ../../include/osapi.h \ 4 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/string.h \ 5 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/_ansi.h \ 6 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/newlib.h \ 7 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/config.h \ 8 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/machine/ieeefp.h \ 9 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/features.h \ 10 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/xtensa/config/core-isa.h \ 11 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/reent.h \ 12 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/_ansi.h \ 13 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/_types.h \ 14 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/machine/_types.h \ 15 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/machine/_default_types.h \ 16 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/lock.h \ 17 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/lib/gcc/xtensa-lx106-elf/4.8.2/include/stddef.h \ 18 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/cdefs.h \ 19 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/string.h \ 20 | ../include/user_config.h ../../include/mem.h ../../include/gpio.h \ 21 | ../../include/user_interface.h ../../include/os_type.h \ 22 | ../../include/ip_addr.h ../../include/queue.h ../../include/spi_flash.h \ 23 | ../include/driver/key.h 24 | -------------------------------------------------------------------------------- /app/driver/.output/eagle/debug/obj/key.o: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/app/driver/.output/eagle/debug/obj/key.o -------------------------------------------------------------------------------- /app/driver/.output/eagle/debug/obj/pwm.d: -------------------------------------------------------------------------------- 1 | .output/eagle/debug/obj/pwm.o .output/eagle/debug/obj/pwm.d : pwm.c ../../include/ets_sys.h ../../include/c_types.h \ 2 | ../../include/eagle_soc.h ../../include/os_type.h \ 3 | ../../include/ets_sys.h ../../include/osapi.h \ 4 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/string.h \ 5 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/_ansi.h \ 6 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/newlib.h \ 7 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/config.h \ 8 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/machine/ieeefp.h \ 9 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/features.h \ 10 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/xtensa/config/core-isa.h \ 11 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/reent.h \ 12 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/_ansi.h \ 13 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/_types.h \ 14 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/machine/_types.h \ 15 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/machine/_default_types.h \ 16 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/lock.h \ 17 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/lib/gcc/xtensa-lx106-elf/4.8.2/include/stddef.h \ 18 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/cdefs.h \ 19 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/string.h \ 20 | ../include/user_config.h ../../include/user_interface.h \ 21 | ../../include/os_type.h ../../include/ip_addr.h ../../include/queue.h \ 22 | ../../include/spi_flash.h ../include/driver/pwm.h 23 | -------------------------------------------------------------------------------- /app/driver/.output/eagle/debug/obj/pwm.o: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/app/driver/.output/eagle/debug/obj/pwm.o -------------------------------------------------------------------------------- /app/driver/.output/eagle/debug/obj/sensor_lp.d: -------------------------------------------------------------------------------- 1 | .output/eagle/debug/obj/sensor_lp.o .output/eagle/debug/obj/sensor_lp.d : sensor_lp.c ../../include/ets_sys.h ../../include/c_types.h \ 2 | ../../include/eagle_soc.h ../../include/osapi.h \ 3 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/string.h \ 4 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/_ansi.h \ 5 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/newlib.h \ 6 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/config.h \ 7 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/machine/ieeefp.h \ 8 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/features.h \ 9 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/xtensa/config/core-isa.h \ 10 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/reent.h \ 11 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/_ansi.h \ 12 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/_types.h \ 13 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/machine/_types.h \ 14 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/machine/_default_types.h \ 15 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/lock.h \ 16 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/lib/gcc/xtensa-lx106-elf/4.8.2/include/stddef.h \ 17 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/cdefs.h \ 18 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/string.h \ 19 | ../include/user_config.h ../../include/c_types.h \ 20 | ../../include/user_interface.h ../../include/os_type.h \ 21 | ../../include/ets_sys.h ../../include/ip_addr.h ../../include/queue.h \ 22 | ../../include/spi_flash.h ../include/user_devicefind.h \ 23 | ../include/user_webserver.h ../include/user_esp_platform.h \ 24 | ../include/driver/sensor_lp.h 25 | -------------------------------------------------------------------------------- /app/driver/.output/eagle/debug/obj/sensor_lp.o: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/app/driver/.output/eagle/debug/obj/sensor_lp.o -------------------------------------------------------------------------------- /app/driver/.output/eagle/debug/obj/spi.d: -------------------------------------------------------------------------------- 1 | .output/eagle/debug/obj/spi.o .output/eagle/debug/obj/spi.d : spi.c ../include/driver/spi.h ../include/driver/spi_register.h \ 2 | ../../include/ets_sys.h ../../include/c_types.h \ 3 | ../../include/eagle_soc.h ../../include/osapi.h \ 4 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/string.h \ 5 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/_ansi.h \ 6 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/newlib.h \ 7 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/config.h \ 8 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/machine/ieeefp.h \ 9 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/features.h \ 10 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/xtensa/config/core-isa.h \ 11 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/reent.h \ 12 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/_ansi.h \ 13 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/_types.h \ 14 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/machine/_types.h \ 15 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/machine/_default_types.h \ 16 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/lock.h \ 17 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/lib/gcc/xtensa-lx106-elf/4.8.2/include/stddef.h \ 18 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/cdefs.h \ 19 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/string.h \ 20 | ../include/user_config.h ../include/driver/uart.h \ 21 | ../include/driver/uart_register.h ../../include/os_type.h \ 22 | ../../include/ets_sys.h ../../include/gpio.h \ 23 | ../../include/user_interface.h ../../include/os_type.h \ 24 | ../../include/ip_addr.h ../../include/queue.h ../../include/spi_flash.h \ 25 | ../../include/mem.h 26 | -------------------------------------------------------------------------------- /app/driver/.output/eagle/debug/obj/spi.o: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/app/driver/.output/eagle/debug/obj/spi.o -------------------------------------------------------------------------------- /app/driver/.output/eagle/debug/obj/uart.d: -------------------------------------------------------------------------------- 1 | .output/eagle/debug/obj/uart.o .output/eagle/debug/obj/uart.d : uart.c ../../include/ets_sys.h ../../include/c_types.h \ 2 | ../../include/eagle_soc.h ../../include/osapi.h \ 3 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/string.h \ 4 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/_ansi.h \ 5 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/newlib.h \ 6 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/config.h \ 7 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/machine/ieeefp.h \ 8 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/features.h \ 9 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/xtensa/config/core-isa.h \ 10 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/reent.h \ 11 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/_ansi.h \ 12 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/_types.h \ 13 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/machine/_types.h \ 14 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/machine/_default_types.h \ 15 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/lock.h \ 16 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/lib/gcc/xtensa-lx106-elf/4.8.2/include/stddef.h \ 17 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/cdefs.h \ 18 | /Volumes/ESPTools/esp-open-sdk/xtensa-lx106-elf/xtensa-lx106-elf/include/sys/string.h \ 19 | ../include/user_config.h ../include/driver/uart.h \ 20 | ../include/driver/uart_register.h 21 | -------------------------------------------------------------------------------- /app/driver/.output/eagle/debug/obj/uart.o: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/app/driver/.output/eagle/debug/obj/uart.o -------------------------------------------------------------------------------- /app/driver/Makefile: -------------------------------------------------------------------------------- 1 | 2 | ############################################################# 3 | # Required variables for each makefile 4 | # Discard this section from all parent makefiles 5 | # Expected variables (with automatic defaults): 6 | # CSRCS (all "C" files in the dir) 7 | # SUBDIRS (all subdirs with a Makefile) 8 | # GEN_LIBS - list of libs to be generated () 9 | # GEN_IMAGES - list of images to be generated () 10 | # COMPONENTS_xxx - a list of libs/objs in the form 11 | # subdir/lib to be extracted and rolled up into 12 | # a generated lib/image xxx.a () 13 | # 14 | ifndef PDIR 15 | GEN_LIBS = libdriver.a 16 | endif 17 | 18 | 19 | ############################################################# 20 | # Configuration i.e. compile options etc. 21 | # Target specific stuff (defines etc.) goes in here! 22 | # Generally values applying to a tree are captured in the 23 | # makefile at its root level - these are then overridden 24 | # for a subtree within the makefile rooted therein 25 | # 26 | #DEFINES += 27 | 28 | ############################################################# 29 | # Recursion Magic - Don't touch this!! 30 | # 31 | # Each subtree potentially has an include directory 32 | # corresponding to the common APIs applicable to modules 33 | # rooted at that subtree. Accordingly, the INCLUDE PATH 34 | # of a module can only contain the include directories up 35 | # its parent path, and not its siblings 36 | # 37 | # Required for each makefile to inherit from the parent 38 | # 39 | 40 | INCLUDES := $(INCLUDES) -I $(PDIR)include 41 | INCLUDES += -I ./ 42 | PDIR := ../$(PDIR) 43 | sinclude $(PDIR)Makefile 44 | 45 | -------------------------------------------------------------------------------- /app/driver/gpio16.c: -------------------------------------------------------------------------------- 1 | #include "ets_sys.h" 2 | #include "osapi.h" 3 | #include "driver/gpio16.h" 4 | 5 | void ICACHE_FLASH_ATTR 6 | gpio16_output_conf(void) 7 | { 8 | WRITE_PERI_REG(PAD_XPD_DCDC_CONF, 9 | (READ_PERI_REG(PAD_XPD_DCDC_CONF) & 0xffffffbc) | (uint32)0x1); // mux configuration for XPD_DCDC to output rtc_gpio0 10 | 11 | WRITE_PERI_REG(RTC_GPIO_CONF, 12 | (READ_PERI_REG(RTC_GPIO_CONF) & (uint32)0xfffffffe) | (uint32)0x0); //mux configuration for out enable 13 | 14 | WRITE_PERI_REG(RTC_GPIO_ENABLE, 15 | (READ_PERI_REG(RTC_GPIO_ENABLE) & (uint32)0xfffffffe) | (uint32)0x1); //out enable 16 | } 17 | 18 | void ICACHE_FLASH_ATTR 19 | gpio16_output_set(uint8 value) 20 | { 21 | WRITE_PERI_REG(RTC_GPIO_OUT, 22 | (READ_PERI_REG(RTC_GPIO_OUT) & (uint32)0xfffffffe) | (uint32)(value & 1)); 23 | } 24 | 25 | void ICACHE_FLASH_ATTR 26 | gpio16_input_conf(void) 27 | { 28 | WRITE_PERI_REG(PAD_XPD_DCDC_CONF, 29 | (READ_PERI_REG(PAD_XPD_DCDC_CONF) & 0xffffffbc) | (uint32)0x1); // mux configuration for XPD_DCDC and rtc_gpio0 connection 30 | 31 | WRITE_PERI_REG(RTC_GPIO_CONF, 32 | (READ_PERI_REG(RTC_GPIO_CONF) & (uint32)0xfffffffe) | (uint32)0x0); //mux configuration for out enable 33 | 34 | WRITE_PERI_REG(RTC_GPIO_ENABLE, 35 | READ_PERI_REG(RTC_GPIO_ENABLE) & (uint32)0xfffffffe); //out disable 36 | } 37 | 38 | uint8 ICACHE_FLASH_ATTR 39 | gpio16_input_get(void) 40 | { 41 | return (uint8)(READ_PERI_REG(RTC_GPIO_IN_DATA) & 1); 42 | } 43 | -------------------------------------------------------------------------------- /app/driver/sensor_lp.c: -------------------------------------------------------------------------------- 1 | #include "ets_sys.h" 2 | #include "osapi.h" 3 | #include "c_types.h" 4 | #include "user_interface.h" 5 | #include "user_devicefind.h" 6 | #include "user_webserver.h" 7 | #include "user_esp_platform.h" 8 | #include "driver/sensor_lp.h" 9 | 10 | SENSOR_DATA_RTC_MEM sensor_data ; 11 | SENSOR_DATA_RTC_MEM* ICACHE_FLASH_ATTR get_sensor_data() { return &sensor_data; } 12 | 13 | void ICACHE_FLASH_ATTR data_func() { 14 | // Read out the sensor data structure from RTC memory 15 | system_rtc_mem_read( SENSOR_DATA_MEM_ADDR, &sensor_data, sizeof(SENSOR_DATA_RTC_MEM) ); 16 | 17 | // When the system powers on for the first time, the data in the rtc memory is random. 18 | struct esp_platform_saved_param esp_param_t; 19 | user_esp_platform_load_param(&esp_param_t); // Stored in flash 20 | // Load user params to check if the device was successfully registered to the server 21 | // If it wasn't, it usually returns 255 (from the flash.) 22 | 23 | if(sensor_data.init_flg!=INIT_MAGIC || sensor_data.cnt>SENSOR_DATA_NUM ) { 24 | // This case runs when we first power on or when it time to flush the RTC memory of old data. 25 | if(esp_param_t.activeflag!=1) { // If registered & activated 26 | user_esp_platform_init(); // Router is not configured. Setup softAP. Wait for config. 27 | #ifdef SERVER_SSL_ENABLE 28 | user_webserver_init(SERVER_SSL_PORT); 29 | #else 30 | user_webserver_init(SERVER_PORT); 31 | #endif 32 | } else { // was connected! So we set init magic to exit the setup loop 33 | sensor_data.init_flg = INIT_MAGIC; 34 | sensor_data.cnt = 0; 35 | system_rtc_mem_write(SENSOR_DATA_MEM_ADDR, &sensor_data, sizeof(SENSOR_DATA_RTC_MEM)); 36 | __SET__DEEP_SLEEP__WAKEUP_NO_RF__; 37 | system_deep_sleep(100000); 38 | } 39 | } else { // This is where the measurements are made 40 | uint16 vdd_val = 0; 41 | if(sensor_data.cnt<0 || sensor_data.cnt>=SENSOR_DATA_NUM) 42 | sensor_data.cnt=0; // range check and resets counter if needed 43 | 44 | /* Reads power supply voltage, byte 107 of init_data.bin should be set to 0xFF. 45 | * Replace with your own code.*/ 46 | sensor_data.data[sensor_data.cnt++] = (uint16)(phy_get_vdd33()); 47 | system_rtc_mem_write( SENSOR_DATA_MEM_ADDR, &sensor_data, sizeof(SENSOR_DATA_RTC_MEM) ); 48 | 49 | // Setup next sleep cycle 50 | if(sensor_data.cnt==SENSOR_DATA_NUM-1) { __SET__DEEP_SLEEP__WAKEUP_NORMAL__; } 51 | else { __SET__DEEP_SLEEP__WAKEUP_NO_RF__; } 52 | 53 | // Uploads or go to sleep 54 | if(sensor_data.cnt == SENSOR_DATA_NUM) { user_esp_platform_init(); } 55 | else { system_deep_sleep(SENSOR_DEEP_SLEEP_TIME); } 56 | } 57 | } 58 | 59 | -------------------------------------------------------------------------------- /app/gen_misc.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | 3 | echo Please follow below steps(1-5) to generate specific bin(s): 4 | echo STEP 1: choose boot version(0=boot_v1.1, 1=boot_v1.2+, 2=none) 5 | set input=default 6 | set /p input=enter(0/1/2, default 2): 7 | 8 | if %input% equ 0 ( 9 | set boot=old 10 | ) else ( 11 | if %input% equ 1 ( 12 | set boot=new 13 | ) else ( 14 | set boot=none 15 | ) 16 | ) 17 | 18 | echo boot mode: %boot% 19 | echo. 20 | 21 | echo STEP 2: choose bin generate(0=eagle.flash.bin+eagle.irom0text.bin, 1=user1.bin, 2=user2.bin) 22 | set input=default 23 | set /p input=enter (0/1/2, default 0): 24 | 25 | if %input% equ 1 ( 26 | if %boot% equ none ( 27 | set app=0 28 | echo choose no boot before 29 | echo generate bin: eagle.flash.bin+eagle.irom0text.bin 30 | ) else ( 31 | set app=1 32 | echo generate bin: user1.bin 33 | ) 34 | ) else ( 35 | if %input% equ 2 ( 36 | if %boot% equ none ( 37 | set app=0 38 | echo choose no boot before 39 | echo generate bin: eagle.flash.bin+eagle.irom0text.bin 40 | ) else ( 41 | set app=2 42 | echo generate bin: user2.bin 43 | ) 44 | ) else ( 45 | if %boot% neq none ( 46 | set boot=none 47 | echo ignore boot 48 | ) 49 | set app=0 50 | echo generate bin: eagle.flash.bin+eagle.irom0text.bin 51 | )) 52 | 53 | echo. 54 | 55 | echo STEP 3: choose spi speed(0=20MHz, 1=26.7MHz, 2=40MHz, 3=80MHz) 56 | set input=default 57 | set /p input=enter (0/1/2/3, default 2): 58 | 59 | if %input% equ 0 ( 60 | set spi_speed=20 61 | ) else ( 62 | if %input% equ 1 ( 63 | set spi_speed=26.7 64 | ) else ( 65 | if %input% equ 3 ( 66 | set spi_speed=80 67 | ) else ( 68 | set spi_speed=40 69 | ))) 70 | 71 | echo spi speed: %spi_speed% MHz 72 | echo. 73 | 74 | echo STEP 4: choose spi mode(0=QIO, 1=QOUT, 2=DIO, 3=DOUT) 75 | set input=default 76 | set /p input=enter (0/1/2/3, default 0): 77 | 78 | if %input% equ 1 ( 79 | set spi_mode=QOUT 80 | ) else ( 81 | if %input% equ 2 ( 82 | set spi_mode=DIO 83 | ) else ( 84 | if %input% equ 3 ( 85 | set spi_mode=DOUT 86 | ) else ( 87 | set spi_mode=QIO 88 | ))) 89 | 90 | echo spi mode: %spi_mode% 91 | echo. 92 | 93 | echo STEP 5: choose spi size(0=256KB, 1=512KB, 2=1024KB, 3=2048KB, 4=4096KB) 94 | set input=default 95 | set /p input=enter (0/1/2/3/4, default 1): 96 | 97 | if %input% equ 0 ( 98 | set spi_size=256 99 | ) else ( 100 | if %input% equ 2 ( 101 | set spi_size=1024 102 | ) else ( 103 | if %input% equ 3 ( 104 | set spi_size=2048 105 | ) else ( 106 | if %input% equ 4 ( 107 | set spi_size=4096 108 | ) else ( 109 | set spi_size=512 110 | )))) 111 | 112 | echo spi size: %spi_size% KB 113 | 114 | touch user/user_main.c 115 | 116 | echo. 117 | echo start... 118 | echo. 119 | 120 | make BOOT=%boot% APP=%app% SPI_SPEED=%spi_speed% SPI_MODE=%spi_mode% SPI_SIZE=%spi_size% 121 | 122 | -------------------------------------------------------------------------------- /app/gen_misc.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # File : gen_misc.sh 4 | # This file is part of Espressif's generate bin script. 5 | # Copyright (C) 2013 - 2015, Espressif Systems 6 | 7 | # Permission is hereby granted, free of charge, to any person obtaining a copy 8 | # of this software and associated documentation files (the "Software"), to deal 9 | # in the Software without restriction, including without limitation the rights 10 | # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 11 | # copies of the Software, and to permit persons to whom the Software is 12 | # furnished to do so, subject to the following conditions: 13 | 14 | # The above copyright notice and this permission notice shall be included in all 15 | # copies or substantial portions of the Software. 16 | 17 | # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 18 | # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 19 | # FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL THE 20 | # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 21 | # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 22 | # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 23 | # SOFTWARE. 24 | 25 | echo "Please follow below steps(1-5) to generate specific bin(s):" 26 | echo "STEP 1: choose boot version(0=boot_v1.1, 1=boot_v1.2+, 2=none)" 27 | echo "enter(0/1/2, default 2):" 28 | read input 29 | 30 | if [ -z "$input" ]; then 31 | boot=none 32 | elif [ $input == 0 ]; then 33 | boot=old 34 | elif [ $input == 1 ]; then 35 | boot=new 36 | else 37 | boot=none 38 | fi 39 | 40 | echo "boot mode: $boot" 41 | echo "" 42 | 43 | echo "STEP 2: choose bin generate(0=eagle.flash.bin+eagle.irom0text.bin, 1=user1.bin, 2=user2.bin)" 44 | echo "enter (0/1/2, default 0):" 45 | read input 46 | 47 | if [ -z "$input" ]; then 48 | if [ $boot != none ]; then 49 | boot=none 50 | echo "ignore boot" 51 | fi 52 | app=0 53 | echo "generate bin: eagle.flash.bin+eagle.irom0text.bin" 54 | elif [ $input == 1 ]; then 55 | if [ $boot == none ]; then 56 | app=0 57 | echo "choose no boot before" 58 | echo "generate bin: eagle.flash.bin+eagle.irom0text.bin" 59 | else 60 | app=1 61 | echo "generate bin: user1.bin" 62 | fi 63 | elif [ $input == 2 ]; then 64 | if [ $boot == none ]; then 65 | app=0 66 | echo "choose no boot before" 67 | echo "generate bin: eagle.flash.bin+eagle.irom0text.bin" 68 | else 69 | app=2 70 | echo "generate bin: user2.bin" 71 | fi 72 | else 73 | if [ $boot != none ]; then 74 | boot=none 75 | echo "ignore boot" 76 | fi 77 | app=0 78 | echo "generate bin: eagle.flash.bin+eagle.irom0text.bin" 79 | fi 80 | 81 | echo "" 82 | 83 | echo "STEP 3: choose spi speed(0=20MHz, 1=26.7MHz, 2=40MHz, 3=80MHz)" 84 | echo "enter (0/1/2/3, default 2):" 85 | read input 86 | 87 | if [ -z "$input" ]; then 88 | spi_speed=40 89 | elif [ $input == 0 ]; then 90 | spi_speed=20 91 | elif [ $input == 1 ]; then 92 | spi_speed=26.7 93 | elif [ $input == 3 ]; then 94 | spi_speed=80 95 | else 96 | spi_speed=40 97 | fi 98 | 99 | echo "spi speed: $spi_speed MHz" 100 | echo "" 101 | 102 | echo "STEP 4: choose spi mode(0=QIO, 1=QOUT, 2=DIO, 3=DOUT)" 103 | echo "enter (0/1/2/3, default 0):" 104 | read input 105 | 106 | if [ -z "$input" ]; then 107 | spi_mode=QIO 108 | elif [ $input == 1 ]; then 109 | spi_mode=QOUT 110 | elif [ $input == 2 ]; then 111 | spi_mode=DIO 112 | elif [ $input == 3 ]; then 113 | spi_mode=DOUT 114 | else 115 | spi_mode=QIO 116 | fi 117 | 118 | echo "spi mode: $spi_mode" 119 | echo "" 120 | 121 | echo "STEP 5: choose spi size(0=256KB, 1=512KB, 2=1024KB, 3=2048KB, 4=4096KB)" 122 | echo "enter (0/1/2/3/4, default 1):" 123 | read input 124 | 125 | if [ -z "$input" ]; then 126 | spi_size=512 127 | elif [ $input == 0 ]; then 128 | spi_size=256 129 | elif [ $input == 2 ]; then 130 | spi_size=1024 131 | elif [ $input == 3 ]; then 132 | spi_size=2048 133 | elif [ $input == 4 ]; then 134 | spi_size=4096 135 | else 136 | spi_size=512 137 | fi 138 | 139 | echo "spi size: $spi_size KB" 140 | echo "" 141 | 142 | touch user/user_main.c 143 | 144 | echo "" 145 | echo "start..." 146 | echo "" 147 | 148 | make COMPILE=gcc BOOT=$boot APP=$app SPI_SPEED=$spi_speed SPI_MODE=$spi_mode SPI_SIZE=$spi_size 149 | -------------------------------------------------------------------------------- /app/include/driver/gpio16.h: -------------------------------------------------------------------------------- 1 | #ifndef __GPIO16_H__ 2 | #define __GPIO16_H__ 3 | 4 | void gpio16_output_conf(void); 5 | void gpio16_output_set(uint8 value); 6 | void gpio16_input_conf(void); 7 | uint8 gpio16_input_get(void); 8 | 9 | #endif 10 | -------------------------------------------------------------------------------- /app/include/driver/i2c_master.h: -------------------------------------------------------------------------------- 1 | #ifndef __I2C_MASTER_H__ 2 | #define __I2C_MASTER_H__ 3 | 4 | #define I2C_MASTER_SDA_MUX PERIPHS_IO_MUX_GPIO2_U 5 | #define I2C_MASTER_SCL_MUX PERIPHS_IO_MUX_MTMS_U 6 | #define I2C_MASTER_SDA_GPIO 2 7 | #define I2C_MASTER_SCL_GPIO 14 8 | #define I2C_MASTER_SDA_FUNC FUNC_GPIO2 9 | #define I2C_MASTER_SCL_FUNC FUNC_GPIO14 10 | 11 | //#define I2C_MASTER_SDA_MUX PERIPHS_IO_MUX_GPIO2_U 12 | //#define I2C_MASTER_SCL_MUX PERIPHS_IO_MUX_GPIO0_U 13 | //#define I2C_MASTER_SDA_GPIO 2 14 | //#define I2C_MASTER_SCL_GPIO 0 15 | //#define I2C_MASTER_SDA_FUNC FUNC_GPIO2 16 | //#define I2C_MASTER_SCL_FUNC FUNC_GPIO0 17 | 18 | #if 0 19 | #define I2C_MASTER_GPIO_SET(pin) \ 20 | gpio_output_set(1<remote_ip, &ipconfig.ip, &ipconfig.netmask)) { 49 | wifi_get_ip_info(STATION_IF, &ipconfig); 50 | wifi_get_macaddr(STATION_IF, hwaddr); 51 | } 52 | } else { 53 | wifi_get_ip_info(STATION_IF, &ipconfig); 54 | wifi_get_macaddr(STATION_IF, hwaddr); 55 | } 56 | 57 | if (pusrdata == NULL) { 58 | return; 59 | } 60 | 61 | if (length == os_strlen(device_find_request) && 62 | os_strncmp(pusrdata, device_find_request, os_strlen(device_find_request)) == 0) { 63 | os_sprintf(DeviceBuffer, "%s" MACSTR " " IPSTR, device_find_response_ok, 64 | MAC2STR(hwaddr), IP2STR(&ipconfig.ip)); 65 | 66 | os_printf("%s\n", DeviceBuffer); 67 | length = os_strlen(DeviceBuffer); 68 | espconn_sent(&ptrespconn, DeviceBuffer, length); 69 | } else if (length == (os_strlen(device_find_request) + 18)) { 70 | os_sprintf(Device_mac_buffer, "%s " MACSTR , device_find_request, MAC2STR(hwaddr)); 71 | os_printf("%s", Device_mac_buffer); 72 | 73 | if (os_strncmp(Device_mac_buffer, pusrdata, os_strlen(device_find_request) + 18) == 0) { 74 | //os_printf("%s\n", Device_mac_buffer); 75 | length = os_strlen(DeviceBuffer); 76 | os_sprintf(DeviceBuffer, "%s" MACSTR " " IPSTR, device_find_response_ok, 77 | MAC2STR(hwaddr), IP2STR(&ipconfig.ip)); 78 | 79 | os_printf("%s\n", DeviceBuffer); 80 | length = os_strlen(DeviceBuffer); 81 | espconn_sent(&ptrespconn, DeviceBuffer, length); 82 | } else { 83 | return; 84 | } 85 | } 86 | } 87 | 88 | /****************************************************************************** 89 | * FunctionName : user_devicefind_init 90 | * Description : the espconn struct parame init 91 | * Parameters : none 92 | * Returns : none 93 | *******************************************************************************/ 94 | void ICACHE_FLASH_ATTR 95 | user_devicefind_init(void) { 96 | ptrespconn.type = ESPCONN_UDP; 97 | ptrespconn.proto.udp = (esp_udp *)os_zalloc(sizeof(esp_udp)); 98 | ptrespconn.proto.udp->local_port = 1025; 99 | espconn_regist_recvcb(&ptrespconn, user_devicefind_recv); 100 | espconn_create(&ptrespconn); 101 | } 102 | -------------------------------------------------------------------------------- /app/user/user_main.c: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * Copyright 2013-2014 Espressif Systems 3 | * 4 | * FileName: user_main.c 5 | * 6 | * Description: entry file of user application 7 | * 8 | * Modification history: 9 | * 2014/1/1, v1.0 create this file. 10 | * 2014/4/20, v1.0.1 edited for LP sensor 11 | *******************************************************************************/ 12 | #include "ets_sys.h" 13 | #include "osapi.h" 14 | 15 | #include "user_interface.h" 16 | 17 | #include "user_devicefind.h" 18 | #include "user_webserver.h" 19 | 20 | #if ESP_PLATFORM 21 | #include "user_esp_platform.h" 22 | #endif 23 | 24 | #ifdef SERVER_SSL_ENABLE 25 | #include "ssl/cert.h" 26 | #include "ssl/private_key.h" 27 | #else 28 | #ifdef CLIENT_SSL_ENABLE 29 | unsigned char *default_certificate; 30 | unsigned int default_certificate_len = 0; 31 | unsigned char *default_private_key; 32 | unsigned int default_private_key_len = 0; 33 | #endif 34 | #endif 35 | 36 | #include "driver/sensor_lp.h" 37 | #include "driver/uart.h" 38 | 39 | 40 | /****************************************************************************** 41 | * FunctionName : user_init 42 | * Description : entry of user application, init user function here 43 | * Parameters : none 44 | * Returns : none 45 | *******************************************************************************/ 46 | void user_init(void) { 47 | //set the uart baudrate to 115200 48 | uart_div_modify(0, 80*1000000 / 115200); 49 | os_printf("SDK version:%s\n", system_get_sdk_version()); 50 | data_func(); 51 | } 52 | 53 | -------------------------------------------------------------------------------- /app/user/user_sensor.c: -------------------------------------------------------------------------------- 1 | /****************************************************************************** 2 | * Copyright 2013-2014 Espressif Systems 3 | * 4 | * FileName: user_sensor.c 5 | * 6 | * Description: sensor demo's function realization 7 | * 8 | * Modification history: 9 | * 2014/5/1, v1.0 create this file. 10 | *******************************************************************************/ 11 | #include "ets_sys.h" 12 | #include "osapi.h" 13 | #include "os_type.h" 14 | #include "user_interface.h" 15 | 16 | #include "user_config.h" 17 | 18 | #if SENSOR_DEVICE 19 | #include "user_sensor.h" 20 | 21 | LOCAL struct keys_param keys; 22 | LOCAL struct single_key_param *single_key[SENSOR_KEY_NUM]; 23 | LOCAL os_timer_t sensor_sleep_timer; 24 | LOCAL os_timer_t link_led_timer; 25 | LOCAL uint8 link_led_level = 0; 26 | LOCAL uint32 link_start_time; 27 | 28 | 29 | /****************************************************************************** 30 | * FunctionName : user_sensor_long_press 31 | * Description : sensor key's function, needed to be installed 32 | * Parameters : none 33 | * Returns : none 34 | *******************************************************************************/ 35 | LOCAL void ICACHE_FLASH_ATTR user_sensor_long_press(void) { 36 | user_esp_platform_set_active(0); 37 | system_restore(); 38 | system_restart(); 39 | } 40 | 41 | LOCAL void ICACHE_FLASH_ATTR user_link_led_init(void) { 42 | PIN_FUNC_SELECT(SENSOR_LINK_LED_IO_MUX, SENSOR_LINK_LED_IO_FUNC); 43 | PIN_FUNC_SELECT(SENSOR_UNUSED_LED_IO_MUX, SENSOR_UNUSED_LED_IO_FUNC); 44 | GPIO_OUTPUT_SET(GPIO_ID_PIN(SENSOR_UNUSED_LED_IO_NUM), 0); 45 | } 46 | 47 | void ICACHE_FLASH_ATTR user_link_led_output(uint8 level) { 48 | GPIO_OUTPUT_SET(GPIO_ID_PIN(SENSOR_LINK_LED_IO_NUM), level); 49 | } 50 | 51 | LOCAL void ICACHE_FLASH_ATTR user_link_led_timer_cb(void) { 52 | link_led_level = (~link_led_level) & 0x01; 53 | GPIO_OUTPUT_SET(GPIO_ID_PIN(SENSOR_LINK_LED_IO_NUM), link_led_level); 54 | } 55 | 56 | void ICACHE_FLASH_ATTR user_link_led_timer_init(void) { 57 | link_start_time = system_get_time(); 58 | os_timer_disarm(&link_led_timer); 59 | os_timer_setfn(&link_led_timer, (os_timer_func_t *)user_link_led_timer_cb, NULL); 60 | os_timer_arm(&link_led_timer, 50, 1); 61 | link_led_level = 0; 62 | GPIO_OUTPUT_SET(GPIO_ID_PIN(SENSOR_LINK_LED_IO_NUM), link_led_level); 63 | } 64 | 65 | void ICACHE_FLASH_ATTR user_link_led_timer_done(void) { 66 | os_timer_disarm(&link_led_timer); 67 | GPIO_OUTPUT_SET(GPIO_ID_PIN(SENSOR_LINK_LED_IO_NUM), 0); 68 | } 69 | 70 | void ICACHE_FLASH_ATTR user_sensor_deep_sleep_enter(void) { 71 | system_deep_sleep(SENSOR_DEEP_SLEEP_TIME > link_start_time \ 72 | ? SENSOR_DEEP_SLEEP_TIME - link_start_time : 30000000); 73 | } 74 | 75 | void ICACHE_FLASH_ATTR user_sensor_deep_sleep_disable(void) { 76 | os_timer_disarm(&sensor_sleep_timer); 77 | } 78 | 79 | void ICACHE_FLASH_ATTR user_sensor_deep_sleep_init(uint32 time) { 80 | os_timer_disarm(&sensor_sleep_timer); 81 | os_timer_setfn(&sensor_sleep_timer, (os_timer_func_t *)user_sensor_deep_sleep_enter, NULL); 82 | os_timer_arm(&sensor_sleep_timer, time, 0); 83 | } 84 | 85 | /****************************************************************************** 86 | * FunctionName : user_sensor_init 87 | * Description : init sensor function, include key and mvh3004 88 | * Parameters : none 89 | * Returns : none 90 | *******************************************************************************/ 91 | void ICACHE_FLASH_ATTR user_sensor_init(uint8 active) { 92 | user_link_led_init(); 93 | wifi_status_led_install(SENSOR_WIFI_LED_IO_NUM, SENSOR_WIFI_LED_IO_MUX, SENSOR_WIFI_LED_IO_FUNC); 94 | 95 | if (wifi_get_opmode() != SOFTAP_MODE) { 96 | single_key[0] = key_init_single(SENSOR_KEY_IO_NUM, SENSOR_KEY_IO_MUX, SENSOR_KEY_IO_FUNC, 97 | user_sensor_long_press, NULL); 98 | 99 | keys.key_num = SENSOR_KEY_NUM; 100 | keys.single_key = single_key; 101 | key_init(&keys); 102 | 103 | if (GPIO_INPUT_GET(GPIO_ID_PIN(SENSOR_KEY_IO_NUM)) == 0) { 104 | user_sensor_long_press(); 105 | } 106 | } 107 | 108 | if (wifi_get_opmode() != STATIONAP_MODE) { 109 | if (active == 1) { 110 | user_sensor_deep_sleep_init(SENSOR_CONNECT_TIME / 1000);//exceed SENSOR_CONNECT_TIME,sleep directly 111 | } else { 112 | user_sensor_deep_sleep_init(SENSOR_CONNECT_TIME / 1000);//exceed SENSOR_CONNECT_TIME,sleep directly 113 | } 114 | } 115 | } 116 | #endif 117 | 118 | -------------------------------------------------------------------------------- /bin/blank.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/blank.bin -------------------------------------------------------------------------------- /bin/boot_v1.1.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/boot_v1.1.bin -------------------------------------------------------------------------------- /bin/boot_v1.2.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/boot_v1.2.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/1312fe7b287025955266ba5642164d8e34c58825.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/1312fe7b287025955266ba5642164d8e34c58825.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/19d81ed280cfe426afbe22d8849277364c5fb652.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/19d81ed280cfe426afbe22d8849277364c5fb652.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/1a674b0abf5da778c74e07e66e88e89787724dfc.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/1a674b0abf5da778c74e07e66e88e89787724dfc.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/1d8c1d2efaac55f427c575029d5c3dc37162c6c0.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/1d8c1d2efaac55f427c575029d5c3dc37162c6c0.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/1e6223eda2891355611fe69153a296910d69bfe1.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/1e6223eda2891355611fe69153a296910d69bfe1.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/2c4fd723c2f16f5f0a0ccdee42bfc051af32f198.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/2c4fd723c2f16f5f0a0ccdee42bfc051af32f198.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/2e0ecd31473113d7b927db1c159e634004c18d9c.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/2e0ecd31473113d7b927db1c159e634004c18d9c.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/2e3eb8d817e448a6e0562538d96f0fe3b7491523.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/2e3eb8d817e448a6e0562538d96f0fe3b7491523.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/30a72d0e002420d71adce5eeecea99dbbe89f6d9.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/30a72d0e002420d71adce5eeecea99dbbe89f6d9.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/3150be56bb829794243c8d3c96810b3980f69a2b.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/3150be56bb829794243c8d3c96810b3980f69a2b.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/355b424b5b04a54e5febcad8642f9087062f10e6.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/355b424b5b04a54e5febcad8642f9087062f10e6.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/3739445d260abc7ceafcffeb498c86fadd778292.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/3739445d260abc7ceafcffeb498c86fadd778292.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/379bcbfc0e8def10d8bd57fd7c5cd79538ff367f.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/379bcbfc0e8def10d8bd57fd7c5cd79538ff367f.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/3b6e892cd723eaac4b9a3662feb9cb87645dc468.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/3b6e892cd723eaac4b9a3662feb9cb87645dc468.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/3ca045eedf039ccd04dd7ca90ff95fc8eac0a042.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/3ca045eedf039ccd04dd7ca90ff95fc8eac0a042.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/41dc1061b28c4675a7759444b866eb6578224c02.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/41dc1061b28c4675a7759444b866eb6578224c02.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/4321bd99bf2054db74531f0aac217c0f3352ac98.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/4321bd99bf2054db74531f0aac217c0f3352ac98.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/4640b8c31ced78d2f207c7a8f0dfe4d67d516e08.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/4640b8c31ced78d2f207c7a8f0dfe4d67d516e08.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/4cf8e02c2de23041c163a04fc86ec502884c4fb7.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/4cf8e02c2de23041c163a04fc86ec502884c4fb7.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/503864dae691f7ee1d430d75e4fcb154b0cc36c7.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/503864dae691f7ee1d430d75e4fcb154b0cc36c7.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/511416f189ca81b6643ccbab6fbfae0a959328aa.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/511416f189ca81b6643ccbab6fbfae0a959328aa.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/53c4098f9594a200e63841a189f6d4e93e0bcdcd.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/53c4098f9594a200e63841a189f6d4e93e0bcdcd.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/55b9358e85ac07cd909f608041575b7653b26ade.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/55b9358e85ac07cd909f608041575b7653b26ade.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/590aab2e9ff28cbe0c9f892d5eab5ae7ad9c1fd1.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/590aab2e9ff28cbe0c9f892d5eab5ae7ad9c1fd1.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/59f92d8cd90534985a7716388d61699c1e84fd11.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/59f92d8cd90534985a7716388d61699c1e84fd11.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/5b522ef53c1b5773f3e9f3e48d0f91efd122d7b4.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/5b522ef53c1b5773f3e9f3e48d0f91efd122d7b4.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/5cc010bc9ba7d6cc7c7d6638d5ad8284a56d2935.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/5cc010bc9ba7d6cc7c7d6638d5ad8284a56d2935.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/5e0b40b7b300192e829fe64e3f0f8953103209ad.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/5e0b40b7b300192e829fe64e3f0f8953103209ad.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/611291ac0776e7a247000747a3894e6a90b1a195.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/611291ac0776e7a247000747a3894e6a90b1a195.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/68a45ac41ef3675eafc0fe2dae742c3273ce96fa.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/68a45ac41ef3675eafc0fe2dae742c3273ce96fa.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/69c62bbf28d73f36eb7daf11eafa4aee01d05f7c.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/69c62bbf28d73f36eb7daf11eafa4aee01d05f7c.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/6bca1801e38dd3e18472e1f46b06487e2626924f.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/6bca1801e38dd3e18472e1f46b06487e2626924f.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/6d1a8612ad1828155b8e1502ce824920c92c316d.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/6d1a8612ad1828155b8e1502ce824920c92c316d.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/6dd15dfb944a858cc5f5a8379d0c21c7cb089d7c.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/6dd15dfb944a858cc5f5a8379d0c21c7cb089d7c.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/6ea6964ca9a5004a1a9377022699bd11ffe1f5a7.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/6ea6964ca9a5004a1a9377022699bd11ffe1f5a7.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/70d75e4857873f6b940da6633a85e676cbe17c41.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/70d75e4857873f6b940da6633a85e676cbe17c41.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/720e6ca904675a596ba312a73e469f03ebcf601a.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/720e6ca904675a596ba312a73e469f03ebcf601a.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/72260589053fe1d6d0515840ff6f2a01d870ccbe.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/72260589053fe1d6d0515840ff6f2a01d870ccbe.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/72791acb4a18362947a51743e991c5b1b33747c2.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/72791acb4a18362947a51743e991c5b1b33747c2.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/72847c1aafce98cd38b092268986fcfcd1a1b214.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/72847c1aafce98cd38b092268986fcfcd1a1b214.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/729023461ad9fb78df70b8e4cad8041b4f20aafe.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/729023461ad9fb78df70b8e4cad8041b4f20aafe.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/748f1f3627e174f39d5560049a7d868a44f6d2a8.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/748f1f3627e174f39d5560049a7d868a44f6d2a8.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/78597104387b72ca6fa55a99ae8e929a573d1de7.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/78597104387b72ca6fa55a99ae8e929a573d1de7.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/7aec77fc2f5ea6df2fa43687d21892dbd0f76f1e.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/7aec77fc2f5ea6df2fa43687d21892dbd0f76f1e.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/7bc280151e08ad01df088605e0da5e6921db0f3b.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/7bc280151e08ad01df088605e0da5e6921db0f3b.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/7bf23a6b947c7c78e20385ed5b488c4e48de6e5a.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/7bf23a6b947c7c78e20385ed5b488c4e48de6e5a.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/7e3281674b5e0357e26c326339f3289fb8390938.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/7e3281674b5e0357e26c326339f3289fb8390938.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/7ef3d1657c4f7a87e842c85659e65923cef54b74.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/7ef3d1657c4f7a87e842c85659e65923cef54b74.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/802a985ea3565252593981b46f8863ff6445f545.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/802a985ea3565252593981b46f8863ff6445f545.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/8158807b97609ed17cb2045cc58f05b82c14eff9.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/8158807b97609ed17cb2045cc58f05b82c14eff9.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/81dcf7eaedfd0e532fc2d268d6ef02cd8a96751e.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/81dcf7eaedfd0e532fc2d268d6ef02cd8a96751e.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/850300c1cd6601bd5b58dbfb43c09d1898c3b122.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/850300c1cd6601bd5b58dbfb43c09d1898c3b122.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/8ac740272ae313ef700a587f9a2fe0cbdc1bf91d.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/8ac740272ae313ef700a587f9a2fe0cbdc1bf91d.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/8b8a5aa14d367efdd496c5f828b34159e57a7274.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/8b8a5aa14d367efdd496c5f828b34159e57a7274.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/8c5090b11698b8b59d53e8f9dd77a822cb064d50.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/8c5090b11698b8b59d53e8f9dd77a822cb064d50.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/8cc9ca7a3bfe8f95ae35b5103dae81a2c55be913.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/8cc9ca7a3bfe8f95ae35b5103dae81a2c55be913.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/8f78ffed9b81d044d66caca8cc8217f85ebb08aa.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/8f78ffed9b81d044d66caca8cc8217f85ebb08aa.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/9065a1530500e46fc32011cb45c96aedc96f875f.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/9065a1530500e46fc32011cb45c96aedc96f875f.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/9119e7322671ca416dd04bd792599bea62435a0f.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/9119e7322671ca416dd04bd792599bea62435a0f.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/92fcc03fceb0c015a5552722fe6ffc7eb6474916.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/92fcc03fceb0c015a5552722fe6ffc7eb6474916.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/94be6e380a6f6108347d2a271ba621b32dc359da.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/94be6e380a6f6108347d2a271ba621b32dc359da.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/9884d87c487de6f2738f67776575a8f1e19e9428.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/9884d87c487de6f2738f67776575a8f1e19e9428.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/993f41e99283dfe8159fe0ade55402ddbcaffc00.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/993f41e99283dfe8159fe0ade55402ddbcaffc00.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/99f9b0b9c7a58ca38627c7819884bdf2cdc85b60.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/99f9b0b9c7a58ca38627c7819884bdf2cdc85b60.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/9a711512de3b3dd0a545de9cc7b3078a988983fb.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/9a711512de3b3dd0a545de9cc7b3078a988983fb.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/9d7a138d6ac6bca768dbc5ed5a121ebabf18eed7.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/9d7a138d6ac6bca768dbc5ed5a121ebabf18eed7.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/9e09b6e9af56780b01c3bf65a48e090fe4450a65.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/9e09b6e9af56780b01c3bf65a48e090fe4450a65.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/9efac19539d5dbea2b9fdebe14a0245f0a6470f6.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/9efac19539d5dbea2b9fdebe14a0245f0a6470f6.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/a04d3ba05ff1fc431dff0a1ac80c53e6f5527cd1.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/a04d3ba05ff1fc431dff0a1ac80c53e6f5527cd1.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/a1d201f61615839136e30925c907d7d6691ffdf4.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/a1d201f61615839136e30925c907d7d6691ffdf4.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/a3005d343bc938997141bf38c33efa6bc9cad014.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/a3005d343bc938997141bf38c33efa6bc9cad014.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/a8cb4171813ed2099c3aa9a230c145efd333c759.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/a8cb4171813ed2099c3aa9a230c145efd333c759.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/b03c9946c691da09f0ab710dad04247df53d014c.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/b03c9946c691da09f0ab710dad04247df53d014c.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/b0aad3f5edbda92681ba248707b7a470b8645c93.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/b0aad3f5edbda92681ba248707b7a470b8645c93.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/b2e85ad12e1b3ada64bee5966b290e81478829bb.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/b2e85ad12e1b3ada64bee5966b290e81478829bb.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/bbef8d57547e9607b58242a576e214cf0fcb63f6.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/bbef8d57547e9607b58242a576e214cf0fcb63f6.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/bc5215ebce7de8a96f3b9d2e8cae22ca4a05610f.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/bc5215ebce7de8a96f3b9d2e8cae22ca4a05610f.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/c17299ecc6a7e3bf6a1984d0c71f78aee89fa673.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/c17299ecc6a7e3bf6a1984d0c71f78aee89fa673.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/c37ba3d2c494fcf82d0f37f616f2febeb0257f2c.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/c37ba3d2c494fcf82d0f37f616f2febeb0257f2c.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/c63e137fae7ac2bfa04b785a33ce4b6d615856dc.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/c63e137fae7ac2bfa04b785a33ce4b6d615856dc.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/c6937b888053cf7798e26d3c9522e3d6f0b628e2.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/c6937b888053cf7798e26d3c9522e3d6f0b628e2.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/c82cea3be5695b9b63165015813f1021810f5f09.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/c82cea3be5695b9b63165015813f1021810f5f09.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/cd29d4071bf14cbee09f68e62dac9191acd91c25.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/cd29d4071bf14cbee09f68e62dac9191acd91c25.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/ce9c4ba672fe888beaf00fcdb753f068c64634e7.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/ce9c4ba672fe888beaf00fcdb753f068c64634e7.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/d0f059bb651bc87680730539d19bbb5131f7cab7.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/d0f059bb651bc87680730539d19bbb5131f7cab7.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/d4665eabfaa39f9d1b3bdcd00c35cc39cc42ebf5.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/d4665eabfaa39f9d1b3bdcd00c35cc39cc42ebf5.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/dcc3aba22f77141f3e390cca58e270c3b5f14b67.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/dcc3aba22f77141f3e390cca58e270c3b5f14b67.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/e2f353aad73aade9e3816f2789a1727664268573.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/e2f353aad73aade9e3816f2789a1727664268573.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/ef9d837492ad9b8781e8b14061895cea3fc02ea2.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/ef9d837492ad9b8781e8b14061895cea3fc02ea2.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/f2dada5d39f0aad7f3073e8689abb141dc854d0b.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/f2dada5d39f0aad7f3073e8689abb141dc854d0b.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/f38e3770958f99399f0340829880503973b77301.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/f38e3770958f99399f0340829880503973b77301.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/f3ea80726e8e72b45c2d76fea236ce4b368afa13.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/f3ea80726e8e72b45c2d76fea236ce4b368afa13.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/f62b940b69d713a1a743456bffe4937e59075560.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/f62b940b69d713a1a743456bffe4937e59075560.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/f72acba76e156ad425dc6b6fe030908dd223d36a.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/f72acba76e156ad425dc6b6fe030908dd223d36a.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/fa98d6d8367de32e4977f4bc246835529d2aee8b.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/fa98d6d8367de32e4977f4bc246835529d2aee8b.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/ff34d55ac4c39070d88551e57929aef9a4865139.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/ff34d55ac4c39070d88551e57929aef9a4865139.bin -------------------------------------------------------------------------------- /bin/devicekeys_ULP_sensor/ff9ab573d9c48d60c8084759db323e79b93b2db5.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/devicekeys_ULP_sensor/ff9ab573d9c48d60c8084759db323e79b93b2db5.bin -------------------------------------------------------------------------------- /bin/eagle.flash.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/eagle.flash.bin -------------------------------------------------------------------------------- /bin/eagle.flash_disable_rf.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/eagle.flash_disable_rf.bin -------------------------------------------------------------------------------- /bin/eagle.irom0text.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/eagle.irom0text.bin -------------------------------------------------------------------------------- /bin/esp_init_data_default.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/esp_init_data_default.bin -------------------------------------------------------------------------------- /bin/esp_init_data_vdd33.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/esp_init_data_vdd33.bin -------------------------------------------------------------------------------- /bin/esp_init_data_vdd33.bin_40M: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/esp_init_data_vdd33.bin_40M -------------------------------------------------------------------------------- /bin/gen_key_bin.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | 3 | f = open('master_device_key.txt','r') 4 | key = f.readline().strip() 5 | 6 | g = open('key.bin','w') 7 | g.write('{:\xFF<128}'.format(key)) 8 | -------------------------------------------------------------------------------- /bin/key.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/key.bin -------------------------------------------------------------------------------- /bin/low_power_sensor_default_bin/blank.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/low_power_sensor_default_bin/blank.bin -------------------------------------------------------------------------------- /bin/low_power_sensor_default_bin/eagle.flash_disable_rf.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/low_power_sensor_default_bin/eagle.flash_disable_rf.bin -------------------------------------------------------------------------------- /bin/low_power_sensor_default_bin/eagle.irom0text.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/low_power_sensor_default_bin/eagle.irom0text.bin -------------------------------------------------------------------------------- /bin/low_power_sensor_default_bin/esp_init_data_vdd33.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/low_power_sensor_default_bin/esp_init_data_vdd33.bin -------------------------------------------------------------------------------- /bin/low_power_sensor_default_bin/esp_init_data_vdd33.bin_40M: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/low_power_sensor_default_bin/esp_init_data_vdd33.bin_40M -------------------------------------------------------------------------------- /bin/low_power_sensor_default_bin/readme.txt: -------------------------------------------------------------------------------- 1 | This is a default bin compiled by the demo 2 | 3 | download: 4 | 5 | eagle.flash_disable_rf.bin -> 0x0 6 | eagle.irom0text.bin -> 0x40000 7 | esp_init_data_vdd33.bin -> 0x7c000 8 | blank.bin -> 0x7e000 9 | device_master_key -> 0x3e000 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /bin/low_power_sensor_default_bin/write_flash.sh: -------------------------------------------------------------------------------- 1 | ../../tools/esptool.py --port /dev/tty.usbserial-AL00D9W2 write_flash \ 2 | 0x00000 eagle.flash_disable_rf.bin \ 3 | 0x40000 eagle.irom0text.bin \ 4 | 0x7c000 esp_init_data_vdd33.bin_40M \ 5 | 0x7e000 blank.bin \ 6 | 0x3e000 ../devicekeys_ULP_sensor/68a45ac41ef3675eafc0fe2dae742c3273ce96fa.bin 7 | 8 | -------------------------------------------------------------------------------- /bin/master_device_key.txt: -------------------------------------------------------------------------------- 1 | 68a45ac41ef3675eafc0fe2dae742c3273ce96fa 2 | -------------------------------------------------------------------------------- /bin/upgrade/user1.512.old.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/upgrade/user1.512.old.bin -------------------------------------------------------------------------------- /bin/upgrade/user1.512.old_disable_rf.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/bin/upgrade/user1.512.old_disable_rf.bin -------------------------------------------------------------------------------- /bin/write_flash.sh: -------------------------------------------------------------------------------- 1 | python ../tools/add_disable_rf_cmd.py eagle.flash.bin 2 | ../tools/esptool.py --port /dev/tty.usbserial-AL00ALCV write_flash \ 3 | 0x00000 eagle.flash_disable_rf.bin \ 4 | 0x40000 eagle.irom0text.bin \ 5 | 0x7c000 esp_init_data_vdd33.bin \ 6 | 0x7e000 blank.bin \ 7 | 0x3e000 key.bin 8 | -------------------------------------------------------------------------------- /include/at_custom.h: -------------------------------------------------------------------------------- 1 | 2 | /* 3 | * custom_at.h 4 | * 5 | * This file is part of Espressif's AT+ command set program. 6 | * Copyright (C) 2013 - 2016, Espressif Systems 7 | * Permission is hereby granted, free of charge, to any person obtaining a copy 8 | * of this software and associated documentation files (the "Software"), to deal 9 | * in the Software without restriction, including without limitation the rights 10 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 11 | * copies of the Software, and to permit persons to whom the Software is 12 | * furnished to do so, subject to the following conditions: 13 | * 14 | * The above copyright notice and this permission notice shall be included in all 15 | * copies or substantial portions of the Software. 16 | * 17 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 18 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 19 | * FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL THE 20 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 21 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 22 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 23 | * SOFTWARE. 24 | */ 25 | 26 | #ifndef CUSTOM_AT_H_ 27 | #define CUSTOM_AT_H_ 28 | 29 | #include "c_types.h" 30 | 31 | typedef struct 32 | { 33 | char *at_cmdName; 34 | int8_t at_cmdLen; 35 | void (*at_testCmd)(uint8_t id); 36 | void (*at_queryCmd)(uint8_t id); 37 | void (*at_setupCmd)(uint8_t id, char *pPara); 38 | void (*at_exeCmd)(uint8_t id); 39 | }at_funcationType; 40 | 41 | /** 42 | * @brief Response "OK" to uart. 43 | * @param None 44 | * @retval None 45 | */ 46 | void at_response_ok(void); 47 | /** 48 | * @brief Response "ERROR" to uart. 49 | * @param events: no used 50 | * @retval None 51 | */ 52 | void at_response_error(void); 53 | /** 54 | * @brief Task of process command or txdata. 55 | * @param custom_at_cmd_array: the array of at cmd that custom defined 56 | * cmd_num : the num of at cmd that custom defined 57 | * @retval None 58 | */ 59 | void at_cmd_array_regist(at_funcationType *custom_at_cmd_array,uint32 cmd_num); 60 | /** 61 | * @brief get digit form at cmd line.the maybe alter pSrc 62 | * @param p_src: at cmd line string 63 | * result:the buffer to be placed result 64 | * err : err num 65 | * @retval TRUE: 66 | * FALSE: 67 | */ 68 | bool at_get_next_int_dec(char **p_src,int*result,int* err); 69 | /** 70 | * @brief get string form at cmd line.the maybe alter pSrc 71 | * @param p_dest: the buffer to be placed result 72 | * p_src: at cmd line string 73 | * max_len :max len of string excepted to get 74 | * @retval None 75 | */ 76 | int32 at_data_str_copy(char *p_dest, char **p_src, int32 max_len); 77 | 78 | /** 79 | * @brief initialize at module 80 | * @param None 81 | * @retval None 82 | */ 83 | void at_init(void); 84 | /** 85 | * @brief print string to at port 86 | * @param string 87 | * @retval None 88 | */ 89 | void at_port_print(const char *str); 90 | #endif 91 | -------------------------------------------------------------------------------- /include/c_types.h: -------------------------------------------------------------------------------- 1 | /* 2 | * copyright (c) Espressif System 2010 3 | * 4 | * This file is part of Espressif IOT Software Development Kit. 5 | * Copyright (C) 2013 - 2016, Espressif Systems 6 | * Permission is hereby granted, free of charge, to any person obtaining a copy 7 | * of this software and associated documentation files (the "Software"), to deal 8 | * in the Software without restriction, including without limitation the rights 9 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | * copies of the Software, and to permit persons to whom the Software is 11 | * furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all 14 | * copies or substantial portions of the Software. 15 | * 16 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | * FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL THE 19 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 22 | * SOFTWARE. 23 | */ 24 | 25 | #ifndef _C_TYPES_H_ 26 | #define _C_TYPES_H_ 27 | 28 | typedef unsigned char uint8_t; 29 | typedef signed char sint8_t; 30 | typedef signed char int8_t; 31 | typedef unsigned short uint16_t; 32 | typedef signed short sint16_t; 33 | typedef signed short int16_t; 34 | typedef unsigned long uint32_t; 35 | typedef signed long sint32_t; 36 | typedef signed long int32_t; 37 | typedef signed long long sint64_t; 38 | typedef unsigned long long uint64_t; 39 | typedef unsigned long long u_int64_t; 40 | typedef float real32_t; 41 | typedef double real64_t; 42 | 43 | typedef unsigned char uint8; 44 | typedef unsigned char u8; 45 | typedef signed char sint8; 46 | typedef signed char int8; 47 | typedef signed char s8; 48 | typedef unsigned short uint16; 49 | typedef unsigned short u16; 50 | typedef signed short sint16; 51 | typedef signed short s16; 52 | typedef unsigned int uint32; 53 | typedef unsigned int u_int; 54 | typedef unsigned int u32; 55 | typedef signed int sint32; 56 | typedef signed int s32; 57 | typedef int int32; 58 | typedef signed long long sint64; 59 | typedef unsigned long long uint64; 60 | typedef unsigned long long u64; 61 | typedef float real32; 62 | typedef double real64; 63 | 64 | #define __le16 u16 65 | 66 | typedef unsigned int size_t; 67 | 68 | #define __packed __attribute__((packed)) 69 | 70 | #define LOCAL static 71 | 72 | #ifndef NULL 73 | #define NULL (void *)0 74 | #endif /* NULL */ 75 | 76 | /* probably should not put STATUS here */ 77 | typedef enum { 78 | OK = 0, 79 | FAIL, 80 | PENDING, 81 | BUSY, 82 | CANCEL, 83 | } STATUS; 84 | 85 | #define BIT(nr) (1UL << (nr)) 86 | 87 | #define REG_SET_BIT(_r, _b) (*(volatile uint32_t*)(_r) |= (_b)) 88 | #define REG_CLR_BIT(_r, _b) (*(volatile uint32_t*)(_r) &= ~(_b)) 89 | 90 | #define DMEM_ATTR __attribute__((section(".bss"))) 91 | #define SHMEM_ATTR 92 | 93 | #ifdef ICACHE_FLASH 94 | #define ICACHE_FLASH_ATTR __attribute__((section(".irom0.text"))) 95 | #define ICACHE_RODATA_ATTR __attribute__((section(".irom.text"))) 96 | #else 97 | #define ICACHE_FLASH_ATTR 98 | #endif /* ICACHE_FLASH */ 99 | 100 | #ifndef __cplusplus 101 | typedef unsigned char bool; 102 | #define BOOL bool 103 | #define true (1) 104 | #define false (0) 105 | #define TRUE true 106 | #define FALSE false 107 | 108 | 109 | #endif /* !__cplusplus */ 110 | 111 | #endif /* _C_TYPES_H_ */ 112 | -------------------------------------------------------------------------------- /include/ets_sys.h: -------------------------------------------------------------------------------- 1 | /* 2 | * copyright (c) 2008 - 2011 Espressif System 3 | * 4 | * Define user specified Event signals and Task priorities here 5 | * 6 | */ 7 | 8 | #ifndef _ETS_SYS_H 9 | #define _ETS_SYS_H 10 | 11 | #include "c_types.h" 12 | #include "eagle_soc.h" 13 | 14 | typedef uint32_t ETSSignal; 15 | typedef uint32_t ETSParam; 16 | 17 | typedef struct ETSEventTag ETSEvent; 18 | 19 | struct ETSEventTag { 20 | ETSSignal sig; 21 | ETSParam par; 22 | }; 23 | 24 | typedef void (*ETSTask)(ETSEvent *e); 25 | 26 | /* timer related */ 27 | typedef uint32_t ETSHandle; 28 | typedef void ETSTimerFunc(void *timer_arg); 29 | 30 | typedef struct _ETSTIMER_ { 31 | struct _ETSTIMER_ *timer_next; 32 | uint32_t timer_expire; 33 | uint32_t timer_period; 34 | ETSTimerFunc *timer_func; 35 | void *timer_arg; 36 | } ETSTimer; 37 | 38 | /* interrupt related */ 39 | #define ETS_SPI_INUM 2 40 | #define ETS_GPIO_INUM 4 41 | #define ETS_UART_INUM 5 42 | #define ETS_UART1_INUM 5 43 | #define ETS_FRC_TIMER1_INUM 9 /* use edge*/ 44 | 45 | #define ETS_INTR_LOCK() \ 46 | ets_intr_lock() 47 | 48 | #define ETS_INTR_UNLOCK() \ 49 | ets_intr_unlock() 50 | 51 | #define ETS_FRC_TIMER1_INTR_ATTACH(func, arg) \ 52 | ets_isr_attach(ETS_FRC_TIMER1_INUM, (func), (void *)(arg)) 53 | 54 | #define ETS_GPIO_INTR_ATTACH(func, arg) \ 55 | ets_isr_attach(ETS_GPIO_INUM, (func), (void *)(arg)) 56 | 57 | #define ETS_UART_INTR_ATTACH(func, arg) \ 58 | ets_isr_attach(ETS_UART_INUM, (func), (void *)(arg)) 59 | 60 | #define ETS_SPI_INTR_ATTACH(func, arg) \ 61 | ets_isr_attach(ETS_SPI_INUM, (func), (void *)(arg)) 62 | 63 | #define ETS_INTR_ENABLE(inum) \ 64 | ets_isr_unmask((1<= GPIO_ID_PIN0) && (reg_id <= GPIO_ID_PIN(GPIO_PIN_COUNT-1))) 13 | 14 | #define GPIO_REGID_TO_PINIDX(reg_id) ((reg_id) - GPIO_ID_PIN0) 15 | 16 | typedef enum { 17 | GPIO_PIN_INTR_DISABLE = 0, 18 | GPIO_PIN_INTR_POSEDGE = 1, 19 | GPIO_PIN_INTR_NEGEDGE = 2, 20 | GPIO_PIN_INTR_ANYEDGE = 3, 21 | GPIO_PIN_INTR_LOLEVEL = 4, 22 | GPIO_PIN_INTR_HILEVEL = 5 23 | } GPIO_INT_TYPE; 24 | 25 | #define GPIO_OUTPUT_SET(gpio_no, bit_value) \ 26 | gpio_output_set(bit_value<>gpio_no)&BIT0) 29 | 30 | /* GPIO interrupt handler, registered through gpio_intr_handler_register */ 31 | typedef void (* gpio_intr_handler_fn_t)(uint32 intr_mask, void *arg); 32 | 33 | 34 | /* 35 | * Initialize GPIO. This includes reading the GPIO Configuration DataSet 36 | * to initialize "output enables" and pin configurations for each gpio pin. 37 | * Must be called once during startup. 38 | */ 39 | void gpio_init(void); 40 | 41 | /* 42 | * Change GPIO pin output by setting, clearing, or disabling pins. 43 | * In general, it is expected that a bit will be set in at most one 44 | * of these masks. If a bit is clear in all masks, the output state 45 | * remains unchanged. 46 | * 47 | * There is no particular ordering guaranteed; so if the order of 48 | * writes is significant, calling code should divide a single call 49 | * into multiple calls. 50 | */ 51 | void gpio_output_set(uint32 set_mask, 52 | uint32 clear_mask, 53 | uint32 enable_mask, 54 | uint32 disable_mask); 55 | 56 | /* 57 | * Sample the value of GPIO input pins and returns a bitmask. 58 | */ 59 | uint32 gpio_input_get(void); 60 | 61 | /* 62 | * Set the specified GPIO register to the specified value. 63 | * This is a very general and powerful interface that is not 64 | * expected to be used during normal operation. It is intended 65 | * mainly for debug, or for unusual requirements. 66 | */ 67 | void gpio_register_set(uint32 reg_id, uint32 value); 68 | 69 | /* Get the current value of the specified GPIO register. */ 70 | uint32 gpio_register_get(uint32 reg_id); 71 | 72 | /* 73 | * Register an application-specific interrupt handler for GPIO pin 74 | * interrupts. Once the interrupt handler is called, it will not 75 | * be called again until after a call to gpio_intr_ack. Any GPIO 76 | * interrupts that occur during the interim are masked. 77 | * 78 | * The application-specific handler is called with a mask of 79 | * pending GPIO interrupts. After processing pin interrupts, the 80 | * application-specific handler may wish to use gpio_intr_pending 81 | * to check for any additional pending interrupts before it returns. 82 | */ 83 | void gpio_intr_handler_register(gpio_intr_handler_fn_t fn, void *arg); 84 | 85 | /* Determine which GPIO interrupts are pending. */ 86 | uint32 gpio_intr_pending(void); 87 | 88 | /* 89 | * Acknowledge GPIO interrupts. 90 | * Intended to be called from the gpio_intr_handler_fn. 91 | */ 92 | void gpio_intr_ack(uint32 ack_mask); 93 | 94 | void gpio_pin_wakeup_enable(uint32 i, GPIO_INT_TYPE intr_state); 95 | 96 | void gpio_pin_wakeup_disable(); 97 | 98 | void gpio_pin_intr_state_set(uint32 i, GPIO_INT_TYPE intr_state); 99 | 100 | #endif // _GPIO_H_ 101 | -------------------------------------------------------------------------------- /include/ip_addr.h: -------------------------------------------------------------------------------- 1 | /* 2 | * copyright (c) Espressif System 2010 3 | * 4 | * This file is part of Espressif IOT Software Development Kit. 5 | * Copyright (C) 2013 - 2016, Espressif Systems 6 | * Permission is hereby granted, free of charge, to any person obtaining a copy 7 | * of this software and associated documentation files (the "Software"), to deal 8 | * in the Software without restriction, including without limitation the rights 9 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | * copies of the Software, and to permit persons to whom the Software is 11 | * furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all 14 | * copies or substantial portions of the Software. 15 | * 16 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | * FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL THE 19 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 22 | * SOFTWARE. 23 | */ 24 | 25 | #ifndef __IP_ADDR_H__ 26 | #define __IP_ADDR_H__ 27 | 28 | #include "c_types.h" 29 | 30 | struct ip_addr { 31 | uint32 addr; 32 | }; 33 | 34 | typedef struct ip_addr ip_addr_t; 35 | 36 | struct ip_info { 37 | struct ip_addr ip; 38 | struct ip_addr netmask; 39 | struct ip_addr gw; 40 | }; 41 | 42 | #define IP4_ADDR(ipaddr, a,b,c,d) \ 43 | (ipaddr)->addr = ((uint32)((d) & 0xff) << 24) | \ 44 | ((uint32)((c) & 0xff) << 16) | \ 45 | ((uint32)((b) & 0xff) << 8) | \ 46 | (uint32)((a) & 0xff) 47 | 48 | /** 49 | * Determine if two address are on the same network. 50 | * 51 | * @arg addr1 IP address 1 52 | * @arg addr2 IP address 2 53 | * @arg mask network identifier mask 54 | * @return !0 if the network identifiers of both address match 55 | */ 56 | #define ip_addr_netcmp(addr1, addr2, mask) (((addr1)->addr & \ 57 | (mask)->addr) == \ 58 | ((addr2)->addr & \ 59 | (mask)->addr)) 60 | 61 | /** Set an IP address given by the four byte-parts. 62 | Little-endian version that prevents the use of htonl. */ 63 | #define IP4_ADDR(ipaddr, a,b,c,d) \ 64 | (ipaddr)->addr = ((uint32)((d) & 0xff) << 24) | \ 65 | ((uint32)((c) & 0xff) << 16) | \ 66 | ((uint32)((b) & 0xff) << 8) | \ 67 | (uint32)((a) & 0xff) 68 | 69 | #define ip4_addr1(ipaddr) (((uint8*)(ipaddr))[0]) 70 | #define ip4_addr2(ipaddr) (((uint8*)(ipaddr))[1]) 71 | #define ip4_addr3(ipaddr) (((uint8*)(ipaddr))[2]) 72 | #define ip4_addr4(ipaddr) (((uint8*)(ipaddr))[3]) 73 | 74 | #define ip4_addr1_16(ipaddr) ((uint16)ip4_addr1(ipaddr)) 75 | #define ip4_addr2_16(ipaddr) ((uint16)ip4_addr2(ipaddr)) 76 | #define ip4_addr3_16(ipaddr) ((uint16)ip4_addr3(ipaddr)) 77 | #define ip4_addr4_16(ipaddr) ((uint16)ip4_addr4(ipaddr)) 78 | 79 | 80 | /** 255.255.255.255 */ 81 | #define IPADDR_NONE ((uint32)0xffffffffUL) 82 | /** 0.0.0.0 */ 83 | #define IPADDR_ANY ((uint32)0x00000000UL) 84 | uint32 ipaddr_addr(const char *cp); 85 | 86 | #define IP2STR(ipaddr) ip4_addr1_16(ipaddr), \ 87 | ip4_addr2_16(ipaddr), \ 88 | ip4_addr3_16(ipaddr), \ 89 | ip4_addr4_16(ipaddr) 90 | 91 | #define IPSTR "%d.%d.%d.%d" 92 | 93 | #endif /* __IP_ADDR_H__ */ 94 | -------------------------------------------------------------------------------- /include/json/json.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2011-2012, Swedish Institute of Computer Science. 3 | * All rights reserved. 4 | * 5 | * Redistribution and use in source and binary forms, with or without 6 | * modification, are permitted provided that the following conditions 7 | * are met: 8 | * 1. Redistributions of source code must retain the above copyright 9 | * notice, this list of conditions and the following disclaimer. 10 | * 2. Redistributions in binary form must reproduce the above copyright 11 | * notice, this list of conditions and the following disclaimer in the 12 | * documentation and/or other materials provided with the distribution. 13 | * 3. Neither the name of the Institute nor the names of its contributors 14 | * may be used to endorse or promote products derived from this software 15 | * without specific prior written permission. 16 | * 17 | * THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND 18 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 19 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 20 | * ARE DISCLAIMED. IN NO EVENT SHALL THE INSTITUTE OR CONTRIBUTORS BE LIABLE 21 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 22 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 23 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 24 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 25 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 26 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 27 | * SUCH DAMAGE. 28 | * 29 | * This file is part of the Contiki operating system. 30 | */ 31 | 32 | /** 33 | * \file 34 | * A few JSON defines used for parsing and generating JSON. 35 | * \author 36 | * Niclas Finne 37 | * Joakim Eriksson 38 | */ 39 | 40 | #ifndef __JSON_H__ 41 | #define __JSON_H__ 42 | 43 | #define JSON_TYPE_ARRAY '[' 44 | #define JSON_TYPE_OBJECT '{' 45 | #define JSON_TYPE_PAIR ':' 46 | #define JSON_TYPE_PAIR_NAME 'N' /* for N:V pairs */ 47 | #define JSON_TYPE_STRING '"' 48 | #define JSON_TYPE_INT 'I' 49 | #define JSON_TYPE_NUMBER '0' 50 | #define JSON_TYPE_ERROR 0 51 | 52 | /* how should we handle null vs false - both can be 0? */ 53 | #define JSON_TYPE_NULL 'n' 54 | #define JSON_TYPE_TRUE 't' 55 | #define JSON_TYPE_FALSE 'f' 56 | 57 | #define JSON_TYPE_CALLBACK 'C' 58 | 59 | enum { 60 | JSON_ERROR_OK, 61 | JSON_ERROR_SYNTAX, 62 | JSON_ERROR_UNEXPECTED_ARRAY, 63 | JSON_ERROR_UNEXPECTED_END_OF_ARRAY, 64 | JSON_ERROR_UNEXPECTED_OBJECT, 65 | JSON_ERROR_UNEXPECTED_STRING 66 | }; 67 | 68 | #define JSON_CONTENT_TYPE "application/json" 69 | 70 | #endif /* __JSON_H__ */ 71 | -------------------------------------------------------------------------------- /include/json/jsonparse.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2011-2012, Swedish Institute of Computer Science. 3 | * All rights reserved. 4 | * 5 | * Redistribution and use in source and binary forms, with or without 6 | * modification, are permitted provided that the following conditions 7 | * are met: 8 | * 1. Redistributions of source code must retain the above copyright 9 | * notice, this list of conditions and the following disclaimer. 10 | * 2. Redistributions in binary form must reproduce the above copyright 11 | * notice, this list of conditions and the following disclaimer in the 12 | * documentation and/or other materials provided with the distribution. 13 | * 3. Neither the name of the Institute nor the names of its contributors 14 | * may be used to endorse or promote products derived from this software 15 | * without specific prior written permission. 16 | * 17 | * THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND 18 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 19 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 20 | * ARE DISCLAIMED. IN NO EVENT SHALL THE INSTITUTE OR CONTRIBUTORS BE LIABLE 21 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 22 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 23 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 24 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 25 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 26 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 27 | * SUCH DAMAGE. 28 | * 29 | * This file is part of the Contiki operating system. 30 | */ 31 | 32 | #ifndef __JSONPARSE_H__ 33 | #define __JSONPARSE_H__ 34 | 35 | #include "c_types.h" 36 | #include "json/json.h" 37 | 38 | #ifdef JSONPARSE_CONF_MAX_DEPTH 39 | #define JSONPARSE_MAX_DEPTH JSONPARSE_CONF_MAX_DEPTH 40 | #else 41 | #define JSONPARSE_MAX_DEPTH 10 42 | #endif 43 | 44 | struct jsonparse_state { 45 | const char *json; 46 | int pos; 47 | int len; 48 | int depth; 49 | /* for handling atomic values */ 50 | int vstart; 51 | int vlen; 52 | char vtype; 53 | char error; 54 | char stack[JSONPARSE_MAX_DEPTH]; 55 | }; 56 | 57 | /** 58 | * \brief Initialize a JSON parser state. 59 | * \param state A pointer to a JSON parser state 60 | * \param json The string to parse as JSON 61 | * \param len The length of the string to parse 62 | * 63 | * This function initializes a JSON parser state for 64 | * parsing a string as JSON. 65 | */ 66 | void jsonparse_setup(struct jsonparse_state *state, const char *json, 67 | int len); 68 | 69 | /* move to next JSON element */ 70 | int jsonparse_next(struct jsonparse_state *state); 71 | 72 | /* copy the current JSON value into the specified buffer */ 73 | int jsonparse_copy_value(struct jsonparse_state *state, char *buf, 74 | int buf_size); 75 | 76 | /* get the current JSON value parsed as an int */ 77 | int jsonparse_get_value_as_int(struct jsonparse_state *state); 78 | 79 | /* get the current JSON value parsed as a long */ 80 | long jsonparse_get_value_as_long(struct jsonparse_state *state); 81 | 82 | /* get the current JSON value parsed as a unsigned long */ 83 | unsigned long jsonparse_get_value_as_ulong(struct jsonparse_state *state); 84 | 85 | /* get the length of the current JSON value */ 86 | int jsonparse_get_len(struct jsonparse_state *state); 87 | 88 | /* get the type of the current JSON value */ 89 | int jsonparse_get_type(struct jsonparse_state *state); 90 | 91 | /* compare the JSON value with the specified string */ 92 | int jsonparse_strcmp_value(struct jsonparse_state *state, const char *str); 93 | 94 | #endif /* __JSONPARSE_H__ */ 95 | -------------------------------------------------------------------------------- /include/mem.h: -------------------------------------------------------------------------------- 1 | /* 2 | * copyright (c) Espressif System 2010 3 | * 4 | * This file is part of Espressif IOT Software Development Kit. 5 | * Copyright (C) 2013 - 2016, Espressif Systems 6 | * Permission is hereby granted, free of charge, to any person obtaining a copy 7 | * of this software and associated documentation files (the "Software"), to deal 8 | * in the Software without restriction, including without limitation the rights 9 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | * copies of the Software, and to permit persons to whom the Software is 11 | * furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all 14 | * copies or substantial portions of the Software. 15 | * 16 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | * FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL THE 19 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 22 | * SOFTWARE. 23 | */ 24 | 25 | #ifndef __MEM_H__ 26 | #define __MEM_H__ 27 | 28 | //void *pvPortMalloc( size_t xWantedSize ); 29 | //void vPortFree( void *pv ); 30 | //void *pvPortZalloc(size_t size); 31 | 32 | #define os_malloc pvPortMalloc 33 | #define os_free vPortFree 34 | #define os_zalloc pvPortZalloc 35 | 36 | #endif 37 | -------------------------------------------------------------------------------- /include/os_type.h: -------------------------------------------------------------------------------- 1 | /* 2 | * copyright (c) Espressif System 2010 3 | * 4 | * This file is part of Espressif IOT Software Development Kit. 5 | * Copyright (C) 2013 - 2016, Espressif Systems 6 | * Permission is hereby granted, free of charge, to any person obtaining a copy 7 | * of this software and associated documentation files (the "Software"), to deal 8 | * in the Software without restriction, including without limitation the rights 9 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | * copies of the Software, and to permit persons to whom the Software is 11 | * furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all 14 | * copies or substantial portions of the Software. 15 | * 16 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | * FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL THE 19 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 22 | * SOFTWARE. 23 | */ 24 | 25 | 26 | #ifndef _OS_TYPES_H_ 27 | #define _OS_TYPES_H_ 28 | 29 | #include "ets_sys.h" 30 | 31 | #define os_signal_t ETSSignal 32 | #define os_param_t ETSParam 33 | #define os_event_t ETSEvent 34 | #define os_task_t ETSTask 35 | #define os_timer_t ETSTimer 36 | #define os_timer_func_t ETSTimerFunc 37 | 38 | #endif 39 | -------------------------------------------------------------------------------- /include/osapi.h: -------------------------------------------------------------------------------- 1 | /* 2 | * copyright (c) Espressif System 2010 3 | * 4 | * This file is part of Espressif IOT Software Development Kit. 5 | * Copyright (C) 2013 - 2016, Espressif Systems 6 | * Permission is hereby granted, free of charge, to any person obtaining a copy 7 | * of this software and associated documentation files (the "Software"), to deal 8 | * in the Software without restriction, including without limitation the rights 9 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | * copies of the Software, and to permit persons to whom the Software is 11 | * furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all 14 | * copies or substantial portions of the Software. 15 | * 16 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | * FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL THE 19 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 22 | * SOFTWARE. 23 | */ 24 | 25 | #ifndef _OSAPI_H_ 26 | #define _OSAPI_H_ 27 | 28 | #include 29 | #include "user_config.h" 30 | 31 | #define os_bzero ets_bzero 32 | #define os_delay_us ets_delay_us 33 | #define os_install_putc1 ets_install_putc1 34 | #define os_install_putc2 ets_install_putc2 35 | #define os_intr_lock ets_intr_lock 36 | #define os_intr_unlock ets_intr_unlock 37 | #define os_isr_attach ets_isr_attach 38 | #define os_isr_mask ets_isr_mask 39 | #define os_isr_unmask ets_isr_unmask 40 | #define os_memcmp ets_memcmp 41 | #define os_memcpy ets_memcpy 42 | #define os_memmove ets_memmove 43 | #define os_memset ets_memset 44 | #define os_putc ets_putc 45 | #define os_str2macaddr ets_str2macaddr 46 | #define os_strcat strcat 47 | #define os_strchr strchr 48 | #define os_strcmp ets_strcmp 49 | #define os_strcpy ets_strcpy 50 | #define os_strlen ets_strlen 51 | #define os_strncmp ets_strncmp 52 | #define os_strncpy ets_strncpy 53 | #define os_strstr ets_strstr 54 | #ifdef USE_US_TIMER 55 | #define os_timer_arm_us(a, b, c) ets_timer_arm_new(a, b, c, 0) 56 | #endif 57 | #define os_timer_arm(a, b, c) ets_timer_arm_new(a, b, c, 1) 58 | #define os_timer_disarm ets_timer_disarm 59 | #define os_timer_done ets_timer_done 60 | #define os_timer_handler_isr ets_timer_handler_isr 61 | #define os_timer_init ets_timer_init 62 | #define os_timer_setfn ets_timer_setfn 63 | 64 | #define os_sprintf ets_sprintf 65 | #define os_update_cpu_frequency ets_update_cpu_frequency 66 | 67 | #ifdef USE_OPTIMIZE_PRINTF 68 | #define os_printf(fmt, ...) do { \ 69 | static const char flash_str[] ICACHE_RODATA_ATTR = fmt; \ 70 | os_printf_plus(flash_str, ##__VA_ARGS__); \ 71 | } while(0) 72 | #else 73 | #define os_printf os_printf_plus 74 | #endif 75 | 76 | #endif 77 | 78 | -------------------------------------------------------------------------------- /include/ping.h: -------------------------------------------------------------------------------- 1 | /* 2 | * copyright (c) Espressif System 2010 3 | * 4 | * This file is part of Espressif IOT Software Development Kit. 5 | * Copyright (C) 2013 - 2016, Espressif Systems 6 | * Permission is hereby granted, free of charge, to any person obtaining a copy 7 | * of this software and associated documentation files (the "Software"), to deal 8 | * in the Software without restriction, including without limitation the rights 9 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | * copies of the Software, and to permit persons to whom the Software is 11 | * furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all 14 | * copies or substantial portions of the Software. 15 | * 16 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | * FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL THE 19 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 22 | * SOFTWARE. 23 | */ 24 | 25 | #ifndef __PING_H__ 26 | #define __PING_H__ 27 | 28 | 29 | typedef void (* ping_recv_function)(void* arg, void *pdata); 30 | typedef void (* ping_sent_function)(void* arg, void *pdata); 31 | 32 | struct ping_option{ 33 | uint32 count; 34 | uint32 ip; 35 | uint32 coarse_time; 36 | ping_recv_function recv_function; 37 | ping_sent_function sent_function; 38 | void* reverse; 39 | }; 40 | 41 | struct ping_resp{ 42 | uint32 total_count; 43 | uint32 resp_time; 44 | uint32 seqno; 45 | uint32 timeout_count; 46 | uint32 bytes; 47 | uint32 total_bytes; 48 | uint32 total_time; 49 | sint8 ping_err; 50 | }; 51 | 52 | bool ping_start(struct ping_option *ping_opt); 53 | bool ping_regist_recv(struct ping_option *ping_opt, ping_recv_function ping_recv); 54 | bool ping_regist_sent(struct ping_option *ping_opt, ping_sent_function ping_sent); 55 | 56 | #endif /* __PING_H__ */ 57 | -------------------------------------------------------------------------------- /include/smartconfig.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2015 -2018 Espressif System 3 | * 4 | */ 5 | 6 | #ifndef __SMARTCONFIG_H__ 7 | #define __SMARTCONFIG_H__ 8 | 9 | typedef void (*sc_callback_t)(void *data); 10 | 11 | typedef enum { 12 | SC_STATUS_WAIT = 0, 13 | SC_STATUS_FIND_CHANNEL, 14 | SC_STATUS_GETTING_SSID_PSWD, 15 | SC_STATUS_GOT_SSID_PSWD, 16 | SC_STATUS_LINK, 17 | SC_STATUS_LINK_OVER, 18 | } sc_status; 19 | 20 | typedef enum { 21 | SC_TYPE_ESPTOUCH = 0, 22 | SC_TYPE_AIRKISS, 23 | } sc_type; 24 | 25 | sc_status smartconfig_get_status(void); 26 | const char *smartconfig_get_version(void); 27 | bool smartconfig_start(sc_type type, sc_callback_t cb, ...); 28 | bool smartconfig_stop(void); 29 | 30 | #endif 31 | -------------------------------------------------------------------------------- /include/spi_flash.h: -------------------------------------------------------------------------------- 1 | /* 2 | * copyright (c) Espressif System 2010 3 | * 4 | * This file is part of Espressif IOT Software Development Kit. 5 | * Copyright (C) 2013 - 2016, Espressif Systems 6 | * Permission is hereby granted, free of charge, to any person obtaining a copy 7 | * of this software and associated documentation files (the "Software"), to deal 8 | * in the Software without restriction, including without limitation the rights 9 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | * copies of the Software, and to permit persons to whom the Software is 11 | * furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all 14 | * copies or substantial portions of the Software. 15 | * 16 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | * FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL THE 19 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 22 | * SOFTWARE. 23 | */ 24 | 25 | #ifndef SPI_FLASH_H 26 | #define SPI_FLASH_H 27 | 28 | typedef enum { 29 | SPI_FLASH_RESULT_OK, 30 | SPI_FLASH_RESULT_ERR, 31 | SPI_FLASH_RESULT_TIMEOUT 32 | } SpiFlashOpResult; 33 | 34 | typedef struct{ 35 | uint32 deviceId; 36 | uint32 chip_size; // chip size in byte 37 | uint32 block_size; 38 | uint32 sector_size; 39 | uint32 page_size; 40 | uint32 status_mask; 41 | } SpiFlashChip; 42 | 43 | #define SPI_FLASH_SEC_SIZE 4096 44 | 45 | uint32 spi_flash_get_id(void); 46 | SpiFlashOpResult spi_flash_erase_sector(uint16 sec); 47 | SpiFlashOpResult spi_flash_write(uint32 des_addr, uint32 *src_addr, uint32 size); 48 | SpiFlashOpResult spi_flash_read(uint32 src_addr, uint32 *des_addr, uint32 size); 49 | 50 | #endif 51 | -------------------------------------------------------------------------------- /include/upgrade.h: -------------------------------------------------------------------------------- 1 | /* 2 | * copyright (c) Espressif System 2010 3 | * 4 | * This file is part of Espressif IOT Software Development Kit. 5 | * Copyright (C) 2013 - 2016, Espressif Systems 6 | * Permission is hereby granted, free of charge, to any person obtaining a copy 7 | * of this software and associated documentation files (the "Software"), to deal 8 | * in the Software without restriction, including without limitation the rights 9 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | * copies of the Software, and to permit persons to whom the Software is 11 | * furnished to do so, subject to the following conditions: 12 | * 13 | * The above copyright notice and this permission notice shall be included in all 14 | * copies or substantial portions of the Software. 15 | * 16 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | * FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL THE 19 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 22 | * SOFTWARE. 23 | */ 24 | 25 | #ifndef __UPGRADE_H__ 26 | #define __UPGRADE_H__ 27 | 28 | #define SPI_FLASH_SEC_SIZE 4096 29 | 30 | #define USER_BIN1 0x00 31 | #define USER_BIN2 0x01 32 | 33 | #define UPGRADE_FLAG_IDLE 0x00 34 | #define UPGRADE_FLAG_START 0x01 35 | #define UPGRADE_FLAG_FINISH 0x02 36 | 37 | #define UPGRADE_FW_BIN1 0x00 38 | #define UPGRADE_FW_BIN2 0x01 39 | 40 | typedef void (*upgrade_states_check_callback)(void * arg); 41 | 42 | //#define UPGRADE_SSL_ENABLE 43 | 44 | struct upgrade_server_info { 45 | uint8 ip[4]; 46 | uint16 port; 47 | 48 | uint8 upgrade_flag; 49 | 50 | uint8 pre_version[16]; 51 | uint8 upgrade_version[16]; 52 | 53 | uint32 check_times; 54 | uint8 *url; 55 | 56 | upgrade_states_check_callback check_cb; 57 | struct espconn *pespconn; 58 | }; 59 | 60 | #define UPGRADE_FLAG_IDLE 0x00 61 | #define UPGRADE_FLAG_START 0x01 62 | #define UPGRADE_FLAG_FINISH 0x02 63 | 64 | //bool system_upgrade_start(struct upgrade_server_info *server); 65 | bool system_upgrade_start_ssl(struct upgrade_server_info *server); 66 | void system_upgrade_init(); 67 | void system_upgrade_deinit(); 68 | bool system_upgrade(uint8 *data, uint16 len); 69 | 70 | #ifdef UPGRADE_SSL_ENABLE 71 | bool system_upgrade_start_ssl(struct upgrade_server_info *server); 72 | #else 73 | bool system_upgrade_start(struct upgrade_server_info *server); 74 | #endif 75 | #endif 76 | -------------------------------------------------------------------------------- /ld/eagle.app.v6.ld: -------------------------------------------------------------------------------- 1 | /* This linker script generated from xt-genldscripts.tpp for LSP . */ 2 | /* Linker Script for ld -N */ 3 | MEMORY 4 | { 5 | dport0_0_seg : org = 0x3FF00000, len = 0x10 6 | dram0_0_seg : org = 0x3FFE8000, len = 0x14000 7 | iram1_0_seg : org = 0x40100000, len = 0x8000 8 | irom0_0_seg : org = 0x40240000, len = 0x32000 9 | } 10 | 11 | PHDRS 12 | { 13 | dport0_0_phdr PT_LOAD; 14 | dram0_0_phdr PT_LOAD; 15 | dram0_0_bss_phdr PT_LOAD; 16 | iram1_0_phdr PT_LOAD; 17 | irom0_0_phdr PT_LOAD; 18 | } 19 | 20 | 21 | /* Default entry point: */ 22 | ENTRY(call_user_start) 23 | PROVIDE(_memmap_vecbase_reset = 0x40000000); 24 | /* Various memory-map dependent cache attribute settings: */ 25 | _memmap_cacheattr_wb_base = 0x00000110; 26 | _memmap_cacheattr_wt_base = 0x00000110; 27 | _memmap_cacheattr_bp_base = 0x00000220; 28 | _memmap_cacheattr_unused_mask = 0xFFFFF00F; 29 | _memmap_cacheattr_wb_trapnull = 0x2222211F; 30 | _memmap_cacheattr_wba_trapnull = 0x2222211F; 31 | _memmap_cacheattr_wbna_trapnull = 0x2222211F; 32 | _memmap_cacheattr_wt_trapnull = 0x2222211F; 33 | _memmap_cacheattr_bp_trapnull = 0x2222222F; 34 | _memmap_cacheattr_wb_strict = 0xFFFFF11F; 35 | _memmap_cacheattr_wt_strict = 0xFFFFF11F; 36 | _memmap_cacheattr_bp_strict = 0xFFFFF22F; 37 | _memmap_cacheattr_wb_allvalid = 0x22222112; 38 | _memmap_cacheattr_wt_allvalid = 0x22222112; 39 | _memmap_cacheattr_bp_allvalid = 0x22222222; 40 | PROVIDE(_memmap_cacheattr_reset = _memmap_cacheattr_wb_trapnull); 41 | 42 | SECTIONS 43 | { 44 | 45 | .dport0.rodata : ALIGN(4) 46 | { 47 | _dport0_rodata_start = ABSOLUTE(.); 48 | *(.dport0.rodata) 49 | *(.dport.rodata) 50 | _dport0_rodata_end = ABSOLUTE(.); 51 | } >dport0_0_seg :dport0_0_phdr 52 | 53 | .dport0.literal : ALIGN(4) 54 | { 55 | _dport0_literal_start = ABSOLUTE(.); 56 | *(.dport0.literal) 57 | *(.dport.literal) 58 | _dport0_literal_end = ABSOLUTE(.); 59 | } >dport0_0_seg :dport0_0_phdr 60 | 61 | .dport0.data : ALIGN(4) 62 | { 63 | _dport0_data_start = ABSOLUTE(.); 64 | *(.dport0.data) 65 | *(.dport.data) 66 | _dport0_data_end = ABSOLUTE(.); 67 | } >dport0_0_seg :dport0_0_phdr 68 | 69 | .data : ALIGN(4) 70 | { 71 | _data_start = ABSOLUTE(.); 72 | *(.data) 73 | *(.data.*) 74 | *(.gnu.linkonce.d.*) 75 | *(.data1) 76 | *(.sdata) 77 | *(.sdata.*) 78 | *(.gnu.linkonce.s.*) 79 | *(.sdata2) 80 | *(.sdata2.*) 81 | *(.gnu.linkonce.s2.*) 82 | *(.jcr) 83 | _data_end = ABSOLUTE(.); 84 | } >dram0_0_seg :dram0_0_phdr 85 | 86 | .rodata : ALIGN(4) 87 | { 88 | _rodata_start = ABSOLUTE(.); 89 | *(.rodata) 90 | *(.rodata.*) 91 | *(.gnu.linkonce.r.*) 92 | *(.rodata1) 93 | __XT_EXCEPTION_TABLE__ = ABSOLUTE(.); 94 | *(.xt_except_table) 95 | *(.gcc_except_table) 96 | *(.gnu.linkonce.e.*) 97 | *(.gnu.version_r) 98 | *(.eh_frame) 99 | /* C++ constructor and destructor tables, properly ordered: */ 100 | KEEP (*crtbegin.o(.ctors)) 101 | KEEP (*(EXCLUDE_FILE (*crtend.o) .ctors)) 102 | KEEP (*(SORT(.ctors.*))) 103 | KEEP (*(.ctors)) 104 | KEEP (*crtbegin.o(.dtors)) 105 | KEEP (*(EXCLUDE_FILE (*crtend.o) .dtors)) 106 | KEEP (*(SORT(.dtors.*))) 107 | KEEP (*(.dtors)) 108 | /* C++ exception handlers table: */ 109 | __XT_EXCEPTION_DESCS__ = ABSOLUTE(.); 110 | *(.xt_except_desc) 111 | *(.gnu.linkonce.h.*) 112 | __XT_EXCEPTION_DESCS_END__ = ABSOLUTE(.); 113 | *(.xt_except_desc_end) 114 | *(.dynamic) 115 | *(.gnu.version_d) 116 | . = ALIGN(4); /* this table MUST be 4-byte aligned */ 117 | _bss_table_start = ABSOLUTE(.); 118 | LONG(_bss_start) 119 | LONG(_bss_end) 120 | _bss_table_end = ABSOLUTE(.); 121 | _rodata_end = ABSOLUTE(.); 122 | } >dram0_0_seg :dram0_0_phdr 123 | 124 | .bss ALIGN(8) (NOLOAD) : ALIGN(4) 125 | { 126 | . = ALIGN (8); 127 | _bss_start = ABSOLUTE(.); 128 | *(.dynsbss) 129 | *(.sbss) 130 | *(.sbss.*) 131 | *(.gnu.linkonce.sb.*) 132 | *(.scommon) 133 | *(.sbss2) 134 | *(.sbss2.*) 135 | *(.gnu.linkonce.sb2.*) 136 | *(.dynbss) 137 | *(.bss) 138 | *(.bss.*) 139 | *(.gnu.linkonce.b.*) 140 | *(COMMON) 141 | . = ALIGN (8); 142 | _bss_end = ABSOLUTE(.); 143 | _heap_start = ABSOLUTE(.); 144 | /* _stack_sentry = ALIGN(0x8); */ 145 | } >dram0_0_seg :dram0_0_bss_phdr 146 | /* __stack = 0x3ffc8000; */ 147 | 148 | .text : ALIGN(4) 149 | { 150 | _stext = .; 151 | _text_start = ABSOLUTE(.); 152 | *(.entry.text) 153 | *(.init.literal) 154 | *(.init) 155 | *(.literal .text .literal.* .text.* .stub .gnu.warning .gnu.linkonce.literal.* .gnu.linkonce.t.*.literal .gnu.linkonce.t.*) 156 | *(.fini.literal) 157 | *(.fini) 158 | *(.gnu.version) 159 | _text_end = ABSOLUTE(.); 160 | _etext = .; 161 | } >iram1_0_seg :iram1_0_phdr 162 | 163 | .lit4 : ALIGN(4) 164 | { 165 | _lit4_start = ABSOLUTE(.); 166 | *(*.lit4) 167 | *(.lit4.*) 168 | *(.gnu.linkonce.lit4.*) 169 | _lit4_end = ABSOLUTE(.); 170 | } >iram1_0_seg :iram1_0_phdr 171 | 172 | .irom0.text : ALIGN(4) 173 | { 174 | _irom0_text_start = ABSOLUTE(.); 175 | *(.irom0.literal .irom.literal .irom.text.literal .irom0.text .irom.text) 176 | _irom0_text_end = ABSOLUTE(.); 177 | } >irom0_0_seg :irom0_0_phdr 178 | } 179 | 180 | /* get ROM code address */ 181 | INCLUDE "../ld/eagle.rom.addr.v6.ld" 182 | -------------------------------------------------------------------------------- /ld/eagle.app.v6.new.1024.app1.ld: -------------------------------------------------------------------------------- 1 | /* This linker script generated from xt-genldscripts.tpp for LSP . */ 2 | /* Linker Script for ld -N */ 3 | MEMORY 4 | { 5 | dport0_0_seg : org = 0x3FF00000, len = 0x10 6 | dram0_0_seg : org = 0x3FFE8000, len = 0x14000 7 | iram1_0_seg : org = 0x40100000, len = 0x8000 8 | irom0_0_seg : org = 0x40201010, len = 0x6B000 9 | } 10 | 11 | PHDRS 12 | { 13 | dport0_0_phdr PT_LOAD; 14 | dram0_0_phdr PT_LOAD; 15 | dram0_0_bss_phdr PT_LOAD; 16 | iram1_0_phdr PT_LOAD; 17 | irom0_0_phdr PT_LOAD; 18 | } 19 | 20 | 21 | /* Default entry point: */ 22 | ENTRY(call_user_start) 23 | PROVIDE(_memmap_vecbase_reset = 0x40000000); 24 | /* Various memory-map dependent cache attribute settings: */ 25 | _memmap_cacheattr_wb_base = 0x00000110; 26 | _memmap_cacheattr_wt_base = 0x00000110; 27 | _memmap_cacheattr_bp_base = 0x00000220; 28 | _memmap_cacheattr_unused_mask = 0xFFFFF00F; 29 | _memmap_cacheattr_wb_trapnull = 0x2222211F; 30 | _memmap_cacheattr_wba_trapnull = 0x2222211F; 31 | _memmap_cacheattr_wbna_trapnull = 0x2222211F; 32 | _memmap_cacheattr_wt_trapnull = 0x2222211F; 33 | _memmap_cacheattr_bp_trapnull = 0x2222222F; 34 | _memmap_cacheattr_wb_strict = 0xFFFFF11F; 35 | _memmap_cacheattr_wt_strict = 0xFFFFF11F; 36 | _memmap_cacheattr_bp_strict = 0xFFFFF22F; 37 | _memmap_cacheattr_wb_allvalid = 0x22222112; 38 | _memmap_cacheattr_wt_allvalid = 0x22222112; 39 | _memmap_cacheattr_bp_allvalid = 0x22222222; 40 | PROVIDE(_memmap_cacheattr_reset = _memmap_cacheattr_wb_trapnull); 41 | 42 | SECTIONS 43 | { 44 | 45 | .dport0.rodata : ALIGN(4) 46 | { 47 | _dport0_rodata_start = ABSOLUTE(.); 48 | *(.dport0.rodata) 49 | *(.dport.rodata) 50 | _dport0_rodata_end = ABSOLUTE(.); 51 | } >dport0_0_seg :dport0_0_phdr 52 | 53 | .dport0.literal : ALIGN(4) 54 | { 55 | _dport0_literal_start = ABSOLUTE(.); 56 | *(.dport0.literal) 57 | *(.dport.literal) 58 | _dport0_literal_end = ABSOLUTE(.); 59 | } >dport0_0_seg :dport0_0_phdr 60 | 61 | .dport0.data : ALIGN(4) 62 | { 63 | _dport0_data_start = ABSOLUTE(.); 64 | *(.dport0.data) 65 | *(.dport.data) 66 | _dport0_data_end = ABSOLUTE(.); 67 | } >dport0_0_seg :dport0_0_phdr 68 | 69 | .data : ALIGN(4) 70 | { 71 | _data_start = ABSOLUTE(.); 72 | *(.data) 73 | *(.data.*) 74 | *(.gnu.linkonce.d.*) 75 | *(.data1) 76 | *(.sdata) 77 | *(.sdata.*) 78 | *(.gnu.linkonce.s.*) 79 | *(.sdata2) 80 | *(.sdata2.*) 81 | *(.gnu.linkonce.s2.*) 82 | *(.jcr) 83 | _data_end = ABSOLUTE(.); 84 | } >dram0_0_seg :dram0_0_phdr 85 | 86 | .rodata : ALIGN(4) 87 | { 88 | _rodata_start = ABSOLUTE(.); 89 | *(.rodata) 90 | *(.rodata.*) 91 | *(.gnu.linkonce.r.*) 92 | *(.rodata1) 93 | __XT_EXCEPTION_TABLE__ = ABSOLUTE(.); 94 | *(.xt_except_table) 95 | *(.gcc_except_table) 96 | *(.gnu.linkonce.e.*) 97 | *(.gnu.version_r) 98 | *(.eh_frame) 99 | /* C++ constructor and destructor tables, properly ordered: */ 100 | KEEP (*crtbegin.o(.ctors)) 101 | KEEP (*(EXCLUDE_FILE (*crtend.o) .ctors)) 102 | KEEP (*(SORT(.ctors.*))) 103 | KEEP (*(.ctors)) 104 | KEEP (*crtbegin.o(.dtors)) 105 | KEEP (*(EXCLUDE_FILE (*crtend.o) .dtors)) 106 | KEEP (*(SORT(.dtors.*))) 107 | KEEP (*(.dtors)) 108 | /* C++ exception handlers table: */ 109 | __XT_EXCEPTION_DESCS__ = ABSOLUTE(.); 110 | *(.xt_except_desc) 111 | *(.gnu.linkonce.h.*) 112 | __XT_EXCEPTION_DESCS_END__ = ABSOLUTE(.); 113 | *(.xt_except_desc_end) 114 | *(.dynamic) 115 | *(.gnu.version_d) 116 | . = ALIGN(4); /* this table MUST be 4-byte aligned */ 117 | _bss_table_start = ABSOLUTE(.); 118 | LONG(_bss_start) 119 | LONG(_bss_end) 120 | _bss_table_end = ABSOLUTE(.); 121 | _rodata_end = ABSOLUTE(.); 122 | } >dram0_0_seg :dram0_0_phdr 123 | 124 | .bss ALIGN(8) (NOLOAD) : ALIGN(4) 125 | { 126 | . = ALIGN (8); 127 | _bss_start = ABSOLUTE(.); 128 | *(.dynsbss) 129 | *(.sbss) 130 | *(.sbss.*) 131 | *(.gnu.linkonce.sb.*) 132 | *(.scommon) 133 | *(.sbss2) 134 | *(.sbss2.*) 135 | *(.gnu.linkonce.sb2.*) 136 | *(.dynbss) 137 | *(.bss) 138 | *(.bss.*) 139 | *(.gnu.linkonce.b.*) 140 | *(COMMON) 141 | . = ALIGN (8); 142 | _bss_end = ABSOLUTE(.); 143 | _heap_start = ABSOLUTE(.); 144 | /* _stack_sentry = ALIGN(0x8); */ 145 | } >dram0_0_seg :dram0_0_bss_phdr 146 | /* __stack = 0x3ffc8000; */ 147 | 148 | .text : ALIGN(4) 149 | { 150 | _stext = .; 151 | _text_start = ABSOLUTE(.); 152 | *(.entry.text) 153 | *(.init.literal) 154 | *(.init) 155 | *(.literal .text .literal.* .text.* .stub .gnu.warning .gnu.linkonce.literal.* .gnu.linkonce.t.*.literal .gnu.linkonce.t.*) 156 | *(.fini.literal) 157 | *(.fini) 158 | *(.gnu.version) 159 | _text_end = ABSOLUTE(.); 160 | _etext = .; 161 | } >iram1_0_seg :iram1_0_phdr 162 | 163 | .lit4 : ALIGN(4) 164 | { 165 | _lit4_start = ABSOLUTE(.); 166 | *(*.lit4) 167 | *(.lit4.*) 168 | *(.gnu.linkonce.lit4.*) 169 | _lit4_end = ABSOLUTE(.); 170 | } >iram1_0_seg :iram1_0_phdr 171 | 172 | .irom0.text : ALIGN(4) 173 | { 174 | _irom0_text_start = ABSOLUTE(.); 175 | *(.irom0.literal .irom.literal .irom.text.literal .irom0.text .irom.text) 176 | _irom0_text_end = ABSOLUTE(.); 177 | } >irom0_0_seg :irom0_0_phdr 178 | } 179 | 180 | /* get ROM code address */ 181 | INCLUDE "../ld/eagle.rom.addr.v6.ld" 182 | -------------------------------------------------------------------------------- /ld/eagle.app.v6.new.1024.app2.ld: -------------------------------------------------------------------------------- 1 | /* This linker script generated from xt-genldscripts.tpp for LSP . */ 2 | /* Linker Script for ld -N */ 3 | MEMORY 4 | { 5 | dport0_0_seg : org = 0x3FF00000, len = 0x10 6 | dram0_0_seg : org = 0x3FFE8000, len = 0x14000 7 | iram1_0_seg : org = 0x40100000, len = 0x8000 8 | irom0_0_seg : org = 0x40281010, len = 0x6B000 9 | } 10 | 11 | PHDRS 12 | { 13 | dport0_0_phdr PT_LOAD; 14 | dram0_0_phdr PT_LOAD; 15 | dram0_0_bss_phdr PT_LOAD; 16 | iram1_0_phdr PT_LOAD; 17 | irom0_0_phdr PT_LOAD; 18 | } 19 | 20 | 21 | /* Default entry point: */ 22 | ENTRY(call_user_start) 23 | PROVIDE(_memmap_vecbase_reset = 0x40000000); 24 | /* Various memory-map dependent cache attribute settings: */ 25 | _memmap_cacheattr_wb_base = 0x00000110; 26 | _memmap_cacheattr_wt_base = 0x00000110; 27 | _memmap_cacheattr_bp_base = 0x00000220; 28 | _memmap_cacheattr_unused_mask = 0xFFFFF00F; 29 | _memmap_cacheattr_wb_trapnull = 0x2222211F; 30 | _memmap_cacheattr_wba_trapnull = 0x2222211F; 31 | _memmap_cacheattr_wbna_trapnull = 0x2222211F; 32 | _memmap_cacheattr_wt_trapnull = 0x2222211F; 33 | _memmap_cacheattr_bp_trapnull = 0x2222222F; 34 | _memmap_cacheattr_wb_strict = 0xFFFFF11F; 35 | _memmap_cacheattr_wt_strict = 0xFFFFF11F; 36 | _memmap_cacheattr_bp_strict = 0xFFFFF22F; 37 | _memmap_cacheattr_wb_allvalid = 0x22222112; 38 | _memmap_cacheattr_wt_allvalid = 0x22222112; 39 | _memmap_cacheattr_bp_allvalid = 0x22222222; 40 | PROVIDE(_memmap_cacheattr_reset = _memmap_cacheattr_wb_trapnull); 41 | 42 | SECTIONS 43 | { 44 | 45 | .dport0.rodata : ALIGN(4) 46 | { 47 | _dport0_rodata_start = ABSOLUTE(.); 48 | *(.dport0.rodata) 49 | *(.dport.rodata) 50 | _dport0_rodata_end = ABSOLUTE(.); 51 | } >dport0_0_seg :dport0_0_phdr 52 | 53 | .dport0.literal : ALIGN(4) 54 | { 55 | _dport0_literal_start = ABSOLUTE(.); 56 | *(.dport0.literal) 57 | *(.dport.literal) 58 | _dport0_literal_end = ABSOLUTE(.); 59 | } >dport0_0_seg :dport0_0_phdr 60 | 61 | .dport0.data : ALIGN(4) 62 | { 63 | _dport0_data_start = ABSOLUTE(.); 64 | *(.dport0.data) 65 | *(.dport.data) 66 | _dport0_data_end = ABSOLUTE(.); 67 | } >dport0_0_seg :dport0_0_phdr 68 | 69 | .data : ALIGN(4) 70 | { 71 | _data_start = ABSOLUTE(.); 72 | *(.data) 73 | *(.data.*) 74 | *(.gnu.linkonce.d.*) 75 | *(.data1) 76 | *(.sdata) 77 | *(.sdata.*) 78 | *(.gnu.linkonce.s.*) 79 | *(.sdata2) 80 | *(.sdata2.*) 81 | *(.gnu.linkonce.s2.*) 82 | *(.jcr) 83 | _data_end = ABSOLUTE(.); 84 | } >dram0_0_seg :dram0_0_phdr 85 | 86 | .rodata : ALIGN(4) 87 | { 88 | _rodata_start = ABSOLUTE(.); 89 | *(.rodata) 90 | *(.rodata.*) 91 | *(.gnu.linkonce.r.*) 92 | *(.rodata1) 93 | __XT_EXCEPTION_TABLE__ = ABSOLUTE(.); 94 | *(.xt_except_table) 95 | *(.gcc_except_table) 96 | *(.gnu.linkonce.e.*) 97 | *(.gnu.version_r) 98 | *(.eh_frame) 99 | /* C++ constructor and destructor tables, properly ordered: */ 100 | KEEP (*crtbegin.o(.ctors)) 101 | KEEP (*(EXCLUDE_FILE (*crtend.o) .ctors)) 102 | KEEP (*(SORT(.ctors.*))) 103 | KEEP (*(.ctors)) 104 | KEEP (*crtbegin.o(.dtors)) 105 | KEEP (*(EXCLUDE_FILE (*crtend.o) .dtors)) 106 | KEEP (*(SORT(.dtors.*))) 107 | KEEP (*(.dtors)) 108 | /* C++ exception handlers table: */ 109 | __XT_EXCEPTION_DESCS__ = ABSOLUTE(.); 110 | *(.xt_except_desc) 111 | *(.gnu.linkonce.h.*) 112 | __XT_EXCEPTION_DESCS_END__ = ABSOLUTE(.); 113 | *(.xt_except_desc_end) 114 | *(.dynamic) 115 | *(.gnu.version_d) 116 | . = ALIGN(4); /* this table MUST be 4-byte aligned */ 117 | _bss_table_start = ABSOLUTE(.); 118 | LONG(_bss_start) 119 | LONG(_bss_end) 120 | _bss_table_end = ABSOLUTE(.); 121 | _rodata_end = ABSOLUTE(.); 122 | } >dram0_0_seg :dram0_0_phdr 123 | 124 | .bss ALIGN(8) (NOLOAD) : ALIGN(4) 125 | { 126 | . = ALIGN (8); 127 | _bss_start = ABSOLUTE(.); 128 | *(.dynsbss) 129 | *(.sbss) 130 | *(.sbss.*) 131 | *(.gnu.linkonce.sb.*) 132 | *(.scommon) 133 | *(.sbss2) 134 | *(.sbss2.*) 135 | *(.gnu.linkonce.sb2.*) 136 | *(.dynbss) 137 | *(.bss) 138 | *(.bss.*) 139 | *(.gnu.linkonce.b.*) 140 | *(COMMON) 141 | . = ALIGN (8); 142 | _bss_end = ABSOLUTE(.); 143 | _heap_start = ABSOLUTE(.); 144 | /* _stack_sentry = ALIGN(0x8); */ 145 | } >dram0_0_seg :dram0_0_bss_phdr 146 | /* __stack = 0x3ffc8000; */ 147 | 148 | .text : ALIGN(4) 149 | { 150 | _stext = .; 151 | _text_start = ABSOLUTE(.); 152 | *(.entry.text) 153 | *(.init.literal) 154 | *(.init) 155 | *(.literal .text .literal.* .text.* .stub .gnu.warning .gnu.linkonce.literal.* .gnu.linkonce.t.*.literal .gnu.linkonce.t.*) 156 | *(.fini.literal) 157 | *(.fini) 158 | *(.gnu.version) 159 | _text_end = ABSOLUTE(.); 160 | _etext = .; 161 | } >iram1_0_seg :iram1_0_phdr 162 | 163 | .lit4 : ALIGN(4) 164 | { 165 | _lit4_start = ABSOLUTE(.); 166 | *(*.lit4) 167 | *(.lit4.*) 168 | *(.gnu.linkonce.lit4.*) 169 | _lit4_end = ABSOLUTE(.); 170 | } >iram1_0_seg :iram1_0_phdr 171 | 172 | .irom0.text : ALIGN(4) 173 | { 174 | _irom0_text_start = ABSOLUTE(.); 175 | *(.irom0.literal .irom.literal .irom.text.literal .irom0.text .irom.text) 176 | _irom0_text_end = ABSOLUTE(.); 177 | } >irom0_0_seg :irom0_0_phdr 178 | } 179 | 180 | /* get ROM code address */ 181 | INCLUDE "../ld/eagle.rom.addr.v6.ld" 182 | -------------------------------------------------------------------------------- /ld/eagle.app.v6.new.512.app1.ld: -------------------------------------------------------------------------------- 1 | /* This linker script generated from xt-genldscripts.tpp for LSP . */ 2 | /* Linker Script for ld -N */ 3 | MEMORY 4 | { 5 | dport0_0_seg : org = 0x3FF00000, len = 0x10 6 | dram0_0_seg : org = 0x3FFE8000, len = 0x14000 7 | iram1_0_seg : org = 0x40100000, len = 0x8000 8 | irom0_0_seg : org = 0x40201010, len = 0x2B000 9 | } 10 | 11 | PHDRS 12 | { 13 | dport0_0_phdr PT_LOAD; 14 | dram0_0_phdr PT_LOAD; 15 | dram0_0_bss_phdr PT_LOAD; 16 | iram1_0_phdr PT_LOAD; 17 | irom0_0_phdr PT_LOAD; 18 | } 19 | 20 | 21 | /* Default entry point: */ 22 | ENTRY(call_user_start) 23 | PROVIDE(_memmap_vecbase_reset = 0x40000000); 24 | /* Various memory-map dependent cache attribute settings: */ 25 | _memmap_cacheattr_wb_base = 0x00000110; 26 | _memmap_cacheattr_wt_base = 0x00000110; 27 | _memmap_cacheattr_bp_base = 0x00000220; 28 | _memmap_cacheattr_unused_mask = 0xFFFFF00F; 29 | _memmap_cacheattr_wb_trapnull = 0x2222211F; 30 | _memmap_cacheattr_wba_trapnull = 0x2222211F; 31 | _memmap_cacheattr_wbna_trapnull = 0x2222211F; 32 | _memmap_cacheattr_wt_trapnull = 0x2222211F; 33 | _memmap_cacheattr_bp_trapnull = 0x2222222F; 34 | _memmap_cacheattr_wb_strict = 0xFFFFF11F; 35 | _memmap_cacheattr_wt_strict = 0xFFFFF11F; 36 | _memmap_cacheattr_bp_strict = 0xFFFFF22F; 37 | _memmap_cacheattr_wb_allvalid = 0x22222112; 38 | _memmap_cacheattr_wt_allvalid = 0x22222112; 39 | _memmap_cacheattr_bp_allvalid = 0x22222222; 40 | PROVIDE(_memmap_cacheattr_reset = _memmap_cacheattr_wb_trapnull); 41 | 42 | SECTIONS 43 | { 44 | 45 | .dport0.rodata : ALIGN(4) 46 | { 47 | _dport0_rodata_start = ABSOLUTE(.); 48 | *(.dport0.rodata) 49 | *(.dport.rodata) 50 | _dport0_rodata_end = ABSOLUTE(.); 51 | } >dport0_0_seg :dport0_0_phdr 52 | 53 | .dport0.literal : ALIGN(4) 54 | { 55 | _dport0_literal_start = ABSOLUTE(.); 56 | *(.dport0.literal) 57 | *(.dport.literal) 58 | _dport0_literal_end = ABSOLUTE(.); 59 | } >dport0_0_seg :dport0_0_phdr 60 | 61 | .dport0.data : ALIGN(4) 62 | { 63 | _dport0_data_start = ABSOLUTE(.); 64 | *(.dport0.data) 65 | *(.dport.data) 66 | _dport0_data_end = ABSOLUTE(.); 67 | } >dport0_0_seg :dport0_0_phdr 68 | 69 | .data : ALIGN(4) 70 | { 71 | _data_start = ABSOLUTE(.); 72 | *(.data) 73 | *(.data.*) 74 | *(.gnu.linkonce.d.*) 75 | *(.data1) 76 | *(.sdata) 77 | *(.sdata.*) 78 | *(.gnu.linkonce.s.*) 79 | *(.sdata2) 80 | *(.sdata2.*) 81 | *(.gnu.linkonce.s2.*) 82 | *(.jcr) 83 | _data_end = ABSOLUTE(.); 84 | } >dram0_0_seg :dram0_0_phdr 85 | 86 | .rodata : ALIGN(4) 87 | { 88 | _rodata_start = ABSOLUTE(.); 89 | *(.rodata) 90 | *(.rodata.*) 91 | *(.gnu.linkonce.r.*) 92 | *(.rodata1) 93 | __XT_EXCEPTION_TABLE__ = ABSOLUTE(.); 94 | *(.xt_except_table) 95 | *(.gcc_except_table) 96 | *(.gnu.linkonce.e.*) 97 | *(.gnu.version_r) 98 | *(.eh_frame) 99 | /* C++ constructor and destructor tables, properly ordered: */ 100 | KEEP (*crtbegin.o(.ctors)) 101 | KEEP (*(EXCLUDE_FILE (*crtend.o) .ctors)) 102 | KEEP (*(SORT(.ctors.*))) 103 | KEEP (*(.ctors)) 104 | KEEP (*crtbegin.o(.dtors)) 105 | KEEP (*(EXCLUDE_FILE (*crtend.o) .dtors)) 106 | KEEP (*(SORT(.dtors.*))) 107 | KEEP (*(.dtors)) 108 | /* C++ exception handlers table: */ 109 | __XT_EXCEPTION_DESCS__ = ABSOLUTE(.); 110 | *(.xt_except_desc) 111 | *(.gnu.linkonce.h.*) 112 | __XT_EXCEPTION_DESCS_END__ = ABSOLUTE(.); 113 | *(.xt_except_desc_end) 114 | *(.dynamic) 115 | *(.gnu.version_d) 116 | . = ALIGN(4); /* this table MUST be 4-byte aligned */ 117 | _bss_table_start = ABSOLUTE(.); 118 | LONG(_bss_start) 119 | LONG(_bss_end) 120 | _bss_table_end = ABSOLUTE(.); 121 | _rodata_end = ABSOLUTE(.); 122 | } >dram0_0_seg :dram0_0_phdr 123 | 124 | .bss ALIGN(8) (NOLOAD) : ALIGN(4) 125 | { 126 | . = ALIGN (8); 127 | _bss_start = ABSOLUTE(.); 128 | *(.dynsbss) 129 | *(.sbss) 130 | *(.sbss.*) 131 | *(.gnu.linkonce.sb.*) 132 | *(.scommon) 133 | *(.sbss2) 134 | *(.sbss2.*) 135 | *(.gnu.linkonce.sb2.*) 136 | *(.dynbss) 137 | *(.bss) 138 | *(.bss.*) 139 | *(.gnu.linkonce.b.*) 140 | *(COMMON) 141 | . = ALIGN (8); 142 | _bss_end = ABSOLUTE(.); 143 | _heap_start = ABSOLUTE(.); 144 | /* _stack_sentry = ALIGN(0x8); */ 145 | } >dram0_0_seg :dram0_0_bss_phdr 146 | /* __stack = 0x3ffc8000; */ 147 | 148 | .text : ALIGN(4) 149 | { 150 | _stext = .; 151 | _text_start = ABSOLUTE(.); 152 | *(.entry.text) 153 | *(.init.literal) 154 | *(.init) 155 | *(.literal .text .literal.* .text.* .stub .gnu.warning .gnu.linkonce.literal.* .gnu.linkonce.t.*.literal .gnu.linkonce.t.*) 156 | *(.fini.literal) 157 | *(.fini) 158 | *(.gnu.version) 159 | _text_end = ABSOLUTE(.); 160 | _etext = .; 161 | } >iram1_0_seg :iram1_0_phdr 162 | 163 | .lit4 : ALIGN(4) 164 | { 165 | _lit4_start = ABSOLUTE(.); 166 | *(*.lit4) 167 | *(.lit4.*) 168 | *(.gnu.linkonce.lit4.*) 169 | _lit4_end = ABSOLUTE(.); 170 | } >iram1_0_seg :iram1_0_phdr 171 | 172 | .irom0.text : ALIGN(4) 173 | { 174 | _irom0_text_start = ABSOLUTE(.); 175 | *(.irom0.literal .irom.literal .irom.text.literal .irom0.text .irom.text) 176 | _irom0_text_end = ABSOLUTE(.); 177 | } >irom0_0_seg :irom0_0_phdr 178 | } 179 | 180 | /* get ROM code address */ 181 | INCLUDE "../ld/eagle.rom.addr.v6.ld" 182 | -------------------------------------------------------------------------------- /ld/eagle.app.v6.new.512.app2.ld: -------------------------------------------------------------------------------- 1 | /* This linker script generated from xt-genldscripts.tpp for LSP . */ 2 | /* Linker Script for ld -N */ 3 | MEMORY 4 | { 5 | dport0_0_seg : org = 0x3FF00000, len = 0x10 6 | dram0_0_seg : org = 0x3FFE8000, len = 0x14000 7 | iram1_0_seg : org = 0x40100000, len = 0x8000 8 | irom0_0_seg : org = 0x40241010, len = 0x2B000 9 | } 10 | 11 | PHDRS 12 | { 13 | dport0_0_phdr PT_LOAD; 14 | dram0_0_phdr PT_LOAD; 15 | dram0_0_bss_phdr PT_LOAD; 16 | iram1_0_phdr PT_LOAD; 17 | irom0_0_phdr PT_LOAD; 18 | } 19 | 20 | 21 | /* Default entry point: */ 22 | ENTRY(call_user_start) 23 | PROVIDE(_memmap_vecbase_reset = 0x40000000); 24 | /* Various memory-map dependent cache attribute settings: */ 25 | _memmap_cacheattr_wb_base = 0x00000110; 26 | _memmap_cacheattr_wt_base = 0x00000110; 27 | _memmap_cacheattr_bp_base = 0x00000220; 28 | _memmap_cacheattr_unused_mask = 0xFFFFF00F; 29 | _memmap_cacheattr_wb_trapnull = 0x2222211F; 30 | _memmap_cacheattr_wba_trapnull = 0x2222211F; 31 | _memmap_cacheattr_wbna_trapnull = 0x2222211F; 32 | _memmap_cacheattr_wt_trapnull = 0x2222211F; 33 | _memmap_cacheattr_bp_trapnull = 0x2222222F; 34 | _memmap_cacheattr_wb_strict = 0xFFFFF11F; 35 | _memmap_cacheattr_wt_strict = 0xFFFFF11F; 36 | _memmap_cacheattr_bp_strict = 0xFFFFF22F; 37 | _memmap_cacheattr_wb_allvalid = 0x22222112; 38 | _memmap_cacheattr_wt_allvalid = 0x22222112; 39 | _memmap_cacheattr_bp_allvalid = 0x22222222; 40 | PROVIDE(_memmap_cacheattr_reset = _memmap_cacheattr_wb_trapnull); 41 | 42 | SECTIONS 43 | { 44 | 45 | .dport0.rodata : ALIGN(4) 46 | { 47 | _dport0_rodata_start = ABSOLUTE(.); 48 | *(.dport0.rodata) 49 | *(.dport.rodata) 50 | _dport0_rodata_end = ABSOLUTE(.); 51 | } >dport0_0_seg :dport0_0_phdr 52 | 53 | .dport0.literal : ALIGN(4) 54 | { 55 | _dport0_literal_start = ABSOLUTE(.); 56 | *(.dport0.literal) 57 | *(.dport.literal) 58 | _dport0_literal_end = ABSOLUTE(.); 59 | } >dport0_0_seg :dport0_0_phdr 60 | 61 | .dport0.data : ALIGN(4) 62 | { 63 | _dport0_data_start = ABSOLUTE(.); 64 | *(.dport0.data) 65 | *(.dport.data) 66 | _dport0_data_end = ABSOLUTE(.); 67 | } >dport0_0_seg :dport0_0_phdr 68 | 69 | .data : ALIGN(4) 70 | { 71 | _data_start = ABSOLUTE(.); 72 | *(.data) 73 | *(.data.*) 74 | *(.gnu.linkonce.d.*) 75 | *(.data1) 76 | *(.sdata) 77 | *(.sdata.*) 78 | *(.gnu.linkonce.s.*) 79 | *(.sdata2) 80 | *(.sdata2.*) 81 | *(.gnu.linkonce.s2.*) 82 | *(.jcr) 83 | _data_end = ABSOLUTE(.); 84 | } >dram0_0_seg :dram0_0_phdr 85 | 86 | .rodata : ALIGN(4) 87 | { 88 | _rodata_start = ABSOLUTE(.); 89 | *(.rodata) 90 | *(.rodata.*) 91 | *(.gnu.linkonce.r.*) 92 | *(.rodata1) 93 | __XT_EXCEPTION_TABLE__ = ABSOLUTE(.); 94 | *(.xt_except_table) 95 | *(.gcc_except_table) 96 | *(.gnu.linkonce.e.*) 97 | *(.gnu.version_r) 98 | *(.eh_frame) 99 | /* C++ constructor and destructor tables, properly ordered: */ 100 | KEEP (*crtbegin.o(.ctors)) 101 | KEEP (*(EXCLUDE_FILE (*crtend.o) .ctors)) 102 | KEEP (*(SORT(.ctors.*))) 103 | KEEP (*(.ctors)) 104 | KEEP (*crtbegin.o(.dtors)) 105 | KEEP (*(EXCLUDE_FILE (*crtend.o) .dtors)) 106 | KEEP (*(SORT(.dtors.*))) 107 | KEEP (*(.dtors)) 108 | /* C++ exception handlers table: */ 109 | __XT_EXCEPTION_DESCS__ = ABSOLUTE(.); 110 | *(.xt_except_desc) 111 | *(.gnu.linkonce.h.*) 112 | __XT_EXCEPTION_DESCS_END__ = ABSOLUTE(.); 113 | *(.xt_except_desc_end) 114 | *(.dynamic) 115 | *(.gnu.version_d) 116 | . = ALIGN(4); /* this table MUST be 4-byte aligned */ 117 | _bss_table_start = ABSOLUTE(.); 118 | LONG(_bss_start) 119 | LONG(_bss_end) 120 | _bss_table_end = ABSOLUTE(.); 121 | _rodata_end = ABSOLUTE(.); 122 | } >dram0_0_seg :dram0_0_phdr 123 | 124 | .bss ALIGN(8) (NOLOAD) : ALIGN(4) 125 | { 126 | . = ALIGN (8); 127 | _bss_start = ABSOLUTE(.); 128 | *(.dynsbss) 129 | *(.sbss) 130 | *(.sbss.*) 131 | *(.gnu.linkonce.sb.*) 132 | *(.scommon) 133 | *(.sbss2) 134 | *(.sbss2.*) 135 | *(.gnu.linkonce.sb2.*) 136 | *(.dynbss) 137 | *(.bss) 138 | *(.bss.*) 139 | *(.gnu.linkonce.b.*) 140 | *(COMMON) 141 | . = ALIGN (8); 142 | _bss_end = ABSOLUTE(.); 143 | _heap_start = ABSOLUTE(.); 144 | /* _stack_sentry = ALIGN(0x8); */ 145 | } >dram0_0_seg :dram0_0_bss_phdr 146 | /* __stack = 0x3ffc8000; */ 147 | 148 | .text : ALIGN(4) 149 | { 150 | _stext = .; 151 | _text_start = ABSOLUTE(.); 152 | *(.entry.text) 153 | *(.init.literal) 154 | *(.init) 155 | *(.literal .text .literal.* .text.* .stub .gnu.warning .gnu.linkonce.literal.* .gnu.linkonce.t.*.literal .gnu.linkonce.t.*) 156 | *(.fini.literal) 157 | *(.fini) 158 | *(.gnu.version) 159 | _text_end = ABSOLUTE(.); 160 | _etext = .; 161 | } >iram1_0_seg :iram1_0_phdr 162 | 163 | .lit4 : ALIGN(4) 164 | { 165 | _lit4_start = ABSOLUTE(.); 166 | *(*.lit4) 167 | *(.lit4.*) 168 | *(.gnu.linkonce.lit4.*) 169 | _lit4_end = ABSOLUTE(.); 170 | } >iram1_0_seg :iram1_0_phdr 171 | 172 | .irom0.text : ALIGN(4) 173 | { 174 | _irom0_text_start = ABSOLUTE(.); 175 | *(.irom0.literal .irom.literal .irom.text.literal .irom0.text .irom.text) 176 | _irom0_text_end = ABSOLUTE(.); 177 | } >irom0_0_seg :irom0_0_phdr 178 | } 179 | 180 | /* get ROM code address */ 181 | INCLUDE "../ld/eagle.rom.addr.v6.ld" 182 | -------------------------------------------------------------------------------- /lib/lib.rar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/lib/lib.rar -------------------------------------------------------------------------------- /lib/libat.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/lib/libat.a -------------------------------------------------------------------------------- /lib/libjson.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/lib/libjson.a -------------------------------------------------------------------------------- /lib/liblwip.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/lib/liblwip.a -------------------------------------------------------------------------------- /lib/libmain.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/lib/libmain.a -------------------------------------------------------------------------------- /lib/libmain.rar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/lib/libmain.rar -------------------------------------------------------------------------------- /lib/libmain_lowpowermode.rar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/lib/libmain_lowpowermode.rar -------------------------------------------------------------------------------- /lib/libnet80211.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/lib/libnet80211.a -------------------------------------------------------------------------------- /lib/libphy.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/lib/libphy.a -------------------------------------------------------------------------------- /lib/libphy.rar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/lib/libphy.rar -------------------------------------------------------------------------------- /lib/libpp.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/lib/libpp.a -------------------------------------------------------------------------------- /lib/libsmartconfig.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/lib/libsmartconfig.a -------------------------------------------------------------------------------- /lib/libssl.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/lib/libssl.a -------------------------------------------------------------------------------- /lib/libupgrade.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/lib/libupgrade.a -------------------------------------------------------------------------------- /lib/libwpa.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/EspressifSystems/low_power_voltage_measurement/5f517ef1cf346746f348f02d7dd6ac8623063bfb/lib/libwpa.a -------------------------------------------------------------------------------- /readme.txt: -------------------------------------------------------------------------------- 1 | low power sensor demo: 2 | 3 | 1.put these file to sdk root path 4 | 2.compile: support flash.bin+rom.bin and bootv1.1.bin+user.bin 5 | 3.download: 6 | eagle.flash_disable_rf.bin -> 0x0 7 | eagle.irom0text.bin -> 0x40000 8 | esp_init_data_vdd33.bin -> 0x7c000 9 | blank.bin -> 0x7e000 10 | device_master_key -> 0x3e000 11 | 12 | or: 13 | user1.512.old_disable_rf.bin ->0x1000 14 | bootv1.1.bin -> 0x0 15 | blank.bin -> 0x7e000 16 | device_master_key -> 0x3e000 17 | esp_init_data_vdd33.bin -> 0x7c000 18 | 19 | 20 | -------------------------------------------------------------------------------- /scripts/get_sensor_voltage.py: -------------------------------------------------------------------------------- 1 | 2 | import datetime 3 | import time 4 | import os 5 | import binascii 6 | import string 7 | import httplib 8 | import urllib2 9 | import json 10 | 11 | DATETIME_FORMAT = '%Y%m%d-%H-%M-%S' 12 | now = datetime.datetime.now() 13 | dir_datetime = now.strftime(DATETIME_FORMAT) 14 | 15 | 16 | def get_test_data(devCnt=10,key='4f5bbb332f838b33cd6211a11bde561f06858c78',start='',end='',offset=0,data_stream="supply_voltage",data_num_in_set=20): 17 | devices_count =devCnt 18 | devKey = key 19 | start_time = start 20 | end_time = end 21 | offset = offset 22 | data_stream = data_stream 23 | 24 | host = 'iot.espressif.cn' 25 | headers = {'Host': host, 'User-Agent': 'Mozilla', 'Accept': '*/*', 'Authorization': 'token %s' % devKey} 26 | params=None 27 | if start_time=='': 28 | path = '/v1/datastreams/%s/datapoints/?row_count=%d' % (data_stream, devices_count ) 29 | elif offset == 0: 30 | path = '/v1/datastreams/%s/datapoints/?row_count=%d&start=%s&end=%s' % (data_stream, devices_count, start_time, end_time) 31 | else: 32 | path = '/v1/datastreams/%s/datapoints/?row_count=%d&start=%s&end=%s&offset=%d' % (data_stream, devices_count, start_time, end_time, offset) 33 | conn = httplib.HTTPConnection(host, port=80) 34 | conn.request("GET", path, params, headers) 35 | response = conn.getresponse() 36 | data = response.read() 37 | conn.close() 38 | 39 | total_data_dict = json.loads(data) 40 | time_list=[] 41 | idx_list = [] 42 | val_data_list = [] 43 | 44 | for dict_tmp in total_data_dict["datapoints"]: 45 | time_list.append( dict_tmp["updated"] ) 46 | idx_list.append( dict_tmp['x']) 47 | val_data_list.append( dict_tmp['y']) 48 | time_cal_list = [ str(datetime.datetime.strptime(time_list[i],'%Y-%m-%d %H:%M:%S') - datetime.timedelta(minutes=((data_num_in_set-1)-idx_list[i]))) for i in range(len(val_data_list))] 49 | voltage_list = [ i*1.0/1024 for i in val_data_list] 50 | time_cal_list.reverse() 51 | voltage_list.reverse() 52 | print time_cal_list 53 | print voltage_list 54 | 55 | 56 | 57 | 58 | if __name__ == '__main__': 59 | #devCnt : data num (<1000) 60 | #key: sensor devkey 61 | #start: data start time 62 | #end : data end time 63 | #offset: data page offset , (if data num exceed 1000: offset++) 64 | #data_stream : data_stream name on the server 65 | #key = '4f5bbb332f838b33cd6211a11bde561f06858c78' #device 66 | #key = '976f39a53c354de37e58f527c232c92b8f67ad12' #owner 67 | #key = 'e50d9d278b6953ff761db08ec37d3de09cb81577' #madcowmoomoo 68 | key = open('../bin/key.bin','r').readline().replace('\xFF','') 69 | print key 70 | get_test_data(devCnt=100, 71 | key=key, 72 | start='2015-03-15 00:00:00', 73 | end=dir_datetime, 74 | offset=1, 75 | data_num_in_set = 20, #data number uploaded one time 76 | data_stream="supply-voltage") 77 | 78 | 79 | -------------------------------------------------------------------------------- /scripts/plot_sensor_voltage.py: -------------------------------------------------------------------------------- 1 | 2 | import datetime 3 | import time 4 | import os 5 | import binascii 6 | import string 7 | import httplib 8 | import urllib2 9 | import json 10 | import matplotlib.pyplot as plt 11 | import numpy as np 12 | 13 | DATETIME_FORMAT = '%Y%m%d-%H-%M-%S' 14 | now = datetime.datetime.now() 15 | dir_datetime = now.strftime(DATETIME_FORMAT) 16 | 17 | 18 | def get_test_data(key='26484cd14129a0c64ed1bf9608fec6cabb0fd0c9',start='',end='',offset=0, datastream='supply-voltage'): 19 | voltage_list = [] 20 | time_cal_list = [] 21 | end_tmp = end 22 | while True: 23 | [t,v] = get_test_data_sub(devCnt=1000,key=key,start=start,end=end_tmp,offset=offset,datastream=datastream) 24 | time_cal_list.extend(t) 25 | voltage_list.extend(v) 26 | if len(t)==0: break 27 | if not time_cal_list[-1]>datetime.datetime.strptime(start, '%Y-%m-%d %H:%M:%S'): break 28 | end_tmp = t[-1] 29 | 30 | #for i in range(len(voltage_list)-1): 31 | # if voltage_list[i]