Contacts seem to be sorted by first name on Digium phones. Can that be changed to last name?
Aye.
The DPMA option is a phone option, name_format.
https://wiki.asterisk.org/wiki/display/DIGIUM/DPMA+Configuration
The XML option is also name_format, it’s a setting.