https://github.com/devstopfix/evrythng.thngpush
Elixir MQTT client for EVRYTHNG THNG-push
https://github.com/devstopfix/evrythng.thngpush
elixir iot mqtt
Last synced: 12 months ago
JSON representation
Elixir MQTT client for EVRYTHNG THNG-push
- Host: GitHub
- URL: https://github.com/devstopfix/evrythng.thngpush
- Owner: devstopfix
- License: apache-2.0
- Archived: true
- Created: 2017-03-05T21:01:24.000Z (almost 9 years ago)
- Default Branch: master
- Last Pushed: 2017-05-29T20:57:27.000Z (almost 9 years ago)
- Last Synced: 2025-03-09T03:08:05.538Z (12 months ago)
- Topics: elixir, iot, mqtt
- Language: Elixir
- Size: 15.6 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 3
-
Metadata Files:
- Readme: README.adoc
- License: LICENSE
Awesome Lists containing this project
README
# THNG-Push
Unofficial Elixir pub/sub client for https://evrythng.com/[EVRYTHNG.com].
An experiment in combining the https://evrythng.com/connected-devices-real-time-push-web-things/[real-time push web of things] with a http://nerves-project.org/[12 MB binary] running on the BEAM VM.
# Installation
If https://hex.pm/docs/publish[available in Hex], the package can be installed
by adding `thngpush` to your list of dependencies in `mix.exs`:
[source,elixir]
----
def deps do
[{:thngpush, "~> 0.17.0"}]
end
----
## Build
Build requires [emqtcc](git@github.com:emqtt/emqttc.git) to be available in a sibling folder.
[source,bash]
----
cd ..
git clone https://github.com/emqtt/emqttc.git
cd emqttc
make
----
= REPL
Connect and disconnect using a key read from ENV:
[source,elixir]
----
alias Evrythng.ThngPush.Client, as: Client
key = System.get_env("EVT_OPERATOR_KEY")
{:ok, pid} = Client.start_link(key)
GenServer.stop(pid)
----
Documentation can be generated with [ExDoc](https://github.com/elixir-lang/ex_doc)
and published on [HexDocs](https://hexdocs.pm). Once published, the docs can
be found at [https://hexdocs.pm/thngpush](https://hexdocs.pm/thngpush).
# License
Copyright © 2017 Devstopfix
Distributed under the Apache License either version 2.0. Not officially supported by https://evrythng.com/[EVRYTHNG.com].