@ chithanh04dt2
I have get the same strange PS2 -> ASCII when i have start my project.
That is a relevant error , it depend if your rs232 data are normal or inverted.
For use one of the rs232 mode i have add a extra rs232 setup in my code .
Then i just comment or uncomment the setup i need ...
Here the rs232 setup from my project coded with CCS C:
for invert mode i do ...
//#use rs232(baud=9600, xmit=PIN_C4, rcv=PIN_C5, FORCE_SW, BITS=8, STOP=1, PARITY=N)
#use rs232(baud=9600, xmit=PIN_C4, rcv=PIN_C5, FORCE_SW, BITS=8, STOP=1, PARITY=N, INVERT)
for normal mode i do ...
#use rs232(baud=9600, xmit=PIN_C4, rcv=PIN_C5, FORCE_SW, BITS=8, STOP=1, PARITY=N)
//#use rs232(baud=9600, xmit=PIN_C4, rcv=PIN_C5, FORCE_SW, BITS=8, STOP=1, PARITY=N, INVERT)
I hope it will resolve your problem