nagisa / msi-rgb

Linux utility for controlling RGB header on select MSI motherboards
ISC License
416 stars 40 forks source link

MSI B450 Tomahawk Max IO field behaviors (incomplete but this might help) #115

Open dberliner opened 4 years ago

dberliner commented 4 years ago

The B450 Tomahawk Max uses a different SIO chip, NCT6797D-M. This appears to be similarly manufactured and (un)documented so we're SOL on official sources.

Like from your blog post the 8 32-bit fields that seem to control things are: E0 AAAA SSSS DDDD FFFF F0 RRRR GGGG BBBB VVWW

What the Dragon software sets the values to

E0 AAAA BBBB CCCC DDDD
F0 RRRR GGGG BBBB XXYY

What the app sets the bytes to
AAAA -> 00000000 Flashing Cycle, Breathing cycle
        000000E0 Steady, Color Cycle, Breathing, flashing, double flashing
        000000F is added sometimes with no apparent purpose
BBBB -> 0 Color cycle, Flashing (while on), Double flashing (while on), Steady
        1 Breathing Cycle, Flashing Cycle, Flashing (while off), Double flashing (while off)
        9 Breathing
        All values sometimes have F in a more significant position (F0, F1, F9)
        Adjusts with random so suit whatever existing function "random" is

CCCC -> 00000000 Flashing Cycle, breathing cycle
        1011FFFF Steady, Color Cycle
        0011FFFF Breathing, flashing, Double flashing

DDDD -> 00003400 Color Cycle, Breathing, Flashing, steady, Double Flashing
        0000000F Breathing Cycle, Flashing Cycle

VVWW -> 0F00FFFF Breathing Cycle, Flashing Cycle
        FE01007F Color Cycle, Breathing, Flashing, Double Flashing, Steady

This alone cannot be everything, flashing cycle and breathing cycle are identical.

A few other notes: EE (from the source comments) is ignored, always 00 For steady values only the most significant nibble of R, G and B is looked at, but the app sets the entire 4 bytes. Modifying XX gets overridden immediately and YY varies by function. On flashing YY is either "7f" or the lights go off. On steady YY has some effect on which bytes are read from RGB fields, but the association is not clear to me. XX can be used to switch from steady to pulsing

I'll try to get a mock up together to at least set a few basic LED functions for this board together later this week. Let me know if there's anything else you think I should look at.