1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
|
%global _empty_manifest_terminate_build 0
Name: python-pythonegardia
Version: 1.0.52
Release: 1
Summary: Python 3 support for Egardia / Woonveilig alarm
License: MIT
URL: https://github.com/jeroenterheerdt/python-egardia
Source0: https://mirrors.nju.edu.cn/pypi/web/packages/28/f7/e04524ad192d982e02d5430b07f39ad2193e43215b71122e47490bc1cd14/pythonegardia-1.0.52.tar.gz
BuildArch: noarch
%description
# python-egardia
Python library to interface with Egardia / Woonveilig alarm. Tested with **WV-1716**, **GATE-01**, **GATE-02**, **GATE-03** and **GATE-04** version of Egardia / Woonveilig. Other versions might work, but unsure. Originally written for integration with [Home Assistant](https://home-assistant.io/) it can also by used to integrate with these alarms in other solutions.
**Note on GATE-02**
There seem to be multiple versions of software running on GATE-02 devices; we have received reports from GATE-02 users who successfully run this package in GATE-02 mode. Others have reported they needed to specify GATE-03 as their version to integrate their GATE-02.
Egardiadevice is the representation of the alarm control panel and the Egardiaserver can be used to handle alarm status changes including triggering. Test files are included for both device and server.
## EgardiaDevice ##
This script talks to the Egardia alarm control panel and can read and set its status. Note that if the alarm is triggered the state is not published through the interface available to this script. To be able to respond to alarm triggers, set up the Egardia Server (see below). For testing purposes have a look at the `test_egardiadevice.py` script. It's usage:
```bash
test_egardiadevice.py [-h] host port username password version
```
For example:
`python test_egardiadevice.py 192.168.1.X 80 user pass GATE-02`.
## EgardiaServer ##
This script captures codes generated by the Egardia alarm control panel after it was set up to forward the codes to the machine running the script ([see the Home Assistant docs](https://home-assistant.io/components/egardia#advanced-configuration): advanced configuration, step 1 to 3).
```bash
usage: egardiaserver.py [-h] [-P PORT]
Run the EgardiaServer
optional arguments:
-h, --help show this help message and exit
-P PORT, --port PORT the port number to run the server on (defaults to 52010)
--host HOST The host to run the server on (defaults to '', which is localhost). Specify this the IP address of your machine if you are having issues receiving messages.
```
The test script for the EgardiaServer is `test_egardiaserver.py` which tests if the `egardiaserver` you are running is accessible.
%package -n python3-pythonegardia
Summary: Python 3 support for Egardia / Woonveilig alarm
Provides: python-pythonegardia
BuildRequires: python3-devel
BuildRequires: python3-setuptools
BuildRequires: python3-pip
%description -n python3-pythonegardia
# python-egardia
Python library to interface with Egardia / Woonveilig alarm. Tested with **WV-1716**, **GATE-01**, **GATE-02**, **GATE-03** and **GATE-04** version of Egardia / Woonveilig. Other versions might work, but unsure. Originally written for integration with [Home Assistant](https://home-assistant.io/) it can also by used to integrate with these alarms in other solutions.
**Note on GATE-02**
There seem to be multiple versions of software running on GATE-02 devices; we have received reports from GATE-02 users who successfully run this package in GATE-02 mode. Others have reported they needed to specify GATE-03 as their version to integrate their GATE-02.
Egardiadevice is the representation of the alarm control panel and the Egardiaserver can be used to handle alarm status changes including triggering. Test files are included for both device and server.
## EgardiaDevice ##
This script talks to the Egardia alarm control panel and can read and set its status. Note that if the alarm is triggered the state is not published through the interface available to this script. To be able to respond to alarm triggers, set up the Egardia Server (see below). For testing purposes have a look at the `test_egardiadevice.py` script. It's usage:
```bash
test_egardiadevice.py [-h] host port username password version
```
For example:
`python test_egardiadevice.py 192.168.1.X 80 user pass GATE-02`.
## EgardiaServer ##
This script captures codes generated by the Egardia alarm control panel after it was set up to forward the codes to the machine running the script ([see the Home Assistant docs](https://home-assistant.io/components/egardia#advanced-configuration): advanced configuration, step 1 to 3).
```bash
usage: egardiaserver.py [-h] [-P PORT]
Run the EgardiaServer
optional arguments:
-h, --help show this help message and exit
-P PORT, --port PORT the port number to run the server on (defaults to 52010)
--host HOST The host to run the server on (defaults to '', which is localhost). Specify this the IP address of your machine if you are having issues receiving messages.
```
The test script for the EgardiaServer is `test_egardiaserver.py` which tests if the `egardiaserver` you are running is accessible.
%package help
Summary: Development documents and examples for pythonegardia
Provides: python3-pythonegardia-doc
%description help
# python-egardia
Python library to interface with Egardia / Woonveilig alarm. Tested with **WV-1716**, **GATE-01**, **GATE-02**, **GATE-03** and **GATE-04** version of Egardia / Woonveilig. Other versions might work, but unsure. Originally written for integration with [Home Assistant](https://home-assistant.io/) it can also by used to integrate with these alarms in other solutions.
**Note on GATE-02**
There seem to be multiple versions of software running on GATE-02 devices; we have received reports from GATE-02 users who successfully run this package in GATE-02 mode. Others have reported they needed to specify GATE-03 as their version to integrate their GATE-02.
Egardiadevice is the representation of the alarm control panel and the Egardiaserver can be used to handle alarm status changes including triggering. Test files are included for both device and server.
## EgardiaDevice ##
This script talks to the Egardia alarm control panel and can read and set its status. Note that if the alarm is triggered the state is not published through the interface available to this script. To be able to respond to alarm triggers, set up the Egardia Server (see below). For testing purposes have a look at the `test_egardiadevice.py` script. It's usage:
```bash
test_egardiadevice.py [-h] host port username password version
```
For example:
`python test_egardiadevice.py 192.168.1.X 80 user pass GATE-02`.
## EgardiaServer ##
This script captures codes generated by the Egardia alarm control panel after it was set up to forward the codes to the machine running the script ([see the Home Assistant docs](https://home-assistant.io/components/egardia#advanced-configuration): advanced configuration, step 1 to 3).
```bash
usage: egardiaserver.py [-h] [-P PORT]
Run the EgardiaServer
optional arguments:
-h, --help show this help message and exit
-P PORT, --port PORT the port number to run the server on (defaults to 52010)
--host HOST The host to run the server on (defaults to '', which is localhost). Specify this the IP address of your machine if you are having issues receiving messages.
```
The test script for the EgardiaServer is `test_egardiaserver.py` which tests if the `egardiaserver` you are running is accessible.
%prep
%autosetup -n pythonegardia-1.0.52
%build
%py3_build
%install
%py3_install
install -d -m755 %{buildroot}/%{_pkgdocdir}
if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi
if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi
if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi
if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi
pushd %{buildroot}
if [ -d usr/lib ]; then
find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst
fi
if [ -d usr/lib64 ]; then
find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst
fi
if [ -d usr/bin ]; then
find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst
fi
if [ -d usr/sbin ]; then
find usr/sbin -type f -printf "/%h/%f\n" >> filelist.lst
fi
touch doclist.lst
if [ -d usr/share/man ]; then
find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst
fi
popd
mv %{buildroot}/filelist.lst .
mv %{buildroot}/doclist.lst .
%files -n python3-pythonegardia -f filelist.lst
%dir %{python3_sitelib}/*
%files help -f doclist.lst
%{_docdir}/*
%changelog
* Fri May 05 2023 Python_Bot <Python_Bot@openeuler.org> - 1.0.52-1
- Package Spec generated
|