Cannot connect to Apple TV My Apple TV works perfectly as a stand alone machine. It plays the channels I want to watch. 
However, Neither my MacBook Air, My iPads, my iPhone 6 and my iMac will no longer connect to AirPlay.
All these devices worked perfectly until recently, AirPlay was a wonderful method by which I could stream videos to the Apple TV for watching on the 'big screen'.

Now, none of them connect. they are all on the same wifi network and 'AirPlay' is switched on on the Apple TV.
Using the iPad, the 'Airplay' button is there, when I choose to play to Apple TV, the iPad says"PLaying on Apple TV" but nothing happens on the TV.
Both the MacBook Air and the iMac are unable to connect to Apple TV. The AirPlay button is there, and when I choose Apple TV, after some moments I get a message "Unable to connect to Apple TV"
Even though this says unable to connect to Apple TV, when I use iTunes to stream MP4 files, I go into the menu on Apple TV, Choose 'Computers' and I can access the MP4 files and they play perfectly.

But, as the computers 'cannot connect' I am unable to Mirror my computer screen, hence, I cannot use 'Beamer' to stream other file types such as .avi or .mkv from them to the TV.
Also, when I stream live TV from my iPads, they say "Playing on Apple TV", but the Apple TV does not respond by playing the files.

I have reset the Apple TV twice and everything is as should be as far as set up is concerned, and I have checked everything I can think of on the computers and have checked all the settings. 

What's gone wrong? I hope someone has an idea that I haven't already tried over the last 5 days of searching for answers on the internet and checking settings on all my devices.
Try restoring the Apple TV to its factory setting via iTunes, Apple Support article here.  We've had a handful of Apple TVs with odd behaviour, and restoring via iTunes has fixed them.  You will need a micro-USB cable to do this.