Skip to content

Commit 31de639

Browse files
committed
Bump version 0.1.5 → 0.1.6
1 parent 68fb64a commit 31de639

File tree

5 files changed

+62
-20
lines changed

5 files changed

+62
-20
lines changed

README.md

Lines changed: 29 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
[![Codacy grade](https://img.shields.io/codacy/grade/bff08a94e4d447b690cea49c6594826d?label=Project%20Quality&logo=codacy)](https://app.codacy.com/gh/nirsimetri/onvif-python/dashboard?utm_source=gh&utm_medium=referral&utm_content=&utm_campaign=Badge_grade)
44
[![Ask DeepWiki](https://deepwiki.com/badge.svg)](https://deepwiki.com/nirsimetri/onvif-python)
5-
[![PyPI](https://img.shields.io/badge/PyPI-0.1.5-orange?logo=archive)](https://pypi.org/project/onvif-python/)
5+
[![PyPI](https://img.shields.io/badge/PyPI-0.1.6-orange?logo=archive)](https://pypi.org/project/onvif-python/)
66
[![Downloads](https://img.shields.io/pypi/dm/onvif-python?label=Downloads&color=red)](https://clickpy.clickhouse.com/dashboard/onvif-python)
77
<br>
88
[![Build](https://github.com/nirsimetri/onvif-python/actions/workflows/python-app.yml/badge.svg?branch=main)](https://github.com/nirsimetri/onvif-python/actions/workflows/python-app.yml)
@@ -54,9 +54,29 @@ pip install .
5454
> [!TIP]
5555
> You can view the complete documentation automatically generated by DeepWiki via the [onvif-python AI Wiki](https://deepwiki.com/nirsimetri/onvif-python) link. We currently do not have an official documentation site. Help us create more examples and helpful documentation by [contributing](https://github.com/nirsimetri/onvif-python?tab=contributing-ov-file).
5656
57-
Below are simple examples to help you get started with the ONVIF Python library. These demonstrate how to connect to an ONVIF-compliant device and retrieve basic device information.
57+
Below are simple examples to help you get started with the ONVIF Python library. These demonstrate how to discover and connect to ONVIF-compliant devices and retrieve basic device information.
5858

59-
**1. Initialize the ONVIFClient**
59+
**1. Discover ONVIF Devices (Optional)**
60+
61+
Use `ONVIFDiscovery` (applied at [`>=v0.1.6`](https://github.com/nirsimetri/onvif-python/releases/tag/v0.1.6)) to automatically find ONVIF devices on your local network:
62+
63+
```python
64+
from onvif import ONVIFDiscovery
65+
66+
# Create discovery instance
67+
discovery = ONVIFDiscovery(timeout=5)
68+
69+
# Discover devices
70+
devices = discovery.discover()
71+
72+
# Display discovered devices
73+
for device in devices:
74+
print(f"Found device at {device['host']}:{device['port']}")
75+
print(f" Scopes: {device.get('scopes', [])}")
76+
print(f" XAddrs: {device['xaddrs']}")
77+
```
78+
79+
**2. Initialize the ONVIFClient**
6080

6181
Create an instance of `ONVIFClient` by providing your device's IP address, port, username, and password:
6282

@@ -73,7 +93,7 @@ client = ONVIFClient(
7393
)
7494
```
7595

76-
**2. Create Service Instance**
96+
**3. Create Service Instance**
7797

7898
`ONVIFClient` provides several main services that can be accessed via the following methods:
7999

@@ -92,7 +112,7 @@ device = client.devicemgmt() # Device Management (Core)
92112
media = client.media() # Media
93113
```
94114

95-
**3. Get Device Information**
115+
**4. Get Device Information**
96116

97117
Retrieve basic information about the device, such as manufacturer, model, firmware version, and serial number using `devicemgmt()` service:
98118

@@ -102,7 +122,7 @@ print(info)
102122
# Example output: {'Manufacturer': '..', 'Model': '..', 'FirmwareVersion': '..', 'SerialNumber': '..'}
103123
```
104124

105-
**4. Get RTSP URL**
125+
**5. Get RTSP URL**
106126

107127
Retrieve the RTSP stream URL for live video streaming from the device using `media()` service:
108128

@@ -135,6 +155,7 @@ This library includes a powerful command-line interface (CLI) for interacting wi
135155

136156
### Features
137157

158+
- **Device Discovery:** Automatic ONVIF device discovery on local network using WS-Discovery protocol.
138159
- **Interactive Shell:** A user-friendly shell with tab completion, command history, and colorized output.
139160
- **Direct Command Execution:** Run ONVIF commands directly from the terminal for scripting and automation.
140161
- **Automatic Discovery:** Automatically detects available services on the device.
@@ -177,7 +198,7 @@ usage: onvif [-h] [--host HOST] [--port PORT] [--username USERNAME] [--password
177198
[--no-patch] [--interactive] [--debug] [--wsdl WSDL] [--cache {all,db,mem,none}] [--health-check-interval HEALTH_CHECK_INTERVAL] [--version]
178199
[service] [method] [params ...]
179200

180-
ONVIF Terminal Client — v0.1.5
201+
ONVIF Terminal Client — v0.1.6
181202
https://github.com/nirsimetri/onvif-python
182203

183204
positional arguments:
@@ -234,7 +255,7 @@ Examples:
234255
<summary><b>2. Interactive Shell</b></summary>
235256

236257
```bash
237-
ONVIF Interactive Shell Commands - v0.1.5
258+
ONVIF Interactive Shell Commands - v0.1.6
238259
https://github.com/nirsimetri/onvif-python
239260

240261
Basic Commands:

README_ID.md

Lines changed: 28 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
[![Codacy grade](https://img.shields.io/codacy/grade/bff08a94e4d447b690cea49c6594826d?label=Project%20Quality&logo=codacy)](https://app.codacy.com/gh/nirsimetri/onvif-python/dashboard?utm_source=gh&utm_medium=referral&utm_content=&utm_campaign=Badge_grade)
44
[![Ask DeepWiki](https://deepwiki.com/badge.svg)](https://deepwiki.com/nirsimetri/onvif-python)
5-
[![PyPI](https://img.shields.io/badge/PyPI-0.1.5-orange?logo=archive)](https://pypi.org/project/onvif-python/)
5+
[![PyPI](https://img.shields.io/badge/PyPI-0.1.6-orange?logo=archive)](https://pypi.org/project/onvif-python/)
66
[![Downloads](https://img.shields.io/pypi/dm/onvif-python?label=Downloads&color=red)](https://clickpy.clickhouse.com/dashboard/onvif-python)
77
<br>
88
[![Build](https://github.com/nirsimetri/onvif-python/actions/workflows/python-app.yml/badge.svg?branch=main)](https://github.com/nirsimetri/onvif-python/actions/workflows/python-app.yml)
@@ -56,7 +56,27 @@ pip install .
5656
5757
Berikut adalah contoh sederhana untuk membantu Anda memulai dengan pustaka ONVIF Python. Contoh ini menunjukkan cara menghubungkan ke perangkat yang sesuai dengan ONVIF dan mengambil informasi dasar perangkat.
5858

59-
**1. Inisialisasi ONVIFClient**
59+
**1. Menemukan Perangkat ONVIF (Opsional)**
60+
61+
Sebelum menghubungkan ke perangkat tertentu, Anda dapat menemukan perangkat ONVIF di jaringan lokal Anda menggunakan kelas `ONVIFDiscovery` (diterapkan pada [`>=v0.1.6`](https://github.com/nirsimetri/onvif-python/releases/tag/v0.1.6)):
62+
63+
```python
64+
from onvif import ONVIFDiscovery
65+
66+
# Buat instance discovery
67+
discovery = ONVIFDiscovery(timeout=5)
68+
69+
# Temukan perangkat
70+
devices = discovery.discover()
71+
72+
# Tampilkan perangkat yang ditemukan
73+
for device in devices:
74+
print(f"Ditemukan perangkat di {device['host']}:{device['port']}")
75+
print(f" Scopes: {device.get('scopes', [])}")
76+
print(f" XAddrs: {device['xaddrs']}")
77+
```
78+
79+
**2. Inisialisasi ONVIFClient**
6080

6181
Buat instance `ONVIFClient` dengan memberikan alamat IP perangkat Anda, port, nama pengguna, dan kata sandi:
6282

@@ -73,7 +93,7 @@ client = ONVIFClient(
7393
)
7494
```
7595

76-
**2. Buat Instance Layanan**
96+
**3. Buat Instance Layanan**
7797

7898
`ONVIFClient` menyediakan beberapa layanan utama yang dapat diakses melalui metode berikut:
7999

@@ -92,7 +112,7 @@ device = client.devicemgmt() # Manajemen Perangkat (Inti)
92112
media = client.media() # Media
93113
```
94114

95-
**3. Dapatkan Informasi Perangkat**
115+
**4. Dapatkan Informasi Perangkat**
96116

97117
Ambil informasi dasar tentang perangkat, seperti produsen, model, versi firmware, dan nomor seri menggunakan layanan `devicemgmt()`:
98118

@@ -102,7 +122,7 @@ print(info)
102122
# Contoh: {'Manufacturer': '..', 'Model': '..', 'FirmwareVersion': '..', 'SerialNumber': '..'}
103123
```
104124

105-
**4. Dapatkan URL RTSP**
125+
**5. Dapatkan URL RTSP**
106126

107127
Ambil URL aliran RTSP untuk streaming video langsung dari perangkat menggunakan layanan `media()`:
108128

@@ -135,6 +155,7 @@ Pustaka ini menyertakan antarmuka baris perintah (CLI) yang kuat untuk berintera
135155

136156
### Fitur
137157

158+
- **Penemuan Perangkat:** Penemuan perangkat ONVIF otomatis di jaringan lokal menggunakan protokol WS-Discovery.
138159
- **Shell Interaktif:** Shell yang ramah pengguna dengan pelengkapan tab, riwayat perintah, dan output berwarna.
139160
- **Eksekusi Perintah Langsung:** Jalankan perintah ONVIF langsung dari terminal untuk skrip dan otomatisasi.
140161
- **Penemuan Otomatis:** Secara otomatis mendeteksi layanan yang tersedia di perangkat.
@@ -177,7 +198,7 @@ usage: onvif [-h] [--host HOST] [--port PORT] [--username USERNAME] [--password
177198
[--no-patch] [--interactive] [--debug] [--wsdl WSDL] [--cache {all,db,mem,none}] [--health-check-interval HEALTH_CHECK_INTERVAL] [--version]
178199
[service] [method] [params ...]
179200

180-
ONVIF Terminal Client — v0.1.5
201+
ONVIF Terminal Client — v0.1.6
181202
https://github.com/nirsimetri/onvif-python
182203

183204
positional arguments:
@@ -235,7 +256,7 @@ Examples:
235256

236257

237258
```bash
238-
ONVIF Interactive Shell Commands - v0.1.5
259+
ONVIF Interactive Shell Commands - v0.1.6
239260
https://github.com/nirsimetri/onvif-python
240261

241262
Basic Commands:

onvif/cli/interactive.py

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

onvif/cli/main.py

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
44

55
[project]
66
name = "onvif-python"
7-
version = "0.1.5"
7+
version = "0.1.6"
88
description = "A comprehensive and developer-friendly Python library for working with ONVIF-compliant devices"
99
readme = "README.md"
1010
requires-python = ">=3.9"

0 commit comments

Comments
 (0)