5

Using OS X Mavericks, the CM Storm Devastator keyboard backlight does not light up. The light is usually activated by scroll lock being enabled, but in OS X, there is no such thing as scroll lock.

9

I have created a fork of the apple LED test script specifically to turn on and off the LED Backlight on cmstorm keyboards. This should also work for anyone who needs to turn on scroll lock on their external keyboards (which is the backlight key for most keyboards).

To use it:

  1. Download the binary and install it in your Applications folder

    wget https://github.com/pykler/led-backlight-osx/blob/master/led-backlight-osx?raw=true -O led-backlight-osx
    chmod +x led-backlight-osx
    mv led-backlight-osx /Applications
    
  2. Then you can either

  3. run it on the terminal like so

       /Applications/led-backlight-osx # turns the backlight on
       /Applications/led-backlight-osx off # turns the backlight off
    
  4. OR use an automator script as described in the following answer. Replace the automator script in step 11 with the following.

     ```/Applications/led-backlight-osx```
    
    • to create a script to turn it off create another automator script with the following

      /Applications/led-backlight-osx off

    • The details for the automator script are in the edit below.

EDIT: to add this as a keyboard shortcut you must use Automator as in @AlexanderTaylor's answer, in summary:

  1. Launch "Automator" from either Launchpad or Finder/Applications

  2. Choose "Service" type (For Catalina, first choose "Quick Actions" on "New")

  3. (On the left) "Library" -> "Utilities", drag "Run Shell Script" to the workflow pane.

  4. At the top of the workflow pan, choose "no input" in "any application"

  5. For "pass input" choose "as arguments"

  6. For "shell" choose "/bin/sh"

  7. Paste in this script:

     /Applications/led-backlight-osx
    
  8. Click "File" -> "Save", save it as "CMStormLedOn"

  9. Go to System Preferences -> Keyboard -> Shortcuts -> Services -> CMStormLedOn and click on the shortcut +ScrLk. (it will show up as ⌘+F14)

Done. Now typing +ScrLk should turn those LEDs on.

| improve this answer | |
  • Do you have an updated version for Mojave? – Zach Saucier Jun 27 '19 at 15:20
  • Works in Catalina just fine. Thank you. – SomeGuyOnAComputer Jan 21 at 18:00
  • Scratch my previous (deleted) comment. Needed to run privileged. Thanks. – RayfenWindspear Mar 26 at 17:09
7

Summary: solve by downloading Apple's keyboard LED test tool, which tests keyboard lights by enabling scroll lock, num lock and caps lock. Make a keyboard shortcut that runs a script that runs the LED test tool and terminates the script while scroll lock is on.

  1. Go here: https://developer.apple.com/library/mac/samplecode/HID_LED_test_tool/Introduction/Intro.html
  2. Click the little "Download sample code" button
  3. Open the downloaded folder and go to Build / Release
  4. Drag the HID LED test tool file to your Applications folder
  5. Launch the OS X "Automator" program
  6. Choose "Service" document type
  7. Under "Library", click "Utilities", and drag "Run Shell Script" to the blank area / workflow pane.
  8. For "selected service receives" choose "no input" in "any application" (important)
  9. For "pass input" choose "as arguments" (important)
  10. For "shell" choose "/bin/bash"
  11. Paste in this script:

    /Applications/HID\ LED\ test\ tool &
    pid=$!
    sleep 3
    kill $pid
    
  12. Click "run" to test. After 3 seconds, your keyboard should remain in a state with num lock and scroll lock enabled, and all the keys should be lit up. Yay! Continue to assign keyboard shortcut to do this.

  13. Click "File" > "Save", "Save service as" : "Devastator LED Lighter"
  14. Go to System Preferences > Keyboard > Shortcuts > Services > General > "Devastator LED Lighter"
  15. Assign a shortcut. Scroll lock and F keys didn't work for me. I ended up choosing ⌘ Command+1.

You're done!

Try your shortcut. If nothing happens, test by clicking "Play" in the automator if you skipped that part. If that doesn't work, the bash script may need to be updated, or maybe the path to the LED test tool is wrong. Then double check steps 8 and 9. Lastly, try making an automator document that does a "Launch Application" command instead of a bash script, and see if you can get any program at all to launch, such as TextEdit, using a keyboard shortcut.

| improve this answer | |
  • This solution worked perfectly for me. Was able to Hotkey to Scroll Lock (F14) as well. – Mike Nov 26 '14 at 15:30
  • when i pasted the script it said no such files in directory – user112043 Feb 1 '15 at 19:44
  • Did you do step 4 as well? – nohillside Feb 1 '15 at 20:00
  • Wasn't able to do Scroll Lock (F14) but was able to do ⌘+F14 – Pykler Jun 22 '15 at 15:34
  • The site you link to is now down :( – Zach Saucier Jun 27 '19 at 15:15
1

If you are experiencing problems, even though you followed the above steps. — Try the below, it worked for me:

Simply plug your keyboard into another USB port on your Mac and then try :)

| improve this answer | |

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .