mirror of
https://github.com/vimagick/dockerfiles
synced 2024-06-28 09:41:20 +00:00
update
This commit is contained in:
parent
9d4acb2fe5
commit
85ba705e1b
@ -17,18 +17,30 @@ $ curl http://127.0.0.1:6052
|
|||||||
$ udevadm info -q property -n /dev/ttyACM0 --property=ID_SERIAL
|
$ udevadm info -q property -n /dev/ttyACM0 --property=ID_SERIAL
|
||||||
$ docker compose exec esphome bash
|
$ docker compose exec esphome bash
|
||||||
>>> cd /config
|
>>> cd /config
|
||||||
>>> esphome ibeacon.yaml run
|
>>> esphome run ibeacon.yaml
|
||||||
====== [SUCCESS] Took 253.61 seconds ======
|
====== [SUCCESS] Took 253.61 seconds ======
|
||||||
INFO Successfully compiled program.
|
INFO Successfully compiled program.
|
||||||
Found multiple options for uploading, please choose one:
|
Found multiple options for uploading, please choose one:
|
||||||
[1] /dev/ttyACM0 (USB JTAG/serial debug unit)
|
[1] /dev/ttyACM0 (USB JTAG/serial debug unit)
|
||||||
[2] Over The Air (esphome-esp32c3-ibeacon.local)
|
[2] Over The Air (esphome-esp32c3-ibeacon.local)
|
||||||
(number): 1
|
(number): 1
|
||||||
|
Dependency Graph
|
||||||
|
|-- AsyncTCP-esphome @ 2.0.1
|
||||||
|
|-- WiFi @ 2.0.0
|
||||||
|
|-- FS @ 2.0.0
|
||||||
|
|-- Update @ 2.0.0
|
||||||
|
|-- ESPAsyncWebServer-esphome @ 3.1.0
|
||||||
|
|-- DNSServer @ 2.0.0
|
||||||
|
|-- ESPmDNS @ 2.0.0
|
||||||
|
|-- ArduinoJson @ 6.18.5
|
||||||
|
|-- NeoPixelBus @ 2.7.3
|
||||||
INFO Successfully uploaded program.
|
INFO Successfully uploaded program.
|
||||||
INFO Starting log output from /dev/ttyACM0 with baud rate 115200
|
INFO Starting log output from /dev/ttyACM0 with baud rate 115200
|
||||||
^C
|
^C
|
||||||
>>> ping esphome-esp32c3-ibeacon.lan
|
>>> ping esphome-esp32c3-ibeacon.lan
|
||||||
>>> exit
|
>>> exit
|
||||||
|
$ curl http://esphome-esp32c3-ibeacon.lan/
|
||||||
|
$ curl -X POST 'http://esphome-esp32c3-ibeacon.lan/light/neopixel_light/turn_on?brightness=255&r=255&g=192&b=203&white_value=0&effect=None'
|
||||||
```
|
```
|
||||||
|
|
||||||
[1]: https://esphome.io/
|
[1]: https://esphome.io/
|
||||||
|
@ -22,6 +22,14 @@ wifi:
|
|||||||
ssid: !secret wifi_ssid
|
ssid: !secret wifi_ssid
|
||||||
password: !secret wifi_password
|
password: !secret wifi_password
|
||||||
domain: .lan
|
domain: .lan
|
||||||
|
ap:
|
||||||
|
ssid: "ESPHome"
|
||||||
|
password: "configesp"
|
||||||
|
|
||||||
|
captive_portal:
|
||||||
|
|
||||||
|
web_server:
|
||||||
|
port: 80
|
||||||
|
|
||||||
mqtt:
|
mqtt:
|
||||||
broker: broker.hivemq.com
|
broker: broker.hivemq.com
|
||||||
|
@ -1,3 +1,7 @@
|
|||||||
|
#
|
||||||
|
# See: https://esphome.io/guides/getting_started_command_line.html
|
||||||
|
#
|
||||||
|
|
||||||
version: "3.8"
|
version: "3.8"
|
||||||
services:
|
services:
|
||||||
esphome:
|
esphome:
|
||||||
@ -6,7 +10,10 @@ services:
|
|||||||
- "6052:6052"
|
- "6052:6052"
|
||||||
volumes:
|
volumes:
|
||||||
- ./data:/config
|
- ./data:/config
|
||||||
|
- /etc/localtime:/etc/localtime:ro
|
||||||
environment:
|
environment:
|
||||||
|
- USERNAME=admin
|
||||||
|
- PASSWORD=admin
|
||||||
- ESPHOME_DASHBOARD_USE_PING=true
|
- ESPHOME_DASHBOARD_USE_PING=true
|
||||||
### FOR THE FIRST-TIME ONLY ###
|
### FOR THE FIRST-TIME ONLY ###
|
||||||
#devices: #
|
#devices: #
|
||||||
|
@ -19,11 +19,12 @@ ExecStart=/bin/hciconfig hci0 noscan
|
|||||||
ExecStart=/usr/bin/hcitool -i hci0 cmd 0x08 0x0008 1E 02 01 1A 1A FF 4C 00 02 15 $UUID $MAJOR $MINOR $POWER 00
|
ExecStart=/usr/bin/hcitool -i hci0 cmd 0x08 0x0008 1E 02 01 1A 1A FF 4C 00 02 15 $UUID $MAJOR $MINOR $POWER 00
|
||||||
ExecStart=/usr/bin/hcitool -i hci0 cmd 0x08 0x0006 $MIN_INTERVAL $MAX_INTERVAL $ADV_MODE 00 00 00 00 00 00 00 00 07 00
|
ExecStart=/usr/bin/hcitool -i hci0 cmd 0x08 0x0006 $MIN_INTERVAL $MAX_INTERVAL $ADV_MODE 00 00 00 00 00 00 00 00 07 00
|
||||||
ExecStart=/usr/bin/hcitool -i hci0 cmd 0x08 0x000a 01
|
ExecStart=/usr/bin/hcitool -i hci0 cmd 0x08 0x000a 01
|
||||||
|
|
||||||
# See: http://stackoverflow.com/questions/21124993/
|
# See: http://stackoverflow.com/questions/21124993/
|
||||||
# ExecStart=/bin/hciconfig hci0 leadv 3 # IT WILL OVERWRITE ADV RATE
|
# ExecStart=/bin/hciconfig hci0 leadv 3 # IT WILL OVERWRITE ADV RATE
|
||||||
ExecStop=/bin/hciconfig hci0 noleadv
|
#ExecStop=/bin/hciconfig hci0 noleadv
|
||||||
ExecStop=/bin/hciconfig hci0 reset
|
#ExecStop=/bin/hciconfig hci0 reset
|
||||||
RemainAfterExit=yes
|
#RemainAfterExit=yes
|
||||||
|
|
||||||
[Install]
|
#[Install]
|
||||||
WantedBy=multi-user.target
|
#WantedBy=multi-user.target
|
||||||
|
9
hass/arm/ibeacon.timer
Normal file
9
hass/arm/ibeacon.timer
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
[Unit]
|
||||||
|
Description=Hourly restart ibeacon
|
||||||
|
|
||||||
|
[Timer]
|
||||||
|
OnCalendar=hourly
|
||||||
|
Persistent=true
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=timers.target
|
Loading…
Reference in New Issue
Block a user