dmitry-s93 / MControlCenter

An application that allows you to change the settings of MSI laptops running Linux
GNU General Public License v3.0
236 stars 61 forks source link

User mode switch does not handle all memory addresses (MSI Modern 15 A11M) #40

Closed timschneeb closed 2 months ago

timschneeb commented 1 year ago

Hey, I noticed that my laptop model (MSI Modern 15 A11M 1552EMS1.1180721) appears to have two additional memory addresses that are altered when I switch between user modes. Some time ago, I wrote a small Windows app to monitor the EC ram while I tweaked settings in MSI Center Pro to find out memory addresses specific to my model.

This was the data I was able to collect from switching between user modes and noting down updated addresses that my tool spit out:

Super Battery:
     0x79 => 70 (0x46)
     0x91 => 70 (0x46)
     0xD2 => 194 (0xC2)
     0xD3 => 129 (0x81)
     0xD4 => 13 (0x0D)
     0xEB => 143 (0x8F)

Silent:
     0x79 => 75 (0x4B)
     0x91 => 70 (0x46)
     0xD2 => 193 (0xC1)
     0xD3 => 130 (0x82)
     0xD4 => 29 (0x1D)
     0xEB => 128 (0x80)

Balanced:
     0x79 => 75 (0x4B)
     0x91 => 70 (0x46)
     0xD2 => 193 (0xC1)
     0xD3 => 131 (0x83)
     0xD4 => 13 (0x0D)
     0xEB => 128 (0x80)

High Performance:
     0x79 => 80 (0x50)
     0x91 => 75 (0x4B)
     0xD2 => 192 (0xC0)
     0xD3 => 131 (0x83)
     0xD4 => 13 (0x0D)
     0xEB => 128 (0x80)

MControlCenter currently sets shift mode 0xD2, fan flags 0xD4, and the super battery mode flag in 0xEB. If we ignore the backlight level 0xD3, there are two addresses left, that aren't handled by this app yet.

Both of these addresses are directly located in the address ranges, which also contain either CPU or GPU temperatures & fan speeds. Still, I'm not entirely sure what these are actually for. My guess: 0x79: CPU power? 0x91: GPU power?

I documented all addresses I found for my model as a hex pattern file for ImHex annotations if that helps: https://github.com/ThePBone/msi-ec-modern/blob/master/msi_modern_15_a11m_ec.hexpat

It would be great if this app would also set 0x79 and 0x91 (maybe other models use these addresses as well?).

dmitry-s93 commented 1 year ago

Hello.

Could you check if there are any performance or fan speed changes when changing the values of 0x79 and 0x91? If necessary, I can build an application in which, when changing modes, values will be set at these addresses.