Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Doesn't work with my new MacBook Air #98

Open
forthrin opened this issue Jan 9, 2020 · 9 comments
Open

Doesn't work with my new MacBook Air #98

forthrin opened this issue Jan 9, 2020 · 9 comments

Comments

@forthrin
Copy link

forthrin commented Jan 9, 2020

MacBook Air (2017). macOS 10.14.6. smcFanControl 2.6.

Changes to fan speeds don't take.

Some times the fan speeds up after a while, but mostly not.

Doesn't work via the CLI either. (Reading back the fan value gives the value I've asked for, though the fan itself does not adhere to the value.)

Had no problems with this with earlier Macs, so may be related to this particular model.

PS! Enclosing my CLI tools, maybe they could be of use to someone (or could be included in the basic product for ease of use.)

alias smc="/Applications/smcFanControl.app/Contents/Resources/smc"

smcr() {
  smc -k $1 -r | cut -d " " -f 7
}

fan() {
  if [[ $# -eq 1 ]]; then
    smc -k F0Mn -w $(printf "%x" $(echo $(($1 << 2))))
  else
    printf "%.0f\n" $(smcr F0Mn)
  fi
}
@Razique
Copy link

Razique commented Nov 12, 2021

After reading around, I have found that the values that the tool expects is not a decimal to hex conversion.
Here's my snippets file:

## To convert decimal to string of bytes

# RPM value is 4400
python3 -c "import struct; print(bytearray(struct.pack('f', 4400)).hex())"

# RPM value is 1100
python3 -c "import struct; print(bytearray(struct.pack('f', 1100)).hex())"

# Activate 'forced' mode
/Applications/smcFanControl.app/Contents/Resources/smc -k "F0Md" -w 01
/Applications/smcFanControl.app/Contents/Resources/smc -k "F0Tg" -w 00007a44

# To restore to auto mode.
/Applications/smcFanControl.app/Contents/Resources/smc -k "F0Md" -w 00

@forthrin
Copy link
Author

Thanks. However I'm getting an error similar to #131. sudo doesn't help. Building the lastest Git doesn't help. Maybe @hholtmann knows the status here?

Error: SMCWriteKey() = e00002bc
Error: SMCWriteKey() = e00002c1

@Razique
Copy link

Razique commented Nov 13, 2021

To confirm, you are running the M1 CPU? If so, AFAIK, the tool isn't compatible with that yet :/

@forthrin
Copy link
Author

forthrin commented Nov 14, 2021

An important clarification:

WORKS: Changing fan speed from the macOS top bar
WORKS: Reading fan speed from CLI
FAILS: Writing fan speeds from CLI

$ sudo /Applications/smcFanControl.app/Contents/Resources/smc -k F0Md -w 01
Error: SMCWriteKey() = e00002bc

MacBook Air (2017). macOS 11.6. smcFanControl 2.6 (latest Homebrew / Git).

@Razique
Copy link

Razique commented Nov 14, 2021

@forthrin do these commands work without sudo? They do here. In theory, you shouldn't need sudo since you should be able to make changes to your session without escalating privileges?
Does this one give you the same output?

/Applications/smcFanControl.app/Contents/Resources/smc -k "F0Md" -w 00

@forthrin
Copy link
Author

$ /Applications/smcFanControl.app/Contents/Resources/smc -k "F0Md" -w 00
Error: SMCWriteKey() = e00002bc

@Razique
Copy link

Razique commented Nov 14, 2021

Oh I see that you have the 2.6 version, try this one: https://github.com/hholtmann/smcFanControl/releases/tag/2.6.1%C3%9F1 (2.6.1 beta). I believe that it fixes that issue.

@forthrin
Copy link
Author

forthrin commented Nov 16, 2021

$ git log
commit de3988463a8fbabb4887c16cb3ac0acb212f1405 (grafted, HEAD, tag: 2.6.1ß1)
Date:   Sun Aug 12 00:53:25 2018 +0200
$ ./smc -k F0Md -w 01
Error: SMCWriteKey() = e00002bc

@Razique
Copy link

Razique commented Nov 16, 2021

hmmm, I don't know then :/ sorry for that

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants