Reducing the Need for Manual Reload of Color Calibration when Docking in Windows 7

Windows 7 has native support for monitor color calibration (though the OS X calibration wizard is more advanced). Unfortunately, at least with my MacBook Pro 5,3 and Apple Cinema display, Windows unloads the calibrations every time the external display is hot-plugged into my laptop. This forces me to go to Control Panel | Color Management | Advanced and click Reload current calibrations on a regular basis. I’ve even pinned this applet to my start menu for this purpose.

I’ve been looking for a command-line way to invoke this so that I can automate it and haven’t come up with anything other than possibly invoking colorcpl.exe and programmatically selecting the Advanced tab and sending a click to the Reload current calibrations button. However, poking around, I recently discovered that there is a scheduled task “\Microsoft\Windows\WindowsColorSystem\Calibration Loader”. This thing appears to do exactly what I want: reload the current calibrations.

The Action of the task is a “Custom Hander” which means it’s a COM handler. The XML definition of this task is in “%systemroot%\System32\Tasks\Microsoft\Windows\WindowsColorSystem\Calibration Loader”. Looking in there you will find the COM CLSID:

  <Actions Context="Group">
    <ComHandler>
      <ClassId>{B210D694-C8DF-490D-9576-9E20CDBC20BD}</ClassId>
    </ComHandler>
  </Actions>

I’ll have to dig into that at a later time.

Meanwhile, my main use-case is docking my laptop which usually has a closed lid or has just been re-opened so it is waking from sleep and locked. There are system events defined for those cases. The other case is just hot-plugging my monitor which is comparatively rare and doesn’t seem to generate an event. In any case, I can add the resume-from-sleep and workstation-unlocked events to the triggers for the calibration re-load task. This largely addresses my issues.

In Scheduled Tasks, navigate to \Microsoft\Windows\WindowsColorSystem and open Calibration Loader. Go to Triggers and add two new events to trigger the task.

Add On Wakeup Event Trigger

resume-from-sleep

  • Begin the task: On an event
      • Basic
      • Log: System
      • Source: Power-Troubleshooter
      • Event ID: 1
      • [check] Delay task for: 5 seconds (optional, I’m experimenting with this)

Add On Workstation Unlock Event Trigger

on-workstation-unlock

  • Begin the task: On workstation unlock
  • Any user

Remaining Annoyances

If you have a MacBook and like to customize the brightness of your external Cinematic Display and/or you like have overridden the default behavior so that function keys behave like function keys rather than Mac OS X-like macro keys by default, then you find when you hot dock your settings aren’t respected. The problem is that when a monitor or keyboard is hot docked, the bootcamp.exe process that interfaces with the Apple system controller doesn’t apply your settings. The solution is to restart bootcamp.exe.

I have a simple convenience powershell script to restart bootcamp.exe.

get-process | where { $_.Name -eq 'bootcamp' } | stop-process
start-process 'C:\Program Files\Boot Camp\Bootcamp.exe'

You may wish to have this also run on an event trigger. However, if you do, the annoyance is that it will litter your system tray with dead “Boot Camp” black diamond icons. I tend to have a powershell console open all the time, so I just invoke the script manually whenever I dock my monitor and keyboard.

Advertisement

New NVidia Video Drivers Improve Graphics Subscore in Windows Experience on Boot Camp 3.2 and Windows 7 x64

nvidia-266.58-driverI have a late 2009 15” MacBook Pro Unibody (MacBookPro5,3) running Windows 7 x64 with Boot Camp 3.2. Because they are Apple, Apple doesn’t keep up to date with the video drivers for Windows. The versions that ship with Boot Camp are a couple of generations out of date.

A couple of weeks ago, NVidia released a new “Verde Notebook” driver which supports my MackBook Pro: GeForce 9600M GT Verde Notebook drivers release 265 v266.58 WHQL. The actual driver version reported by Device Manager is 8.17.12.6658 built 1/7/2011.

After creating a restore point, I went ahead and installed it although I did not elect to install PhysX or NVidia 3D Vision, neither of which have any use for me.

It just occurred to me to update the Windows Experience meter thingy. I didn’t expect any change but I was pleasantly surprised to find my Graphics and Gaming Graphics subscores increased slightly from 6.4 to 6.5 with no negative side-effects so far. This doesn’t make much if any difference at all in the real world but it feels nice.

graphics-score-nvidia-notebook-2066.58

What’s new in Boot Camp 3.2?

Bootcamp IconBoot Camp 3.2 is out. It is not a cumulative update. You have to install Boot Camp 3.0 from Snow Leopard, then apply 3.1 and then apply 3.2. Apple says that it “adds support for the ATI-Radeon HD 5870 graphics card, Apple USB Ethernet Adapter, MacBook Air SuperDrive, and addresses critical bug fixes.”

