If someone wants to install an advert app on their fridge (I assume in exchange for money) then fair enough.
If I buy a tv I shouldn't just have to accept that, now or in the future, the manufacturer will sell advertising on it.
Termination for convenience is a standard term in contracts, hence well-understood by corporate lawyers. The repayment could be reduced using a depreciation schedule so the longer the device is in your hands the less that's returned.
I think this would work. The legal machinery is already there. The market would work out the details.