Thanks for your reply.
I have no problem with online monitoring, even though sometimes it seems "lost" communication for about 0.5s and then recover by it self.
I tried the OIT sample projects, both on 485 and 232. If I repeat pushing the button, some times the PLC will response slowly - about 1 second no response.
Again, with monitor the communication with ocilloscope, I found these two things. In both case, I'm using RS232 port and HMI is master, PLC is slave; also, I'm using a very simple PLC ladder circuit, basically it turn the outputs (Stack lights) based one the relay status; HMI will toggle the relay on/off and display the output status. No communicaiton command, no EEPROM access.
1. PLC response delay.
If I use default setting, i.e. do not use setbaud 1,6, but do use setprotocol 1,1 and setsystem 3,0, the PLC will response the HMI command after 30ms.
However, if I re-set the baudrate by setbaud 1,6, which suppose no change to the baud rate setting, the PLC will response the HMI in about 3-4 ms.
I'm thinking this is a bug in PLC OS.
2. Baudrate accuracy.
I checked the signal again with ocilloscope. The problem is still there: transmitter signal from HMI is 26us bit width, while PLC transmitter signal is 28us bitwidth.
By monitoring the command/response signal, I can tell that every one or two minutes, the PLC will stop response for one command cycle, i.e. you can see the HMI send command to PLC, but PLC no response. With RS232, most of the time the HMI will pick up the communicaiton in about 1 or 2 command cycle, so you don't notice the lost communication; but in some cases, it will lost communictiaon for more than 2 seconds, which is not allowed for my project.
I'm assuming the PLC uses HC12 CPU. I notice the PLC is using 16MHz crystal, which means the MCLK is 8MHz. I highly suspect that in the PLC OS, when setting the baudrate control register, it uses 14 instead of 13, which caused the bit width become 28us. I highly recommand that you ask your engineer to test this.
Next Monday I will double check the signal on RS485 port, to find out the bit width on 485 port.
Thanks for your support.