Apple doesn’t describe what the critical bug fixes are, but here’s what else is new in there.

  • New Apple mutlitouch touchpad drivers: 3.1.0.10 (replaces 3.0.0.0)
  • New Cirrus Audio drivers: 6.6006.1.26 (replaces previous patch 6.6001.1.25 from BC 3.1.3 or  6.60001.1.21 from BC 3.1).
  • New Apple wireless touchpad drivers: 3.1.0.7
  • New Boot Camp manager (bootcamp.exe): 3.1.0.10 (replaces 3.0.0.1)
  • New Boot Camp control panel AppleControlPanel.exe: 3.2.0.0 (replaces 3.0.0.2)
  • New Apple OS Manager: 3.1.0.3 (replaces 3.1.0.1)
  • New HFS+ driver, AppleHFS.sys: 3.2.0.0 (replaces 3.1.0.0)
  • New apple mount manager, AppleMNT.sys: 3.2.0.0 (replaces 3.0.0.1.8)
    The most immediate thing that I noticed is that FN+F5 on my MacBook Pro (MacBookPro5,3) can now dial the keyboard backlight all the way down to off. The built-in speaker volume also seems to be much louder without any enhancements enabled.

Maybe with Boot Camp 3.0 (Lion?) we’ll get an ambient light sensor driver so that the Adaptive Brightness service in Windows 7 can work.

FIXED: Boot Camp Audio Pops and Crackles with Windows 7 x64

Speaker_IconI have passed the 96 hour mark with a working fix for my audio problems with Boot Camp 3.1 running Windows 7 x64. To recap, I recently did a fresh installation of Windows 7 on my Mac Book Pro unibody (late 2009). Afterward, I started getting audio anomalies in the form of loud pops and permanent crackle distortions. These went away if I restarted audiosrv or reset the drivers in any way. For example, unplugging and plugging the speakers back into the minijack would fix it for a while as would turning audio enhancements on and off in the control panel for one of the devices.

I tried getting the latest Crystal Audio driver from Apple and  a solution from the interwebs that suggested disabling 802.11a. I also dug up a much newer version of the Broadcom wireless network card driver than Apple is distributing. I tried fiddling with Skype, which seemed to be part of the problem. I also disabled the USB audio device in my Apple Cinematic Display. None of these interventions totally solved the problem.

Then I came across a KB article that describes a similar but different issue with USB audio:

  • You attach a USB audio device to a computer that is running Windows 7 or Windows Server 2008 R2.
  • You configure this device as the default audio device.
  • You put the computer into the S3 sleep mode while an application plays audio.
  • You disconnect the USB audio device while the computer is in the S3 sleep mode.
  • You resume the computer from the S3 sleep mode.

In this scenario, the application that was playing audio stops responding. Additionally, all the other audio-related applications stop responding. For example, Volume Mixer also stops responding.

This is similar. My problems with mangled audio seemed to be related to power management, sleep yes but also not exclusively. My symptoms were much less extreme than the ones described: corruption instead of outright failure. The hotfix replaces the usbaudio.sys driver that shipped with Windows 7/2008R2 gold with a new version from July 14, 2010. What the heck, usbaudio.sys, is being used by one of the audio devices so I decided to give it a try.

Viola. It fixed my issue. I have had no audio squirreliness in 4 days where I previously could not have gone 4 hours.

What has me really scratching my head is how did I not have this problem before? I was running Windows 7 for a year on this computer and I didn’t really notice much of an audio problem until two weeks ago. Maybe it is the sort of thing that you don’t notice until you do and then you really notice.

Microsoft KB article 2122063: “The audio applications stop responding in Windows 7 or in Windows Server 2008 R2 after you resume the computer from the S3 sleep mode”

Why is Skype Using the Wrong Audio Device?

I’ve been trying to figure out what is causing my audio to whack out and go crackly intermittently. Now I’m hyper-sensitized to anything making pops and crackles on my late 2009 MacBook Pro 15” running Windows 7 x64 with Boot Camp 3.1.

