Cov txheej txheem:

Pheej Yig Qhov Chaw Nkag Nkag Pheej Yig Pheej Yig: 6 Kauj Ruam (nrog Duab)
Pheej Yig Qhov Chaw Nkag Nkag Pheej Yig Pheej Yig: 6 Kauj Ruam (nrog Duab)

Video: Pheej Yig Qhov Chaw Nkag Nkag Pheej Yig Pheej Yig: 6 Kauj Ruam (nrog Duab)

Video: Pheej Yig Qhov Chaw Nkag Nkag Pheej Yig Pheej Yig: 6 Kauj Ruam (nrog Duab)
Video: Zoo Siab Nrog Koj - Paj Tsua Thoj [ Official MV ] Nkauj Tawm Tshiab 2022 2024, Kaum ib hlis
Anonim
Image
Image

Credit

Kuv zoo nkauj tau theej Savjee qhov kev siv tab sis tsis txhob siv Shelly Kuv siv Sonoff Basic. Tshawb xyuas nws lub vev xaib thiab YouTube Channel!

www.savjee.be 2020/06/make-garage-door-ope…

www.youtube.com/c/Savjee/

Kev xav

  • Koj muaj Lub Tsev Pabcuam piv txwv khiav thiab koj paub siv nws li cas
  • Koj muaj ESPHome piv txwv khiav thiab koj paub siv nws li cas

Khoom siv

Sonoff Basic-https://www.amazon.com/Sonoff-Remote-Control-Comp…

Hu rau Sensor -

USB Rau Serial -

Tshav Kub Kub -

Soldering Iron -

Kub Shrink Tubing -

Hlau -

Tes Tsho Hlau -

Dupont Cables -

Software:

Tus Pab Tsev -

ESPhome -

ESP Yooj Yim -

Kauj Ruam 1: Hloov Kho Sonoff RF R2 Fais Fab

Hloov kho Sonoff RF R2 Fais Fab
Hloov kho Sonoff RF R2 Fais Fab
Hloov kho Sonoff RF R2 Fais Fab
Hloov kho Sonoff RF R2 Fais Fab
Hloov kho Sonoff RF R2 Fais Fab
Hloov kho Sonoff RF R2 Fais Fab

DISCLAIMER

Kuv tsis yog kws kho hluav taws xob thiab tsis ua txuj ua si hauv internet. Yog tias koj txiav txim siab hloov kho Sonoff Basic koj tab tom ua ntawm koj tus kheej txoj kev pheej hmoo. Nov yog qhov kuv tau hloov kho kuv li Sonoff Basic tab sis tsis pom zoo kom koj ua ib yam. Kuv kuj tsis hais txog tias kuv ua nws raug lossis raug nyab xeeb.

Pib

Csongor Varga ua rau lub ntsiab lus zoo hauv nws cov vis dis aus txog nws tsis muaj kev nyab xeeb los hloov kho qhov Sonoff no ib yam li cov ntawv dhau los los ntawm kev txiav cov kab. Saib ntxiv ntawm no. Cov kab txuas txuas rau kev xa tawm thiab txuas txuas rau lub fuse uas muab lub zog rau lub tshuab hluav taws xob nyob ze dhau los ua txoj hauv kev txiav kab. Kuv tau txais qhov no los ntawm kev tshem tawm feem ntau ntawm cov kab thiab txav lub fuse.

  1. Nrhiav lub fuse uas muab lub zog rau lub tshuab hluav taws xob
  2. Qhov chaw nyob qhov twg cov xov hlau tsis zoo nyob rau hauv lub qhov nkag
  3. Desolder lub fuse, tshem tawm, thiab tso tseg
  4. Desolder cov xov hlau nruab nrab ntawm qhov nkag thiab tshem tawm
  5. Txiav tawm kab raws li pom hauv daim duab ntawm qib tsib
  6. Txiav tawm ib qho thais raws li pom hauv daim duab ntawm kauj ruam 6
  7. Solder lub fuse txoj kev rov qab koj tau coj nws tawm thiab txuas qhov kawg ntev rau kab nkag
  8. Seem cov xov hlau nruab nrab thiab muab nws txuas rau lub rooj tsavxwm raws li pom hauv daim duab ntawm kauj ruam 8

Kauj Ruam 2: ESPHome - Tsim Software

Hloov mus teeb tsa tus xa xov. Qhov no yuav yog sab hauv kom nws tsis cuam tshuam ncaj qha rau Tsev Pabcuam.

hloov:

- platform: gpio pin: 12 id: relay_1 lub npe: "sonoff_basic_4_switch" sab hauv: muaj tseeb Peb yuav xav tau lub ntsuas cua binary rau lub ntsuas kev sib cuag uas yuav qhia rau peb yog lub qhov rooj qhov rooj kaw lossis qhib

binary_sensor:

- platform: gpio tus pin: tus lej: 3 hom: INPUT_PULLUP lub npe: "Qhov Rooj Qhov Rooj Tiv Thaiv Sensor" id: contact_sensor sab hauv: lim tiag: qeeb_on_off: 500ms Peb tuaj yeem teeb tsa lub pob ntawm Sonoff txhawm rau hloov qhov kev xa tawm

- lub platform: gpio

id: button_0 tus pin: tus lej: 0 inverted: Hom tseeb: INPUT_PULLUP on_click: tom qab ntawd: - switch.turn_on: relay_1 - ncua: 500ms - switch.turn_off: relay_1 Thaum kawg, npog nrog tus cwj pwm tso tsheb

npog:

- platform: template device_class: lub tsev rau khoom lub npe: "Qhov Rooj Qhov Rooj" id: template_cov lambda: |- yog (id (contact_sensor).state) {rov qab COVER_OPEN; } lwm {xa COVER_CLOSED; } open_action: - switch.turn_on: relay_1 - ncua: 0.5s - switch.turn_off: relay_1 close_action: - switch.turn_on: relay_1 - ncua: 0.5s - switch.turn_off: relay_1 Nov yog tag nrho YAML

wifi:

ssid: password: manual_ip: static_ip: gateway: subnet: dns1: dns2: # Enable fallback hotspot (captive portal) nyob rau hauv rooj plaub wifi txuas tsis ua ap: ssid: password: captive_portal: # Pab kom nkag tau logger: # Pab kom Lub Tsev Pabcuam API api: ota: hloov chaw: # Hloov kho qhov hloov pauv raws li koj qhov chaw hostname: 'sonoff_basic_4' esphome: name: $ hostname platform: ESP8266 board: esp01_1m board_flash_mode: dout status_led: pin: number: 13 inverted: True binary_sensor: - platform: gpio pin: number: 3 hom: INPUT_PULLUP lub npe: "Lub Nkoj Qhov Rooj Hu Xov Tooj Sensor" id: contact_sensor sab hauv: lim tiag: ncua_on_off: 500ms - platform: gpio id: button_0 tus pin: tus lej: 0 inverted: Hom tseeb: INPUT_PULLUP on_click: tom qab: - switch.turn_on: relay_1 - ncua: 500ms - switch.turn_off: relay_1 hloov: - platform: gpio pin: 12 id: relay_1 lub npe: "sonoff_basic_4_switch" sab hauv: npog qhov tseeb: - platform: template device_class: chav tso npe: "Qhov Rooj Qhov Rooj" id: template_cov lambda: |- yog (id (contact_sensor).state) {retu rn COVER_OPEN; } lwm {xa COVER_CLOSED; } open_action: - switch.turn_on: relay_1 - ncua: 0.5s - switch.turn_off: relay_1 close_action: - switch.turn_on: relay_1 - ncua: 0.5s - switch.turn_off: relay_1 sensor: - platform: wifi_signal lub npe: "sonoff_basic_4_wifi_signal" update_interval: 60s - platform: uptime name: "sonoff_basic_4_up_time" text_sensor: - platform: version version: "sonoff_basic_4_version"

Kauj Ruam 3: ESPEasy - Ua kom lub Sonoff Basic

ESPEasy - Ua rau Sonoff Basic yooj yim
ESPEasy - Ua rau Sonoff Basic yooj yim
ESPEasy - Ua rau Sonoff Basic yooj yim
ESPEasy - Ua rau Sonoff Basic yooj yim
ESPEasy - Ua rau Sonoff Basic yooj yim
ESPEasy - Ua rau Sonoff Basic yooj yim

Koj yuav xav tau USB rau txuas txuas rau qhov no.

  • RX ntawm tus lej txuas mus rau TX ntawm Sonoff
  • TX ntawm qhov txuas txuas mus rau RX ntawm Sonoff
  1. Hauv ESPHome sau cov cai
  2. Download tau lub binary
  3. Luam cov ntaub ntawv.bin rau koj phau ESPEasy
  4. Txuas koj cov xov tooj txuas mus rau Sonoff
  5. Tuav lub pob ntawm Sonoff thiab ntsaws rau hauv Serial rau USB adapter rau koj lub khoos phis tawj
  6. Hauv ESPEasy phau ntawv qhib FlashESP8266.exe
  7. Xaiv koj qhov chaw nres nkoj COM
  8. Xaiv lub.bin
  9. Nyem nyem

Kauj Ruam 4: Txhim Kho Txhua Yam

Txuas Txhua Yam
Txuas Txhua Yam
Txuas Txhua Yam
Txuas Txhua Yam
Txuas Txhua Yam
Txuas Txhua Yam
Txuas Txhua Yam
Txuas Txhua Yam

Kuv siv dupont cables thiab lub computer fais fab cable rau qhov no tab sis koj tuaj yeem siv qhov koj nyiam.

  1. Siv lub xaim hlau mus rau RX lub davhlau ya nyob twg ntawm Sonoff
  2. Siv lub xaim txuas mus rau GND lub davhlau ya nyob twg ntawm Sonoff
  3. Txuas cov xov hlau mus rau qhov nruab nrab thiab cov kab tawm
  4. Muab cov ntaub ntawv Sonoff tso rau
  5. Txiav sab sab hauv ntawm txoj hlua txuas ntxiv, hle cov xov hlau, thiab txuas nws Sonoff kab thiab nruab nrab qhov nkag
  6. Ntsia lub Sonoff lub kaus mom kom ntseeg tau tias cov xov hlau nkag tau ruaj ntseg
  7. Kuaj xyuas kom ntseeg tau tias koj lub xov tooj sib txuas thiab xa tawm tau ua haujlwm raug

