Thanks Michael, that got me in the right direction but it didn't work.
Before I wrote to
com.apple.keyboard.fnState I read from it to see what was there.
defaults read -g com.apple.keyboard.fnState
When the checkbox was on in System Preferences (acted like function keys) the above resulted in
1. When the checkbox was off (hardware keys) it resulted in
0.
When I ran +defaults write -g com.apple.keyboard.fnState true+ it didn't make the keys only work as function keys, in fact it didn't change anything. If I wrote a
true or a
false the keys didn't change from whatever they were set to before I ran that command.
When I read back
com.apple.keyboard.fnState whatever I had written to before was there. Writing
false to that preference resulted in
false being returned and the key type never changing.
If I wrote a
1 or a
0 it didn't change how the keys behaved yet checking or unchecking the System Preferences checkbox (resulting in a
1 or
0 being read from the preference) would change the behavior of the keys.
I even restarted (effectively killing all processes). That resulted in the sum total of nothing. I'm really stumped on this one. Googling "fnstate" resulted in a handful of of cases just like this that I hadn't discovered in my previous Googlings. None of them with a solution that worked for me.
Is there some silly mistake that I'm making here or what?