『瀚思彼岸』» 智能家居技术论坛

 找回密码
 立即注册
楼主: alei643

[教程系列] Node Red 系列教程之一 初识Node Red

  [复制链接]

1

主题

6

帖子

46

积分

新手上路

Rank: 1

积分
46
金钱
40
HASS币
0
发表于 2024-3-7 17:26:26 | 显示全部楼层
好帖看看
回复

使用道具 举报

0

主题

1

帖子

16

积分

新手上路

Rank: 1

积分
16
金钱
15
HASS币
0
发表于 2024-3-7 21:46:14 | 显示全部楼层
膜拜大神!学习一手nodered
回复

使用道具 举报

0

主题

11

帖子

108

积分

注册会员

Rank: 2

积分
108
金钱
97
HASS币
0
发表于 2024-3-8 10:45:35 | 显示全部楼层
感谢分享  学习了
回复

使用道具 举报

0

主题

12

帖子

67

积分

注册会员

Rank: 2

积分
67
金钱
55
HASS币
0
发表于 2024-3-8 12:18:31 | 显示全部楼层
谢谢分享
回复

使用道具 举报

1

主题

18

帖子

88

积分

注册会员

Rank: 2

积分
88
金钱
70
HASS币
0
发表于 2024-3-8 15:24:26 | 显示全部楼层
谢谢分享
回复

使用道具 举报

0

主题

1

帖子

26

积分

新手上路

Rank: 1

积分
26
金钱
25
HASS币
0
发表于 2024-3-8 15:48:11 | 显示全部楼层
来学习 node red
回复

使用道具 举报

2

主题

40

帖子

169

积分

注册会员

Rank: 2

积分
169
金钱
129
HASS币
0
发表于 2024-3-9 17:06:20 | 显示全部楼层
谢谢分享
回复

使用道具 举报

0

主题

76

帖子

335

积分

中级会员

Rank: 3Rank: 3

积分
335
金钱
259
HASS币
0
发表于 2024-3-9 20:06:12 | 显示全部楼层
#继电器

output:
  - platform: gpio
    pin:
      number: GPIO1
    id: out1

  - platform: gpio
    pin:
      number: GPIO2
    id: out2

  - platform: gpio
    pin:
      number: GPIO3
    id: out3

  - platform: gpio
    pin:
      number: GPIO20
    id: out4


#灯实体
light:
  - platform: binary
    name: ${device_name}-1
    output: out1
    id: light1

  - platform: binary
    name: ${device_name}-2
    output: out2
    id: light2

  - platform: binary
    name: ${device_name}-3
    output: out3
    id: light3

  - platform: binary
    name: ${device_name}-4
    output: out4
    id: light4

#物理按键
binary_sensor:
  - platform: gpio
    pin:
      number: GPIO5
      mode: INPUT_PULLUP
      inverted: true
    name: bs1
    internal: true
    on_press:
      - light.toggle: light1

  - platform: gpio
    pin:
      number: GPIO7
      mode: INPUT_PULLUP
      inverted: true
    name: bs2
    internal: true
    on_press:
      - light.toggle: light2

  - platform: gpio
    pin:
      number: GPIO0
      mode: INPUT_PULLUP
      inverted: true
    name: bs3
    internal: true
    on_press:
      - light.toggle: light3

  - platform: gpio
    pin:
      number: GPIO10
      mode: INPUT_PULLUP
      inverted: true
    name: bs4
    internal: true
    on_press:
      - light.toggle: light4
回复

使用道具 举报

0

主题

1

帖子

46

积分

新手上路

Rank: 1

积分
46
金钱
45
HASS币
0
发表于 2024-3-9 22:15:22 | 显示全部楼层
学习学习学习学习学习
回复

使用道具 举报

0

主题

16

帖子

90

积分

注册会员

Rank: 2

积分
90
金钱
74
HASS币
0
发表于 2024-3-10 13:50:04 | 显示全部楼层
学习一下
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

Archiver|手机版|小黑屋|Hassbian

GMT+8, 2024-6-6 02:58 , Processed in 0.065337 second(s), 30 queries .

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

快速回复 返回顶部 返回列表