i have once come across to a similar problem with an older samsung tv. it would repeatedly switch between inputs making it impossible to use.! the problem was with the onboard tv controls. stuck buttons actually! i opened the tv and disconnected the control board. the tv is working fine ever since, however only with the remote control! although your tv isnt that old, being a smart tv, there is still a chance you have the same problem, else most probably an issue with the tv switching power supply. However ,if it is still under any warranty i wouldnt try anything myself and make sure it would br delt by Samsung!