water
Device is a Glovary Firewall 6l with GPIO (2x5) on the motherboard.
The header is the not so standard dupont pins 2mm
GPIO is over the super I/O chip: iTE IT8613E
PIN 1 : SIO_PD0 (line 0)
PIN 2 : SIO_PD4 (line 38)
PIN 3 : SIO_PD1 (line 3)
PIN 4 : SIO_PD5 (line 39)
PIN 5 : SIO_PD2 (line 10)
PIN 6 : SIO_PD6 (line 40)
PIN 7 : SIO_PD3 (line 41)
PIN 8 : SIO_PD7 (line 9)
PIN 9 : GND
PIN 10 : VCC
not working:
> Circuits.GPIO.open("GPIO41", :output)
{:error, :not_found}
> Circuits.GPIO.open(41, :output)
{:error, :not_found}
> Circuits.GPIO.enumerate()
[]
> Circuits.GPIO.backend_info()
%{name: Circuits.GPIO.CDev, gpio_number_remapping: :none}
linux (toybox):
> sudo gpioset 0 "41=1" # turn on
> sudo gpioset 0 "41=0" # turn off
> gpioset --version
toybox 0.8.11
linux (libgpiod):
> sudo gpioset -t0 -c gpiochip0 "41=1" # turn on
> sudo gpioset -t0 -c gpiochip0 "41=0" # turn off
> gpioset --version
gpioset (libgpiod) v2.2
Copyright (C) 2017-2023 Bartosz Golaszewski
License: GPL-2.0-or-later
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Trending in Questions
I having some trouble figuring out if I have set myself too strict of standards for my production server. Currently I can handle 75% of r...
New
Documentation
While reading the Scoped Routes section, I noticed that the documentation currently refers to a problem without explainin...
New
Hello,
I’m trying to build a basic Phoenix web-app, and I’d like to use Tailwind.
However, when I launch mix phx.server, I get an error...
New
Hi everyone,
I am toying with the idea of building a “match maker” for giving personal help to people that wants to start coding.
I sta...
New
I recently noticed that Elixir’s Logger defaults its primary log level to :debug when no :logger, :level application configuration is pre...
New
I’m working on a small exercise involving update_in/3, and I came up with this solution:
data = %{
name: "Periodic Table",
category:...
New
I’ve got trouble wrapping my head around the order in which functions are called in this snippet (from Phoenix’s authentication):
toke...
New
Other Trending Topics
Edit: 2026 May 15 - This post is archived.
Mob is alive!!
Main docs: mob v0.7.11 — Documentation
A bit of explanation for the slightly c...
New
Hey, I’m Jesse and I’m the main contributor behind Dexter, a full-featured, lightning-fast Elixir LSP optimized for large codebases. It s...
New
I am happy to introduce the very α version of the new programming language compiled to BEAM.
Welcome Cure.
It has literally three kille...
New
Hobbes is a low-level distributed database for the Elixir programming language.
Hobbes provides a simple, safe, and scalable storage lay...
New
Hi everyone!
The first release candidate for the Expert language server project is now available!
We’ve published a press release detai...
New
A little off-topic, but I feel like people here have a good head on their shoulders.
I used to be quite good at making software. Was luc...
New
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #library
- #deployment
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #elixirconf
- #channels
- #exunit
- #discussion
- #code-sync
- #podcasts
- #javascript
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ai
- #ecto-query
- #elixirconf-us
- #blog-post
- #elixir-ls
- #phoenix_html
- #iex
- #graphql
- #genstage
- #websockets
- #supervisor
- #advent-of-code
- #distillery
- #processes
- #elixirconf-eu
- #api
- #forms
- #metaprogramming
- #hex










Showing Posts 1 to 6- Show Best Posts
- Show All (oldest first)
- Show All (newest first)
water
@benwilson512
I saw you changed the topic to the nerves section.
Is Circuits.Gpio only on a nerves installation? I’m trying to use the library without nerves.
fhunleth
Hi @water,
My first thought is that it’s a permissions issue and
Circuits.GPIOdoesn’t have access to the GPIOs. I see that you ransudoongpioset. I’m assuming that you’re not running Elixir as root and that if you removed thesudothatgpiosetwouldn’t work either.If it is a permissions issue and your device is running udev, you can add a udev rule to set the group/permissions on
/dev/gpiochip0so that Elixir can access it without running as root. Create a file like/etc/udev/rules.d/99-gpio.rulesfile with the following contents:Then create the
gpiogroup if you don’t already have one. E.g.sudo addgroup gpio. Also make sure that your user is in thegpiogroup in/etc/group.Then reload udev and rerun the rules:
If you look at
/dev/gpiochip0, it should have the right permissions andCircuits.GPIOshould find the GPIOs. You also shouldn’t need to runsudoforgpioset, etc.Hope this helps!
benwilson512
Hey @water that’s my bad, I saw Circuits.GPIO and assumed nerves!
water
thank you.
nixos configuration
water
Writing to the led works.
I can also read from an input.
But
Circuits.GPIO.set_interruptsgives an error and the error message is not clear.The example in the readme is the reverse of my button press result. I don’t think it matters?
water
I can’t get
gpiomonto work either.I’ll change the 2 buttons with switches.
Polling them every 500ms should do the trick.