Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
KC868-A2 configure yaml for ESPhome
#1
KC868-A2 configure yaml for ESPhome by Ethernet or WiFi.
   

.txt   ESPHome_KC868-A2-ethernet.txt (Size: 732 bytes / Downloads: 419)

.txt   ESPHome_KC868-A2-wifi.txt (Size: 875 bytes / Downloads: 309)
Reply
#2
Hi

Great product.... but how do we use a SIM7600 (4g modem) with ESPHome to send SMS text messages to / from the device?

Thank you!
Reply
#3
ESPHome only support 2g modem SIM800L to send SMS. maybe i will feedback to ESPHome support 4G module.
Reply
#4
Yes - please do ask ESPHome to support SIM7600! Your videos show SIM7600 being plugged in, and you talk about ESPHome - but this combination cannot be used.

Many countries are closing down 2g network. More will follow..... so SIM7600 support for the KC868-A2 is very important. 

I think the commands are very similar - so probably only very small changes required to the ESPHome SIM800 code? Maybe someone at your company has the skills to suggest the required changes and make a pull request? https://github.com/esphome/esphome/tree/...ts/sim800l


Australia 
Telstra – Closed in December 2016 
Optus – Closed in August 2017 
Vodafone – Closed in June 2018 

Bahrain 
Batelco – Closed in November 2021 

Belgium 
Orange – Closing before December 2030 

Brunei 
DST – Closed in June 2021 
Imagine - Closed in June 2021 
Progresif - Closed in June 2021 

Canada 
Telus – Closed in May 2017 
Rogers – Closed in December 2021 
Bell – Closed in April 2019 

China 
China Telecom – Closed in June 2020 
China Unicom – Closed in December 2021 

Colombia 
Claro – Closing before December 2022 

France 
Orange – Closing before December 2025 

Germany 
Vodafone – Closing before December 2025 

Hong Kong 
Three – Closed in September 2021 
China Mobile – Closed in December 2021 
HKT – Closed in September 2021 
SmarTone – Closed in December 2021 

Israel 
Partner Communications – Closing before December 2025 
Cellcom – Closing before December 2025 

Italy 
Vodafone – Closing before December 2025 
Telecom Italia – Closing before December 2029 

Japan 
Softbank – Closed in March 2010 
NTT Docomo – Closed in March 2012 
KDDI – Closed in 2020 

Luxembourg 
Orange – Closing before December 2030 

Mexico 
AT&T – Closed in March 2019 
Movistar – Closed in January 2021 

Netherlands 
Vodafone – Closing before December 2025 
T-Mobile – Closing before June 2023 

New Zealand 
2degrees – Closed in March 2018 
Vodafone – Closing before December 2025 
Spark – Closed in July 2012 

Norway 
Telenor – Closing before December 2025 
Telia – Closing before December 2025 

Pakistan 
Telenor – Closing before December 2025 

Poland 
Orange – Closing before December 2030 

Romania 
Orange – Closing before December 2030 
Vodafone – Closing before December 2025 

Singapore 
MobileOne – Closed in April 2018 
Singtel - Closed in April 2018 
Starhub - Closed in April 2018 

Spain 
Orange – Closing before December 2030 
Vodafone – Closing before December 2025 

Slovakia 
Orange – Closing before December 2030 
Vodafone – Closing before December 2025 

South Africa 
Telkom – Closed in 2020 

South Korea 
KT – Closed in March 2012 
LG Uplus – Closed in June 2021 
SK Telcom – Closed in July 2020 

Switzerland 
Swisscom – Closed in December 2020 
Sunrise – Closing before December 2022 

Taiwan 
Chunghwa Telecom – Closed in June 2017 
FarEasTone – Closed in June 2017 
Taiwan Mobile – Closed in June 2017 

United Arab Emirates 
Du – Closing in December 2022 
Etisalat – Closing in December 2022 

United Kingdom 
EE – Closing before December 2033 
Vodafone – Closing before December 2033 
O2 – Closing before December 2033 
Three – Have never run a 2G network 

United States 
AT&T – Closed in January 2017 
T-Mobile – Closing before December 2022 
Verizon – Closed in December 2020
Reply
#5
At least initially, maybe sim7600 support could be added as an external component to esphome?

