Filled in some missing details to the setValue(operand, value, width) function