When the dealer installs a new radio, they use a MB STAR scan tool to code it with the vin number of your vehicle once they have completed the physical install.
The audio unit is more than just an audio unit. It is a control module that part of the antitheft(immobilize) system goes thru for the vehicle. Part of this is matching vin numbers coded into each of the various control modules when they are interrogated by the immobilizer control module. If one doesnt match, the immobilizer will prevent the vehicle from starting. The IP Cluster, ECM, SAM, Audio unit, and immobilizer control modules all have to match in vin number.
As to salvage yards, they are not governed by any laws on selling used parts except airbags. Other than airbags, they have no laws to adhere to and it is up to their personal ethics on selling parts that cannot be reused. I run into this all the time with not just audio units, but also ecms, bcms, pcms and other control modules. 99% of all control modules cannot be reprogrammed to another vehicle, but that has never stopped salvage yards from selling them to people. I usually have to tell 6-10 people a week that I cannot install their used control module in their vehicle because it cannot be reprogrammed to work with their vehicle.
Please remember to rate service using the rating page so that I may receive credit. Thanks
If for any reason, you can't rate my answer OKAY, GOOD, or EXCELLENT today.
Please reply and let me know why, so I can help more/better.
All follow up responses are FREE, after completing the required rating