Skip to content

Instantly share code, notes, and snippets.

@Natetronn
Last active May 12, 2023 00:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Natetronn/4c46e195a01c066cdfdc8f07dcb5991f to your computer and use it in GitHub Desktop.
Save Natetronn/4c46e195a01c066cdfdc8f07dcb5991f to your computer and use it in GitHub Desktop.
Netgear R7000P LEDS Startup Script
#!/bin/sh
#
# Netgear R7000P Startup Script
#
# Ordered by physical LED, from left to right
#
# GPIO LED Notes
# 0 ?
# 1 ?
# 2 Power Enable/Disable LED (gpio enable 2 turns led off)
# 3 Power Toggle Led Coler (White/Amber)
# 4 Disable 4 None led - It seems that register 4 is enabled by default. If it is disabled, register 5 does not work)
# 5 Wifi On/Off None led - Toggles Wifi On/Off (gpio enable 5 turns on)
# 6 Reset None led - Full Reset (default: enabled - gpio disable 6 resets router - requires user/password update etc)
# 7 Internet Toggle Led Color (White/Amber)
# 8 Internet Enable/Disable Led (gpio enable 8 turns led off)
# 10 2.4 GHz Enable/Disable Led (gpio enable 10 turns led off)
# 9 5 GHz Enable/Disable Led (gpio enable 9 turns led off)
# 14 USB 3.0 Enable/Disable Led (gpio enable 14 turns led off)
# 15 USB 2.0 Enable/Disable Led (gpio enable 15 turns led off)
# et Ethernet 1 use et commands
# et Ethernet 2 use et commands
# et Ethernet 3 use et commands
# et Ethernet 4 use et commands
# 13 WiFi On/Off Enable/Disable Led (gpio disable 13 turns led off)
# 11 WPS Enable/Disable Led (gpio disable 11 turns led off)
# 12 ?
for i in 2 8 9 10 14 15; do gpio enable $i; done
for i in 11 13; do gpio disable $i; done
# /jffs/et robowr 0x0 0x18 0x1ff # ?
/jffs/et robowr 0x0 0x18 0x0 # Lights rapidly flash white
/jffs/et robowr 0x0 0x1a 0x0 # Then shut off
# /jffs/et robowr 0x0 0x16 0x0 # ?
#
# note: et didn't exists on my device, I therefore turn on jffs support and uploaded a copy to /tmp using scp and finally move it to /jffs
# if et exists on your device, by running et directly in cli, you can remove the /jffs/ prefix from the previous commands
# see DD-WRT Wiki for more on using jffs
@Natetronn
Copy link
Author

Natetronn commented May 11, 2023

For those missing et (mini linux guide):

  1. Download et from here: https://forum.dd-wrt.com/phpBB2/viewtopic.php?p=1203814#1203814 - or from backup: https://www.mediafire.com/file/pdysgl093sqzfie/et/file
  2. Enable ssh - It's under Services > Services > Secure Shell - I added a public key with password enabled and login with router password.
  3. Enable and clean jffs - see More on JFFS link above and then read Directions for (normal) users: using Web-GUI Interface in that wiki - probably best to reboot to make sure it's enabled and you're seeing Available and Free space specs.
  4. scp /path/to/et root@192.168.x.x:/tmp/et - update the path to et file, which you just downloaded to your local machine, as well as update your router's ip address accordingly; most likely 192.168.1.1
  5. mv /tmp/et /jffs - move et from /tmp into /jffs
  6. Add script above as a Startup Script via the WebGUI (or via other methods listed in Startup Scripts Wiki)
  7. Reboot

@Natetronn
Copy link
Author

Natetronn commented May 11, 2023

@Natetronn
Copy link
Author

Comments removed:

#!/bin/sh
#
for i in 2 8 9 10 14 15; do gpio enable $i; done
for i in 11 13; do gpio disable $i; done
/jffs/et robowr 0x0 0x18 0x0
/jffs/et robowr 0x0 0x1a 0x0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment