PragmaticBookshelf

PragmaticBookshelf

Forum Sponsor

Build a Weather Station with Elixir and Nerves (PragProg)

Alexander Koutmos
Bruce A. Tate @redrapids
Frank Hunleth @fhunleth

edited by Jacquelyn Carter @jkcarter

The Elixir programming language has become a go-to tool for creating reliable, fault-tolerant, and robust server-side applications. Thanks to Nerves, those same exact benefits can be realized in embedded applications. This book will teach you how to structure, build, and deploy production grade Nerves applications to network-enabled devices. The weather station sensor hub project that you will be embarking upon will show you how to create a full stack IoT solution in record time. You will build everything from the embedded Nerves device, to the Phoenix backend and even the Grafana time-series data visualizations.

Elixir as a programming language has found its way into many different software domains, largely in part to the rock solid foundation of the Erlang virtual machine. Thanks to the Nerves framework, Elixir has also found success in the world of embedded systems and IoT. Having access to all of the Elixir and OTP constructs such as concurrency, supervision, and immutability makes for a powerful IoT recipe. Find out how to create fault-tolerant, reliable, and robust embedded applications using the Nerves framework.

Build and deploy a production grade weather station sensor hub using Elixir and Nerves, all while leveraging the best practices established by the Nerves community for structuring and organizing Nerves applications. Capture all of your weather station sensor data using Phoenix and Ecto in a lightweight server-side application. Efficiently store and retrieve the time-series weather data collected by your device using TimescaleDB (the Postgres extension for time-series data). Finally, complete the full stack IoT solution by using Grafana to visualize all of your time-series weather station data. Discover how to create software solutions where the underlying technologies and techniques are applicable to all layers of the project.

Take your project from idea to production-ready in record time with Elixir and Nerves.


Alexander Koutmos has been writing software professionally for almost a decade and has been working primarily with Elixir since 2016. He currently maintains a few Elixir libraries on Hex and also runs a software consultancy (www.stagira.com).

Bruce Tate is a kayaker, programmer, and father of two from Chattanooga, Tennessee. The author of more than 10 books has been around Elixir from the beginning. He is the founder of Groxio, a company that trains Elixir developers.

Frank Hunleth is an embedded systems programmer, OSS maintainer, and Nerves core team member. When not in front of a computer, he loves running and spending time with his family.


Don’t forget you can get 35% off with your Devtalk discount! Just use the coupon code “devtalk.com" at checkout :+1:


Posted via Devtalk (see this thread for details).

Most Liked

stefanluptak

stefanluptak

OK, so I found an european e-shop, that has all the parts in stock, except for the Raspi. Raspi is in stock in another e-shop we have here. Also, I didn’t link the MicroSD card + reader and the micro USB cables, since I own these already. Hope this could help somebody. :slight_smile:

akoutmos

akoutmos

Author of Build a Weather Station with Elixir and Nerves

:partying_face: Beta 2 of the book has just landed :partying_face:

Feel free to check it out at: Build a Weather Station with Elixir and Nerves: Visualize Your Sensor Data with Phoenix and Grafana by Alexander Koutmos, Bruce A. Tate, Frank Hunleth

The updates for this beta include the addition of chapter 4 and chapter 5 as well as addressing some errata. Chapter 4 goes over how to publish data from your Nerves device to a Phoenix API that you will be writing. The Phoenix API is backed by TimescaleDB so you can store and query all that time-series goodness :wink:. Chapter 5 goes over how to set up Grafana and how to visualize your time-series data that is stored in TimescaleDB. By the end of the book you’ll be able to build a (near) real-time weather dashboard like so:

Be sure to check it out and feel free to reach out with any feedback! Happy hacking :slight_smile:.

margareteldridge

margareteldridge

@lucaong We do have another Nerves book in the works – stay tuned. I am not sure when it will be ready for beta as only a few chapters are written so far.

Where Next?

Popular in Books Top

peerreynders
Don’t forget you can get 35% off the ebook using the code: devtalk.com :023: Note: Check out this thread for help running code in lat...
New
AstonJ
by Benjamin Tan Wei Hao The Little Elixir & OTP Guidebook gets you started programming applications with Elixir and OTP. You begin w...
New
AstonJ
By Simon St. Laurent If you’re new to Erlang, its functional style can seem difficult, but with help from this hands-on introduction, y...
New
AstonJ
Don’t forget you can get 35% off the ebook using the code ‘devtalk.com’ :023: Current: Search Original: Search For those looking for ...
New
radar
:wave: You might remember me as the author of Joy of Elixir: https://forum.elixirforum.com/t/joy-of-elixir-self-published-free/ I’ve got...
New
New
PragmaticBookshelf
Rebecca Le and Zach Daniel @zachdaniel _edited by Kelly Lee @k.lee _ Ash Framework is the game-changing toolkit for Elixir developers. W...
New
mchean
By @emadb OVERVIEW Author Emanuele DelBono guides readers along the first steps of mastering the Elixir programming language in Elixi...
New
kokolegorille
https://www.packtpub.com/application-development/mastering-elixir A new resource, it seems… I did not read it (yet?). Anyone?
New
peerreynders
Don’t forget you can get 35% off the ebook with your forum discount, use code ‘devtalk.com’ :023: Available in beta now
New

Other popular topics Top

mcarvalho
What is the difference between System.get_env and Application.get_env? For example, what are best practices to use one versus another.
New
skosch
To my knowledge, put_in, Map.update etc. all have the one limitation of not automatically creating intermediate keys when needed (for exa...
New
lessless
I believe there are people here who are dealing with CSV files import on the daily basis, and since Excel is a really popular tool there ...
New
Qqwy
Original source of discussion: This topic on the Pragmatic Programmers’ Functional Web Development with Elixir, OTP, and Phoenix forum. ...
New
vrod
I am using the Starship cross-shell prompt – it seems pretty nice, but I get some errors: [WARN] - (starship::utils): Executing command ...
New
SoCreat
i’m a new one to elixir which editor can i use vs code? or atom? Thanks! :smiley:
New
vonH
When I run the Plug and I recompile I wind up having to use Ctrl C to quit iex and start again. Witht the help of rlwrap I can use the cu...
New
fayddelight
I tried installing elixir 1.11.2 erlang 23.3.4 via asdf in my zsh shell. Enabled the versions locally and globally. When I list them ...
New
romenigld
I am trying to run a deploy with docker and I successfully runned with this command: docker build -t romenigld/blog-prod . but when I t...
New
svb
Hi! Currently I want to submit a form by pressing the Enter key. However, since my input field is of type “textarea” this is just adds a...
New

Latest on Elixir Forum

Elixir Forum

We're in Beta

About us Mission Statement