Reshared post from +Koushik Dutta
Beta APK: AirPlay Mirroring and Screen Recording in CyanogenMod
Instructions:
Download apk and install on CyanogenMod (must have a recent 10.2 nightly).http://download.clockworkmod.com/test/Mirror.apk
To use screen recording, it is very similar to screenshots. Instead of volume down + power (screenshot), press volume up + power. A notification will pop up that notifies you that your screen is being recorded. You can enable showing touches, and also stop the recordings. Recordings are saved to /sdcard/MirrorRecordings.
To use airplay mirroring, go into Settings, displays, Wireless Displays. It will scan for airplay devices. Pick one, and it will mirror your screen.
There's some bugs with the NSD Service in Android itself, which I need to fix. Causes hard hangs/NPEs in the framework. So if your airplay stops working after a while, a reboot will fix it.
Caveat:
This will NOT work on any devices that don't support MiraCast, like the Galaxy Nexus. Your phone is too damn old.