Questions tagged [nerves-project]

Questions about Nerves Project

Official website: https://nerves-project.org/

15 questions
2
votes
0 answers

Nerves Project Circuits SPI Clock not initialised

I cannot get the SPI to work. I am trying to interface an IC mcp2515. It is an SPI to CAN interface. I probed the CE pins (GPIO 8 and GPIO 7) and SCLK (GPIO 11) with the oscilloscope but got nothing. these are deps defp deps do [ {:nerves, "~>…
Umer Kiani
  • 3,783
  • 5
  • 36
  • 63
2
votes
1 answer

Elixir - Nerves BLE Library Recommendation

I'm working on an IoT project and I recently discovered nerves. At the moment I'm using node.js with noble, that I would like to replace with nerves, for the gateway on Raspberry Pi. I didn't find anything similar and maintained for Elixir. Does…
Pietro
  • 1,815
  • 2
  • 29
  • 63
2
votes
0 answers

Cannot compile sqlite in Nerves firmware

This question has come up a bit by many others in #nerves slack. Essentially, you try to include sqlite in Nerves firmware (usually via esqlite) and it fails on mix firmware during compilation: ===> Compiling esqlite ===> Compiling…
Jon Jon
  • 21
  • 1
2
votes
1 answer

How to setup wlan0 in Nerves

I created a new Elixir Nerves project and try to connect my Raspberry Pi Zero W to the local wifi. In my target.exs, I set the following config: config :nerves_network, regulatory_domain: "US" config :nerves_network, :default, wlan0: [ …
Peter
  • 1,110
  • 10
  • 25
2
votes
2 answers

Elixir Nerves Phoenix Umbrella Project - Running Phoenix error: 'CoreServices/CoreServices.h' file not found

Following this Nerves Tutorial to setup a phoenix-framework, I get this error at the end of the tutorial when trying to run the server. cjsMBP15:ui cj$ mix phoenix.server ==> fs (compile) Compiling c_src/mac/cli.c In file included from…
DogEatDog
  • 2,899
  • 2
  • 36
  • 65
1
vote
1 answer

Elixir GenServer handle_cast not being invoked

I am having an issue with Handle Cast. After the module loads it calls periodic_comm which after every 5 seconds calls the save_data method. In my save_data method the logs are being printed but the statement does nothing. GenServer.cast(__MODULE__,…
Umer Kiani
  • 3,783
  • 5
  • 36
  • 63
1
vote
1 answer

How to get current device IP using Elixir/Nerves

I'm writing a UPnP adapter for a Nerves project and as such need to be able to respond to certain requests with the devices IP address. Is there an easy one-liner way of doing so? My project is using VintageNet along with nerves-pack, and it is…
Tom Haines
  • 123
  • 3
  • 9
1
vote
1 answer

is key and cert required with CA for SSL MQTT

I started mosquitto broker with SSL using CA,cert and key when I am trying to connect to broker the library in elixir tortoise is asking me to put the key and cert with certifi. When I looked into certifi it is showing the list of CA can we use this…
Yugandhar Chaudhari
  • 3,831
  • 3
  • 24
  • 40
1
vote
1 answer

Running mix deps.get throws :erlang.binary_to_atom argument error

I'm building a Nerves project and am attempting to verify my custom firmware will be built with the main Nerves application following the instructions here. I've set up a UI project with Phoenix and have the custom image in its own directory under a…
brendon.otto
  • 44
  • 1
  • 8
1
vote
1 answer

Nerves, Phoenix, GPIO?

I have an umbrella app setup as described the docs, and all is compiling nicely. One question that I'm left with is how does the Phoenix app in this scenario interact with GPIO? elixir_ale will only compile on the target device, and I can't…
Matt Darby
  • 6,294
  • 4
  • 27
  • 35
0
votes
1 answer

Decoding endian(?) data from a sensor

I am not sure I even understand what is going on here with this data, but I am trying to replicate functionality like here, here or here to decode the data I am receiving over UART from my Plantower PMS5003 sensor (see datasheet) sensor in…
Zen
  • 7,197
  • 8
  • 35
  • 57
0
votes
1 answer

How to copy CRT file on a Nerves device

I want to copy ca file to establish ssl connection. I am placing the CA inside lib lib/ mymodule.ex #using the ca path here mycrt.crt and then using mix firmware I am giving the relative path like this def getPath() do {path,0} =…
Yugandhar Chaudhari
  • 3,831
  • 3
  • 24
  • 40
0
votes
1 answer

Task like GPIO read forever should be a recursive function or GenServer?

I am monitoring a value continuously for detection. I am wondering will it work reliably if it is a recursive function? Or I should create a Genserver and call it continuously so that it can handle failures? Which are the best cases for using…
Yugandhar Chaudhari
  • 3,831
  • 3
  • 24
  • 40
0
votes
2 answers

Error when iex -S mix on fresh nerves project

Elixir Version : 1.6.0 Compiled with OTP 20 Erlang OTP: 20 I installed nerves and created new nerves project when I set MIX_TARGET=rpi3. I get this error ** (FunctionClauseError) no function clause matching in…
Yugandhar Chaudhari
  • 3,831
  • 3
  • 24
  • 40
-1
votes
1 answer

How do I encrypt nerves project files on memory card?

When I burn memory card by mix.burn. Anybody can read content of my card by simple usb reader. I have sensitive keys and authentication credentials on memory. how do I encrypt or obfuscate the card?
Yugandhar Chaudhari
  • 3,831
  • 3
  • 24
  • 40