HTC One Earphone - Don't use iPod earphone
It has taken me a week to resolve this issue. Tried resolving some issues with the file structure on the phone, where the music files are stored on both the phone and in iTunes, trying working with HTC Sync Manager, uninstalled and reinstalled it, could not get it to work correctly, converted all of the files to MP3 format and finally flushed the cache. Nothing resolved the problem. This morning I changed earphones from an iPod earphone I had been using to the HTC earphone that came in the box with the HTC phone. Works as advertised.
The iPod earphone jack and the HTC earphone jack appear almost identical. However, the HTC earphone jack is about 1 mm longer than the iPod jack. Thus, it appears to me that that minor difference in earphone jack may be the problem or there is a possibility that the iPod earphone wires are not shielded and the HTC earphone wires are but I strongly suspect that it is that 1 mm of jack length difference that made the iPod phone not quite making sufficient contact and that was causing a spurious input to the music player.