'Setup serial port and set is as escpos device'

def open(self):

    self.device = serial.Serial(port=self.devfile, baudrate=self.baudrate, bytesize=self.bytesize, parity=serial.PARITY_NONE, stopbits=serial.STOPBITS_ONE, timeout=self.timeout, dsrdtr=True)
    if (self.device is not None):
        print 'Serial    printer    enabled'
    else:
        print ('Unable    to    open    serial    printer    on:    %s' % self.devfile)
