API: Fix the sensor_type and value

Convert everything to a string in the custom setter
as we don't know the order that the value and sensor_type are written,
so convert to the desired type in get_value().

part of blueprint api
Change-Id: Ia0c9883cecd6beea8ab8dff2c6b63c31e588819e