One thing I noticed is that the pops seem to always start with the incoming IM noise emitted by Skype. Another thing I noticed was that the pop seemed to be first coming from my 24” Cinematic Display. To simplify the number of things going on, I disabled the Cinematic Display (aka "Apple USB audio device”) and “Digital Audio (S/PDIF)” playback audio devices in mmsys.cpl because I’m not using them. (I’ve gone many hours without any pops and crackles after disabling these two devices but I’m not ready to say the problem is solved.)

What I just noticed is that the incoming IM ping sound was coming very much from my right speaker and it was really loud. Then I realized it wasn’t coming from the right desktop speaker at all. It was coming from my laptop. All of my other sound is coming out of my Klipsch speakers via the “headphones” minijack. Nothing should be coming out of the laptop speakers which aren’t the current default playback device. It shouldn’t be doing that.

The Volume Mixer shows that Skype is the only thing using the built-in speakers. These screenshots were taken nearly simultaneously without making any system changes. I just changed the selected device in the Volume Mixer.

skype-using-interanleverything-else-using-default

All of the Skype incidental notifications are coming out of my laptop but voice calls are playing out of the configured default playback device, which is my desktop speakers. Very weird. This reminds me that when we first got the MacBooks it was just as Snow Leopard was released and we had the drivers in Boot Camp 3.0. Skype could not hear anything with the built-in microphone even though the built-in microphone was working as demonstrated by Sound Recorder.

I have a suspicion that Skype is doing something low-level and inadvisable with the audio devices.

For the record, according to Skype’s own settings dialogs, it should not be using the laptop built-in speakers.

skype-audio-config

Mystery Solved!

The notifications show up on whatever speaker is defined in Options | Audio Settings | Ringing. By default that is set to “Ring on all devices”. Changing it to Use selected speaker removes the weirdness of ringing coming out of the laptop speakers while using headphones.

Boot Camp: Dated Broadcom Driver Causes Audio Pops and Crackles

broadcom-disable-802-11aI have had a problem with my MacBook Pro having intermittent crackles and pops in the audio in my late 2009 Macbook Pro Unibody. I previously suspected the Cirrus Audio driver.  Restarting “Windows Audio” (aka audiosrv) fixes the problem. The pattern is that everything is fine on boot. The crackles and pops start after resuming from sleep.

I just came across this post which indicates the problem is actually caused somehow by the the 802.11a feature of the Broadcom wireless network adapter. Somewhat incredulously, I gave this a try and it works so far.

It also seems that although, Apple has not seen fit to send out an update, Broadcom has published several newer versions of their 943XX driver. These are available from other OEMs using Broadcom chips (Acer, Dell and HP) that actually provide updates for Windows drivers on a regular basis. HP helpfully offers a version of the Broadcom Wireless driver that is almost a year newer than the one in Boot Camp 3.1. The revision history of here shows notes a series of performance enhancements over the Apple-distributed version 5.60.18.8.

Update

Some good folks have taken it upon themselves to scrape together Broadcom wireless driver downloads posted by various OEMs. Note that sometimes the stuff in the forums is newer than what is listed in the pinned initial post. At the time of this writing, the latest available is 5.100.249.2 from Acer.

Update 2

I’m still getting the intermittent pops and crackles. Perhaps I have unfairly maligned the Broadcom driver based on random info from the interwebs. I just realized that the speakers on my Cinematic Display are running at the same time as my nice speakers on the mini-jack. Maybe that has something to do with it. Still futzing.

Boot Camp 3.1.3: Cirrus Audio Update

The Boot Camp update for MacBook Pro (13-inch, Mid 2010) (BootCamp_3.1.3_64-bit.exe) contains Cirrus Audio driver 6.6001.1.25 from 4/28/2010 which is newer than the 6.6001.1.21 version from Boot Camp 3.1. This driver works fine in a 2009 MacBook Pro 15-inch except that the package is set up to refuse to install on anything except the aforementioned new MacBook.

I’ve been having a problem with intermittent pops and crackles on my external speakers that seems to be a software/driver issue, so I wanted to give this update a whirl. So far, it seems like 6.6001.1.25 has fixed my pops and crackles problem.

7-Zip can extract the driver from the packaging. It’s just a matter of digging it out. Inside of Boot Camp_3.1.3_64-bit.exe is BootCampUpdate64.msp (a windows installer patch file). 7-Zip can unpack that into some cryptically named directories. Buried in there is a file called Binary.Cirrus_Audio_Bin which is actually some form of archive. Inside of that thing are the driver files.

Once you have Binary.Cirrus_Audio_Bin unpacked, you can point Device Manager at the unpacked location to update your Cirrus Audio driver.

I’m scratching my head a bit, wondering why Apple didn’t generally release this driver to all compatible hardware.

beforeafter

Painless NVidia Boot Camp Update on MacBook Pro

NVidia has recently WHQL certified “verde” notebook drivers: 258.96. In the past, drivers from NVidia have refused to install without hacking the INF or waiting for a boot camp update, which happens about once a year.

This time, though the drivers installed happily with no complaint. Woot!

I also grabbed the latest NForce drivers which contain Ethernet, SMBus and Away Mode drivers for my 2009 MacBook Pro Unibody. The SMBus and Away Mode drivers are related to power management. Who knows, maybe they will improve my battery life.

nvidia-ver devmgmt-ver

Boot Camp 3.1, from Apple this time

Boot Camp now officially supports Windows 7. As I expected, it is largely a repackaging of drivers previously released for Boot Camp 2.2. Here’s the flyby of what is in the update (I looked at the x64 version).

  • NVidia  display driver 8.16.11.8861, 01/05/2010
  • Binary.aapltp_Bin
  • Binary.AppleBTBroadcom_Bin
  • Binary.AppleBTE_Bin
  • Binary.AppleBT_Bin
  • Binary.AppleDisplay_Bin
  • Binary.AppleiSight_Bin
  • Binary.AppleODD_Bin
  • Binary.asix_ethernet_Bin
  • Binary.AtherosWin7_Bin
  • Binary.Atheros_Bin
  • Binary.Ati_GraphicsWin7_Bin
  • Binary.Ati_Graphics_Bin
  • Binary.BroadcomEthernet_Bin
  • Binary.BroadcomWireless_Bin
  • Binary.Cirrus_Audio_Bin 6.6001.1.21 (all new!)
  • Binary.crystal_beach_Bin
  • Binary.intel_ethernet_Bin
  • Binary.IRFilter_Bin
  • Binary.Keyboard_Bin 3.0.0.0 (same version number as was in Boot Camp 3.0 but I can definitely dim the keyboard more, now)
  • Binary.marvell_ethernet_Bin
  • Binary.MultiTouchMouse_Bin
  • Binary.MultiTP_Bin 3.0.0.0 (same as in 2.2)
  • Binary.null_driver_Bin
  • Binary.Realtek_Bin
  • Binary.Sigmatel_Bin

Available from Apple in x86 and x64 flavors.

Make your own Apple Boot Camp “3.1” update

Apple loves to tout compatibility with Windows.

Have a Windows application you need to use once in a while? No problem. Every new Mac lets you install Windows XP and Vista and run them at native speeds, using a built-in utility called Boot Camp.

There is something to this and the Apple hardware is awesome but Apple is a bit heel-dragging and sloppy about the way they release drivers for Boot Camp. For example, Windows 7 was finished July 22, 2009 but as of December 15, 2009 it is still officially unsupported by Apple. Windows 7 uses the same driver model as Vista, so that policy from Apple is just recalcitrant and disingenuous. Apple really does provide all the drivers you need to get Windows 7 x86 or x64 to run natively on Mac hardware.

On the other hand, some of the drivers in Boot Camp 3.0 are really flaky. For the latest Macbook Pros that use Cirrus Logic audio controllers, the volume is messed up so the internal speakers are un-hearable and the built-in microphone doesn’t work at all with some applications—notably Skype.

Apple actually does have updated drivers available. They are packaged as Boot Camp Drivers Update 2.2.

Setup is simple and straightforward — just as you’d expect with a Mac.

Awesome.

Except that if you are running Boot Camp 3.0, you are screwed and the setup is very not straightforward and there is no one-click installer from Apple. It is doable, though, and worthwhile.

This update addresses issues with the Apple trackpad and turns off the red digital audio port LED on laptop computers when it is not being used. It also includes support for the Apple Magic mouse and wireless keyboard. It is intended only for use with Microsoft Windows XP and Microsoft Windows Vista running on a Mac computer using Boot Camp.

If, like me, you are running Boot Camp 3.0 with Windows 7 on your MacBook Pro and you want these updates here’s what you have to do.

  • If you don’t already have it, install 7-zip.
  • Download the Boot Camp Drivers Update 2.2 for Windows from http://support.apple.com/kb/DL967
  • After you have BootCamp_Update_2.2.exe, right-click on it and select 7-zip | Extract to “BootCamp_Update_2.2\”.
  • Now you have a directory of files that includes BootCampUpdate32.msp and BootCampUpdate64.msp. The 64 version will work with Windows Vista or 7 x64.
  • Right-click on the appropriate msp file and extract it with 7-zip.
  • Now you have a directory full of weird file and folder names. One of the folders should be named “BootCamp24ToBootCamp223”. Inside there are some files that are named with the pattern Binary.*_Bin:

Binary.Cirrus_Audio_Bin –> Fixes audio levels and microphone
Binary.Keyboard_Bin –> Same version that shipped with Boot Camp 3.0
Binary.MultiTouchMouse_Bin –> Magic Mouse driver
Binary.MultiTP_Bin –>  Fixes accidental select while dragging
Binary.TrackPad_Bin –> I don’t have the older touchpad so I don’t know

    • Each of these files is an archive that you can extract with 7-zip. Once you extract them, you can install the drivers by running DPInst.exe or by pointing the Device Manager at the extracted drivers in the usual way.

Happy updating.

Now that that’s out of the way, can someone explain to me why this had to be so hard?

Why bundle these updates with a smug “Setup is simple and straightforward — just as you’d expect with a Mac” tagline but make sure that the customers who bought the latest hardware and latest OS X cannot install them? It makes no sense.

Why did Boot Camp 3.0 ask me to configure automatic driver updates from Apple but Apple doesn’t actually publish any driver updates though that channel? It makes no sense.

%d bloggers like this: