Use the LEDs

From F256 Foenix
Revision as of 05:25, 15 February 2025 by 1BitFeverDreams (talk | contribs) (→‎LED availability: clarification on which machine have RGB LEDs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

How to Use the LEDs

LED availability

Here's a chart for the availability of the LEDs for the 4 machines

LED Name F256 Jr. F256 Jr.2 F256K F256K2
Power yes yes yes, RGB yes, RGB
L0 status yes yes yes yes
L1 status yes yes yes yes
SD Card Access yes yes yes, RGB yes, RGB
Caps Lock no no yes, RGB yes, RGB
Network no no no yes, RGB

L0 and L1 are status LED on the board itself. (to do: state their normal purpose in this page)

System Control Register 0 at 0xD6A0

Here's the register that can let you assume manual control for the LEDs. In order to take control of a given LED, set the appropriate bit to 1.

Address R/W Name 7 6 5 4 3 2 1 0
0xD6A0 W SYS0 RESET NETW_LED CAPLOCKS_LED BUZZ L1_LED L0_LED SD_LED PWR_LED

System Control Register 1 at 0xD6A1

This register can control the behavior of the onboard L0 and L1 LEDs

Address R/W Name 7 6 5 4 3 2 1 0
0xD6A1 W SYS1 L1_RATE1 L1_RATE0 L0_RATE1 L0_RATE0 SID_ST PSG_ST L1_MN L0_MN

If L1_MN, L0_MN are set, they are under manual control. This allows to manually turn them on or off using the SYS0 register at 0xD6A0. If they are cleared, they will flash according to the L1_RATE and L0_RATE settings.

RATE1 RATE0 Rate
0 0 1s
0 1 0.5s
1 0 0.4s
1 1 0.2s

LED Color Registers on the K and K2

Set these RGB byte values for every LED other than L0 and L1. Note that these registers are Write only. The color will only change if you assumed manual control of these LEDs using the corresponding SYS0 system control register bits above.

LED Name Red register Green register Blue register
Power 0xD6A7 0xD6A8 0xD6A9
SD Access 0xD6AA 0xD6AB 0xD6AC
Caps Lock 0xD6AD 0xD6AE 0xD6AF
Network (K2 only) 0xD6B3 0xD6B4 0xD6B5