https://esphome.io/components/external_components.html
Reply
#6
we will contact with esphome about the 4G needs.
Reply
#7
Good day, I have one of these units set up with esphome. I'm using the recommended yaml for ethernet connection.

My intention was to use the board to restart my router when the internet fails. So the board powers the router and at the same time is connected to the router via the ethernet port.

The problem I have is that when I power cycle the board or associated relay powering the router, the esp32 chip does not reconnect to the network.

I can see the board connected to the network with it's associated IP address, but the esp32 does not seem to connect and therefore the board is inaccessible. I cant see it in homeassitant or on the assigned ip address webui.

If I just use it to power something else and it doesn't loose Ethernet connection, then it works fine.

However, as I explained the use case was as an internet 'watchdog'.

Is there an additional setting I must add to the esphome yaml?

See below my esphome yaml for reference

```
substitutions:
  name: networksocket
  friendly_name: networksocket

esphome:
  name: ${friendly_name}

esp32:
  board: esp32dev
  framework:
    type: arduino

web_server:
  port: 80

logger:

api:
  encryption:
    key: "key"
  services:
  - service: power_cycle_relay1
    then:
    - switch.turn_off: relay1
    - delay: 30s
    - switch.turn_on: relay1
  - service: power_cycle_relay2
    then:
    - switch.turn_off: relay2
    - delay: 30s
    - switch.turn_on: relay2
  - service: power_cycle_esp
    then:
    - delay: 5min
    - button.press: ${friendly_name}_restart

ethernet:
  type: LAN8720
  mdc_pin: GPIO23
  mdio_pin: GPIO18
  clk_mode: GPIO17_OUT
  phy_addr: 0

i2c:
- id: bus_a
  sda: GPIO4
  scl: GPIO5
  scan: true
   
switch:
- platform: gpio
  name: ${friendly_name}-relay1
  pin: 15
  inverted: false
  restore_mode: RESTORE_DEFAULT_ON
  id: relay1
- platform: gpio
  name: ${friendly_name}-relay2
  pin: 2
  inverted: false
  restore_mode: RESTORE_DEFAULT_ON
  id: relay2   

binary_sensor:
- platform: gpio
  name: ${friendly_name}-input1
  pin:
    number: 36
    inverted: true
  on_press:
    then:
    - switch.toggle: relay1
- platform: gpio
  name: ${friendly_name}-input2
  pin:
    number: 39
    inverted: true
  on_press:
    then:
    - switch.toggle: relay2

sensor:
- platform: uptime
  name: ${friendly_name} uptime

text_sensor:
- platform: version
  name: ${friendly_name} ESPHome Version   
- platform: ethernet_info
  ip_address:
    name: ${friendly_name} IP Address

time:
- platform: homeassistant
  id: homeassistant_time

# https://esphome.io/components/esp32_ble_tracker.html
esp32_ble_tracker:
  scan_parameters:
    active: true
   
# https://esphome.io/components/bluetooth_proxy.html
bluetooth_proxy:
  active: true 

button:
- platform: restart
  name: ${friendly_name} restart
  entity_category: config
  disabled_by_default: false
  device_class: restart
  id: ${friendly_name}_restart

```

Thank you
Reply
#8
i think you can use esphome to visit one internet URL, if can't visited, then use relay ON/OFF for your router's power supply.
Reply
#9
(09-26-2023, 11:57 PM)admin Wrote: i think you can use esphome to visit one internet URL, if can't visited, then use relay ON/OFF for your router's power supply.

Thank you that is not the problem.
The problem is that if the board is initiated before it has a LAN connection (while the router is starting) then the esp32 does not connect, there's no webgui in the assigned IP.
The board is connected to the network, because it's connected via ethernet, so I can see it in my router webpage, but it doesn initiate or start the esp32 in esphome. There's no control.

If I restart the board, while it has a 'live' network connection, then it works fine.

It just doesn't work correctly when it's initiated  without a network connection.
Reply
#10
if router not ready, esp32 will always try to connect with ethernet connection.
you can download KCS firmware for a test. just let esp32 board power on, then router power off, wait for a moment, router power on, then check esp32 whether is connected to router by ethernet.
Reply


Forum Jump:


Users browsing this thread:
1 Guest(s)