Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/t0mer/redalert-windows-service
Redalert Windows service is a service that listen to redalerts and publishes it using Mqtt or Telegram bot
https://github.com/t0mer/redalert-windows-service
csharp home-automation mosquitto mqtt telegram telegram-bot
Last synced: 23 days ago
JSON representation
Redalert Windows service is a service that listen to redalerts and publishes it using Mqtt or Telegram bot
- Host: GitHub
- URL: https://github.com/t0mer/redalert-windows-service
- Owner: t0mer
- License: apache-2.0
- Created: 2019-11-24T20:28:01.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2022-10-19T06:23:17.000Z (about 2 years ago)
- Last Synced: 2024-10-02T08:07:07.611Z (about 1 month ago)
- Topics: csharp, home-automation, mosquitto, mqtt, telegram, telegram-bot
- Language: C#
- Homepage:
- Size: 5.14 MB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: License
Awesome Lists containing this project
README
# Red Alert Windows Service
__________________________________________c# based windows service that reads json from [Oref Website](https://www.oref.org.il/) and publishes it over MQTT Protocol and/or Telegram Bot.
## Installation
In order to install the service download the code and compile it. than move the binary files as listed below in to a new folder under Program Files:
- RedAlert.exe
- RedAlert.exe.config
- Newtonsoft.Json.dll
- M2Mqtt.Net.dll
And run the following command from Command line (Make sure to run as admin):
```
c:\Windows\Microsoft.NET\Framework64\v4.0.30319 "c:\Program Files\RedAlert\RedAlert.exe"
```## Service configuration
### RedAlert.exe.config
In order to use this service, some configuration need to be done.
Open RedAlert.exe.config in any text editor and edit the required settings as follows:
```xml
```
[How to create Telgram Bot](https://techblog.co.il/2019/11/%D7%A9%D7%9C%D7%99%D7%97%D7%AA-%D7%94%D7%95%D7%93%D7%A2%D7%95%D7%AA-%D7%9C%D7%A2%D7%A8%D7%95%D7%A5-%D7%98%D7%9C%D7%92%D7%A8%D7%9D-%D7%91%D7%93%D7%A8%D7%9A-%D7%94%D7%A7%D7%9C%D7%94/)## Usage
### Adding Sensor in Home-Assistant
#### Get full json (including date and id)
```yaml
- platform: mqtt
name: "Red Alert"
state_topic: "/redalert/"
# unit_of_measurement: '%'
icon: fas:broadcast-tower
value_template: "{{ value_json }}"
qos: 1
```#### Get json with alert areas only
```yaml
- platform: mqtt
name: "Red Alert"
state_topic: "/redalert/"
# unit_of_measurement: '%'
icon: fas:broadcast-tower
value_template: "{{ value_json.data }}"
qos: 1
```