Question

i'm currently using DS89C450 MCU on Keil C51 Programming.

I have an Infrared Receiver attached to P3^2 which is the falling edge trigger. Whenever I press a key on the remote control, it will trigger the interrupt and save it into the xdata X or Y (bit by bit then byte by byte for 500 bytes).

I'm trying to transmit the data bit (either '1' or '0') from the buffer to the hyperterminal via Serial Port. However, I do not get any data displayed when I press the remote control.

Can anyone expert tell me why and how do i get it to work?

The program is here:

http://pastebin.com/hpAw2ipH

Was it helpful?

Solution

Google "Terminal by br@y", it can show serial comms in HEX. Most UARTs cannot send a single bit, rather they will send a character of N bits, usually 7 or 8, with start/stop/parity bits (8-bits, no parity, 1 stop bit being the universal default). It can make life easier to encode data as ASCII, perhaps even with start/stop characters, so you know when you're getting real data.

For even more detail, use an oscilloscope, BusPirate or LogicSniffer (from DangerousPrototypes.com) to sniff the communications data.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top