I am not sure where an arduino fits into this project. It sounds like just a software project on the PC.
and make the printer scans the log
codes written in Arduino tell the thermal printer to scan the log.txt and print out the lastest item.
because we found that what you just posted contains sensitive terms. " and you never know what exactly are the so-called "sensitive terms" .