2927 views|0 replies

652

Posts

1

Resources
The OP
 

【BIGTREETECH CB1】—— Installing HomeAssistant [Copy link]

 

2. CB1_HomeAssistant_notes

2.1. Install HomeAssistant-Core using the system's own Python

2.1.1. Install home-assistant-core according to the tutorial on HomeAssistant official website

https://www.home-assistant.io/installation/raspberrypi#install-home-assistant-core

  1. The debian image is switched to the tuna image source of Tsinghua University in China

    Refer to the Debian mirror usage help ( https://mirrors.tuna.tsinghua.edu.cn/help/debian/ )

    sudo you /etc/apt/sources.list

    # The source mirror is commented out by default to increase the speed of apt update. You can uncomment it if necessary. deb https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye main contrib non-free # deb-src https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye main contrib non-free deb https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye-updates main contrib non-free # deb-src https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye-updates main contrib non-free

    debhttps://mirrors.tuna.tsinghua.edu.cn/debian/bullseye-backports main contrib non-free # deb-srchttps://mirrors.tuna.tsinghua.edu.cn/debian/bullseye-backports main contrib non-free

    debhttps://mirrors.tuna.tsinghua.edu.cn/debian-securitybullseye-security main contrib non-free # deb-srchttps://mirrors.tuna.tsinghua.edu.cn/debian-securitybullseye-security main contrib non-free

  2. Switch pip source

    Downloading from pip's official website is too slow (40KB/s). Refer to Python to modify the pip source to the domestic source ( https://www.cnblogs.com/137point5/p/15000954.html )

    pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple
    
  3. The difference from the text is

    The original text is for Raspberry Pi, which has built-in gpio and i2c user groups, but the CB1 system does not have these user groups, so the command

    sudo useradd -rm homeassistant -G dialout,gpio,i2c
    

    Should be changed to

    sudo useradd -rm homeassistant -G dialout
    
  4. Run at the end

    pip3 install homeassistant==2023.2.0
    

    An error occurred, saying that the 2023.2.0 version of HomeAssistant was not found.

    1. Maybe the pip source has not been updated yet.

    2. Note: Later, in the installed HomeAssistant, it will be prompted that the current system Python version is 3.9, which has been disabled in version 2023.2.0 and needs to be updated to Python-3.10 or above before it can be used.

  5. Do not specify the latest HomeAssistant version, ie: pip3 install homeassistant

  6. The whole process is shown in the figure:

  7. The command line result after the installation is completed is as shown below:

2.2. Run and use HomeAssistant-

After installation, enter hass in the command line to run the HomeAssistant service.

(Note: From the command line output information, you can see that the previous installation of pip3 install home-assistant==2023.2.0 failed because HomeAssistant-2023.2 stopped supporting the current Python-3.9.2 version, so you can only install the latest version supported by python-3.9.2 - HomeAssistant-2023.1.7)

2.2.1. Configuring HomeAssistant

Enter http://XXXX:8123 (replace XXXX with your machines' IP address) in the browser address bar to enter the HomeAssistant browser interface. The initial configuration is as follows:

  1. First, create a user

  2. Log in after setting user information:

  3. After logging in, automatically discover devices supported by HomeAssistant

    During the test, it was found that the router (Huawei AX3 Pro) in the wireless network connected to the system supports HomeAssistant:

  4. Settings/repair information

    There is an information sign in the Settings on the left sidebar. After clicking it, I found a repair message, which also verified the reason why the previous installation of the latest HomeAssistant-2023.2.0 failed: HomeAssistant-2023.2 will no longer support python-3.9 and requires at least python-3.10 and above.

This post is from Domestic Chip Exchange
 
 

Just looking around
Find a datasheet?

EEWorld Datasheet Technical Support

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京B2-20211791 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号
快速回复 返回顶部 Return list