The issue has nothing to do with HSERIN or the program. As you have a MAX232 could you connect direct to your PC and use HyperTerminal to test the functioning?