USB Keyboard on MAC: \ and < characters inverted I have a strange behaviour with an USB keyoboard connected to a MacBook Pro laptop. 
Mac OS X version: macOS Sierra 10.12.2 (16C67)

In the laptop the keys are correct, but with the external keyboard the \| keys is inverted with the &lt;> key

How can I solve this issue?
hanks.
This can be caused when the OS mis-identifies the keyboard. To get that back, clear the preference that saves which device is which layout.

How to reset the mac keyboard

I made as described in the post:


Delete the file /Library/Preferences/com.apple.keyboardtype.plist
Disconnect the keyboard
Reconnect the keyboard
Restart the os


After doing these steps, the keyboard had to be recognized again, and it fixes the issue.

The correct keyboard for Italian is ISO (Eur).