Symfonisk volume value to variable or media device (Chromecast)

Hello!
I have a symfonisk Sound controller (Ikea Zigbee Sound Controller) and I've set it up to control my google chromecast audio device volume. This is a brief guide to point you in one direction which will help get this working for you. Initially it took a bit of fiddling to get this to work as I had made a few incorrect assumptions, so hopefully this will help you.

Note: This guide is assuming you have the Chromecast and the Symfonisk controller connected correctly already.

  1. Use the Rule Machine app to create a new rule e.g. Chromecast volume
  2. Create two trigger events: button 2 released & button 3 released
  3. Create a new local variable called something like "vol"
  4. Create a new action to set the value of the variable vol to the attribute of the symfonisk controller (operation: device attribute) the name of the attribute is "level"
  5. Create a new action after the one above, to set the volume on the chromecast, the value to specify in the "Select volume (0 - 100%)" is the variable name created in step 3 (vol) surrounded by percentage characters e.g. %vol%

And that should do it.