Created
April 7, 2014 20:13
-
-
Save macrotis/10043405 to your computer and use it in GitHub Desktop.
rMBP screen manufacturer check (with fix to improve performance in extreme circumstances)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Check for "LSN" or "LP" | |
# "LP" => LG screen, classic IPS, susceptible to Image Retention | |
# "LSN" => Samsung screen, PLS, not susceptible to Image Retention | |
# Anything else? Not sure about that. | |
# The original version began the pipeline with | |
#ioreg -wl0 | |
# But recently, a gigantic dictionary got dropped in my I/O Kit registry (and I'm not sure why) | |
# and because the -l flag makes everything display, that was wasting a lot of CPU time. | |
# This version only reads the "EDID" key (hence -k EDID), greatly improving performance. | |
ioreg -w0 -k EDID | grep \"EDID\" | sed "/[^<]*</s///" | xxd -p -r | strings -6 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment