the original code of phoenix demo