To convert a quantity to a number using a scalar unit, instead use Modelica.Blocks.Math.Gain with k set to the reciprocal of the unit.