{"id":24708243,"url":"https://github.com/clementlecorre/esp8266-temperaturesensor","last_synced_at":"2026-04-13T17:04:26.529Z","repository":{"id":104873000,"uuid":"110842310","full_name":"clementlecorre/ESP8266-temperatureSensor","owner":"clementlecorre","description":"Temperature sensor Micropython on wireless ESP8266","archived":false,"fork":false,"pushed_at":"2019-03-13T20:56:46.000Z","size":5818,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-01-27T06:32:36.199Z","etag":null,"topics":["dht11","ds18b20","esp8266","micropython","python","python3"],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/clementlecorre.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-11-15T14:14:07.000Z","updated_at":"2019-03-13T20:56:47.000Z","dependencies_parsed_at":null,"dependency_job_id":"5902195c-356f-4555-b9bd-6ac585fd91cf","html_url":"https://github.com/clementlecorre/ESP8266-temperatureSensor","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/clementlecorre%2FESP8266-temperatureSensor","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/clementlecorre%2FESP8266-temperatureSensor/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/clementlecorre%2FESP8266-temperatureSensor/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/clementlecorre%2FESP8266-temperatureSensor/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/clementlecorre","download_url":"https://codeload.github.com/clementlecorre/ESP8266-temperatureSensor/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244913330,"owners_count":20530817,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["dht11","ds18b20","esp8266","micropython","python","python3"],"created_at":"2025-01-27T06:29:06.675Z","updated_at":"2026-04-13T17:04:26.488Z","avatar_url":"https://github.com/clementlecorre.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ESP8266-temperatureSensor\n\nTested On macOS High Sierra\n\n## Init your ESP8266\n\n[Datasheet ESP8266](https://cdn-learn.adafruit.com/assets/assets/000/046/211/original/Huzzah_ESP8266_Pinout_v1.2.pdf?1504807178)\n\n* Requirement\n    * Download micropython [esp8266-20171101-v1.9.3.bin](https://micropython.org/download)\n    * Download SLAB_USBtoUART driver [USB to UART Bridge Virtual COM Port (VCP)](https://www.silabs.com/products/development-tools/software/usb-to-uart-bridge-vcp-drivers)\n    * Clone github repo [themadinventor/sptool](https://github.com/themadinventor/esptool)\n    * Clone github repo [micropython/webrepl](https://github.com/micropython/webrepl)\n    * brew install picocom\n    * pip install esptool\n\nPlug USB to ESP8266\n\n![Step 1](screenshot/step_1.JPG)\n\n\n```\n$ python3 esptool.py --port /dev/cu.SLAB_USBtoUART erase_flash\nesptool.py v2.2\nConnecting........_\nDetecting chip type... ESP8266\nChip is ESP8266EX\nUploading stub...\nRunning stub...\nStub running...\nErasing flash (this may take a while)...\nChip erase completed successfully in 7.9s\nHard resetting...\n\n```\n```\n$ python3 esptool.py --port /dev/cu.SLAB_USBtoUART write_flash --flash_size=detect 0 esp8266-20171101-v1.9.3.bin\nesptool.py v2.2\nConnecting........_\nDetecting chip type... ESP8266\nChip is ESP8266EX\nUploading stub...\nRunning stub...\nStub running...\nConfiguring flash size...\nAuto-detected Flash size: 4MB\nFlash params set to 0x0040\nCompressed 600888 bytes to 392073...\nWrote 600888 bytes (392073 compressed) at 0x00000000 in 34.6 seconds (effective 138.7 kbit/s)...\nHash of data verified.\n\nLeaving...\nHard resetting...\n```\n\nESP8266 restarts automatically after flash\n\nYou must see your device appear in your wifi ! (default password is **micropythoN**)\n\nTry to connect\n\n\n![Step 2](screenshot/step_2.png)\n\n## Setup your ESP8266\n\nFor the first configuration, it is necessary to connect via USB\n\n\n```\n$ picocom /dev/cu.SLAB_USBtoUART -b115200\npicocom v3.1\n\nport is        : /dev/cu.SLAB_USBtoUART\nflowcontrol    : none\nbaudrate is    : 115200\nparity is      : none\ndatabits are   : 8\nstopbits are   : 1\nescape is      : C-a\nlocal echo is  : no\nnoinit is      : no\nnoreset is     : no\nhangup is      : no\nnolock is      : no\nsend_cmd is    : sz -vv\nreceive_cmd is : rz -vv -E\nimap is        :\nomap is        :\nemap is        : crcrlf,delbs,\nlogfile is     : none\ninitstring     : none\nexit_after is  : not set\nexit is        : no\n\nType [C-a] [C-h] to see available commands\nTerminal ready\n\n\u003e\u003e\u003e import webrepl_setup\nWebREPL daemon auto-start status: disabled\n\nWould you like to (E)nable or (D)isable it running on boot?\n(Empty line to quit)\n\u003e E\nTo enable WebREPL, you must set password for it\nNew password (4-9 chars): Ohx1ThaoJ\nConfirm password: Ohx1ThaoJ\nChanges will be activated after reboot\nWould you like to reboot now? (y/n) y\n\n```\n\nESP8266 restarts automatically after setup\n\nNow you can access the device via web socket (WebREPL daemon started on ws://192.168.4.1:8266)\n## Assembly\n\n[Datasheet ESP8266](https://cdn-learn.adafruit.com/assets/assets/000/046/211/original/Huzzah_ESP8266_Pinout_v1.2.pdf?1504807178)\n\nDS18B20 DATA : PIN 4\n\nDS18B20 GND (-) : GND\n\nDS18B20 3.3v (+) : 3.3v\n\nRESET : RST TO PIN 16\n\n![Step 3](screenshot/step_3.JPG)\n\n![Step 3-1](screenshot/step_3-1.JPG)\n\n## Upload code\n\nYou must be connect to micropython wifi\n\n### Ui method\n\nUse `webrepl.html` file in micropython/webrepl repo\n\n![Step 4](screenshot/step_4.png)\n\n### Command line method\n\nUse `webrepl_cli.py` file in micropython/webrepl repo\n\n```\n$ ./webrepl_cli.py -p Ohx1ThaoJ ~/mygit/ESP8266-temperatureSensor/DS18B20/main.py 192.168.4.1:/\nop:put, host:192.168.4.1, port:8266, passwd:Ohx1ThaoJ.\n/Users/clement/mygit/ESP8266-temperatureSensor/DS18B20/main.py -\u003e /main.py\nRemote WebREPL version: (1, 9, 3)\nSent 2836 of 2836 bytes\n```\n\n**Be careful** the code here contains a sleep, n this case the wifi sometimes in standby. It will have to be taken into account during the test.\n\nTips: Log in via picocom (USB) and interrupt the program via ctrl+C.\n\n## Grafana\n\nYou can add a grafana dashboard to view the data\n\n![Step final](screenshot/step_final.png)\n\n## Helping\n\n```\nControl commands:\n  CTRL-A        -- on a blank line, enter raw REPL mode\n  CTRL-B        -- on a blank line, enter normal REPL mode\n  CTRL-C        -- interrupt a running program\n  CTRL-D        -- on a blank line, do a soft reset of the board\n  CTRL-E        -- on a blank line, enter paste mode\n\nFor further help on a specific object, type help(obj)\n```\n\n### Manage files\n\n```\n\u003e\u003e\u003e import os\n\u003e\u003e\u003e os.remove('main.1.py')\n\u003e\u003e\u003e os.listdir()\n['boot.py', 'webrepl_cfg.py', 'main.py']\n\u003e\u003e\u003e\n\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fclementlecorre%2Fesp8266-temperaturesensor","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fclementlecorre%2Fesp8266-temperaturesensor","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fclementlecorre%2Fesp8266-temperaturesensor/lists"}