Hi
I believe that you can use the TXEMP interrupt to generate an interrupt (see USRn) at the end of the last stop bit sent.
In the uTasker MODBUS module for the M522XX with RS485 support this was however not used (see http://www.utasker.com/docs/MODBUS/uTasker_MODBUS.PDF appendix B and chapter 11) . Instead the normal character interrupt was used and a timer started to timeout when the RTS line should be changed, allowing for extra control of the timing to, say, several bits times after the last stop bit.
Regards
Mark
www.uTasker.com
- OS, TCP/IP stack, USB, device drivers and simulator for M521X, M521XX, M5221X, M5222X, M5223X, M5225X. One package does them all - "Embedding it better..."