@danielbibit I adapted his code for use in new version to homeasssistant.
@boralyl for you excelent tutorial : Building a Home Assistant Custom Component.
Custom component to get information qBitTorrent for the home assistant
Have HACS installed, this will allow you to easily update.
Add https://github.com/radsonpatrick/qbittorrent_custom_component as a custom repository with Type: Integration
Click Install under "qBitTorrent" integration.
Restart Home-Assistant.
sensor:
- platform: custom_qbittorrent
name: qbit #optional
host: "http://hostname:8080"
username: "admin"
password: "adminadmin"
monitored_variables:
- 'current_status'
- 'total_torrents'
- 'active_torrents'
- 'inactive_torrents'
#- 'downloading_torrents' if you not need remove or comment
#- 'seeding_torrents'
- 'resumed_torrents'
- 'paused_torrents'
- 'completed_torrents'
- 'download_speed'
- 'upload_speed'
alternative_speed
in qbittorrent interfaceswitch:
- platform: custom_qbittorrent
name: qbit #optional
host: "http://hostname:8080"
username: "admin"
password: "adminadmin"
not confuse between alternative_speed
switch and limit_speed_switch
.
limit_speed_switch
you get one value between min:
and max:
, for limit global download speed
value
= 0 is unlimited speednumber:
- platform: custom_qbittorrent
name: qbit_limit_speed #optional
host: "http://192.168.1.2:8080"
username: "admin"
password: "adminadmin"
min: 0
max: 120 #value in Mb/s
step: 0.5