Skip to content
View in the app

A better way to browse. Learn more.

Armbian Community Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

How do I persist GPIO changes across reboots?

Featured Replies

I have Armbian up and running on a Rock Pi S with a PoE HAT. To enable the audio jack on the PoE HAT I had to run the following commands as mentioned on the official Rock Pi S PoE Hat wiki.
 

# echo 15 > /sys/class/gpio/export 
# echo out > /sys/class/gpio/gpio15/direction
# echo 1 > /sys/class/gpio/gpio15/value

 

Once enabled, the audio works as needed. However, every time the device is rebooted I have to SSH in and run these commands again to re-enable audio out which is obviously not ideal.

 

How can I persist these changes between reboots?

 

Solved by PHLAK

  • Author
  • Solution

I was able to solve this by using systemd-tmpfiles to modify these values on boot. Specifically I created a file `/etc/tmpfiles.d/enable-audio-jack.conf` with the following contents.

 

w /sys/class/gpio/export - - - - 15
w /sys/class/gpio/gpio15/direction - - - - out
w /sys/class/gpio/gpio15/value - - - - 1

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.