Kauj Ruam 5: Txuas rau Lub Qhov Rooj Nkag Nkag

Txuas mus rau Qhov Rooj Nkoj
Txuas mus rau Qhov Rooj Nkoj
Txuas mus rau Qhov Rooj Nkoj
Txuas mus rau Qhov Rooj Nkoj
Txuas mus rau Qhov Rooj Nkoj
Txuas mus rau Qhov Rooj Nkoj
  1. Txuas tus sensor hu (Kuv txuas kuv rau lub pulley)

    Kuv tsis muaj ib lub xov tooj hluav taws xob hlau yog li kuv tau siv qee tus hais lus xaim thiab cable qhwv los txuas tus neeg tiv tauj.

  2. Txuas Sonoff mus rau qee yam (Kuv siv tus tuav tuav tuav lub qhov rooj qhib lub qhov rooj)
  3. Txuas cov kab

Kauj Ruam 6: Lub Tsev Pabcuam Automation - Kev Ceeb Toom Yog Lub Nkoj Qhib Rau 2 Teev

Ua rau: Yog tias lub qhov rooj qhov rooj qhib rau 2 teev

Kev Ua: Xa cov ntawv ceeb toom rau kuv lub xov tooj, kuv tus phooj ywg tus xov tooj, thiab rau kuv lub tsev tsis sib haum xeeb channel

automations.yaml

- id: ceeb toom_if_garage_is_open_for_2_hours

alias: "ceeb toom yog lub chaw nres tsheb qhib rau 2 teev" txhais: platform: xeev entity_id: cover.garage_door rau: qhib rau: teev: 2 kev nqis tes ua: - kev pabcuam: ceeb toom.mobile_app_courtney_s_iphone cov ntaub ntawv: npe: "[?] [?] chav nres tsheb sab laug qhib! " lus: "Lub qhov rooj tsheb tau qhib rau 2 teev. Kaw nws?" cov ntaub ntawv: thawb: qeb: ios_close_garage - kev pabcuam: ceeb toom.mobile_app_pixel_3a cov ntaub ntawv: npe: "[?] [?] Lub tsev tso tsheb sab laug qhib!" lus: "Lub qhov rooj tsheb tau qhib rau 2 teev. Kaw nws?" cov ntaub ntawv: nqis tes ua: - nqis tes ua: android_close_garage title: Kaw Garage - kev pabcuam: ceeb toom.discord cov ntaub ntawv: xov: "[?] [?] Lub qhov rooj tsheb tau qhib rau 2 teev. Kaw nws?" lub hom phiaj: ["Koj DISCORD CHANNEL ID"]

Txhawm rau kom tau txais kev ceeb toom ntawm IOS uas muaj lub pob kaw lub qhov rooj rau lub qhov rooj koj yuav tsum tau ntxiv cov hauv qab no rau cov ntawv teeb tsa.yaml.

configuration.yaml

ios:

thawb: pawg: - lub npe: Kaw qhov chaw cim tsheb: 'ios_close_garage' kev nqis tes ua: - tus cim: 'IOS_CLOSE_GARAGE' lub npe: 'Kaw Lub Tsev Tso Tsheb' kom ua haujlwm Mode: 'keeb kwm yav dhau los' authenticationRequired: muaj tseeb # Yuav Tsum Tau FaceID / TouchID kev puas tsuaj: kev coj ua tsis raug:

Tam sim no koj tuaj yeem ntxiv qhov kev siv tshuab uas hu ua thaum koj nias lub qhov rooj kaw lub qhov rooj khawm ntawm IOS thawb ceeb toom.

automations.yaml

- id: 'ios_mobile_app_notification_close_garage_door'

alias: ios mobile app ceeb toom kaw lub qhov rooj rau tsheb: platform: xwm txheej event_type: ios.notification_action_fired event_data: actionName: IOS_CLOSE_GARAGE ua: - ncua: 00:00:15 - kev pabcuam: npog.close_cover cov ntaub ntawv: entity_id: cover.garage_door

Kev siv lub tshuab ua haujlwm uas hu ua thaum koj nias lub qhov rooj kaw lub qhov rooj ntawm Android ceeb toom thawb.

automations.yaml

- id: 'android_mobile_app_notification_close_garage_door'

alias: android mobile app ceeb toom kaw qhov rooj rau tsheb: - event_data: nqis tes ua: android_close_garage event_type: mobile_app_notification_action platform: kev tshwm sim ua: - ncua: 00:00:15 - kev pabcuam: npog.close_cover cov ntaub ntawv: entity_id: cover.garage_door

Pom zoo: