To cut down on all the editing required, it's probably a good idea to put all the buttons in a frame with the name of the path to the device, then use relative naming on the buttons. e.g. suppose the device was Fordrat8\ElkM1EZ8\Light 14 - you would use that as the name of the frame. Then a button in that frame would be called <^>. In fact, anywhere the name of the button is used you would substitute <^>, including in state rules and Lua code.
If used in a Lua string then use [[ ]] notation to delimit the string.