Xmodem send does not work
I have checked the latest source code of XMODEM protocol, however I could not find a bug you mentioned. Every time Tera Term receives a ACK/NAK, the data packet sends.
I have the same problem with Tera Term 2.3. The first packet is sends twice without waiting answer. If the file is empty Tera Term sends EOT and then another EOT with full data packet, where data is from previous file being transmitted.
I have found out the problem. It is not the problem with Tere Term. I think you send two NAK before you actually click at the File->tranfer->xmodem->send, and as a result, when xmodem start to work, it send two first packet. You should be sure to start xmodem before you send more than two NAK.
Xmodem send fails with TeraTerm 4.52 and 4.63. A serial protocol analyzer shows that the first packet (01) is sent twice by TeraTerm before any ACK/NAK is received. Then the receiving device sends an ACK for the first data packet (01) received, followed by a NAK for the second data packet received (another packet 01). Since the second packet is supposed to be number 02, but is packet 01 instead, the receiving device aborts the transfer due to a packet received out of sequence. Not all devices capable of receiving XMODEM protocol can recover from a packet out of sequence error. TeraTerm should send the first packet (01), then wait for an ACK or NAK before sending the next packet. Perhaps something is not initialized properly regarding a timer used to generate a timeout error in the case that no ACK or NAK is received? I am running Windows XP and using a USB/serial adapter cable at 38400 baud. Since the connection could be going over an external modem, an ACK/NAK timeout of one second or more would not be unreasonable.