Custom LED behavior, is this possible?

TP-Link Archer C6 v3.20, OpenWRT 24.10.
How to configure the behavior of two LEDs in a custom way?

  1. No cable present in the WAN port = nothing lights up.
  2. The cable is present, but there is no internet connection (e. g. no IP address) = amber:wan lights up continuously.
  3. The cable is present and the connection is fine = green:wan lights up or flashes.

This is the default logic of these LEDs on stock firmware. Is this possible on OpenWRT?

You will need to create specific scripts for what you want it to do.

https://forum.openwrt.org/search?q=wan%20led%20script

Does this help?

No, there is no such trigger. Simply "link up" detects the WAN cable, but does not detect the internet connection itself. Scripts mentioned here do the opposite: they cannot detect if the cable is disconnected.

A script isn't needed for cable connectivity.

To be clear, you did see the script for WAN Internet link?

I wasn't sure if you made your comment because the example used blue instead of amber.

https://www.reddit.com/r/Proxmox/comments/13q31n0/is_there_a_command_or_some_way_to_tell_which_nic/

https://www.kernel.org/doc/Documentation/ABI/testing/sysfs-class-net