These code is the serial programming for linux system