def setPulseInputRatio(self, line_in, new_cnst, password="<STR_LIT>"):
result = False<EOL>self.setContext("<STR_LIT>")<EOL>try:<EOL><INDENT>if not self.requestA():<EOL><INDENT>self.writeCmdMsg("<STR_LIT>")<EOL><DEDENT>else:<EOL><INDENT>if not self.serialCmdPwdAuth(password):<EOL><INDENT>self.writeCmdMsg("<STR_LIT>")<EOL><DEDENT>else:<EOL><INDENT>req_const = binascii.hexlify(str(new_cnst).zfill(<NUM_LIT:4>))<EOL>line_const = binascii.hexlify(str(line_in - <NUM_LIT:1>))<EOL>req_str = "<STR_LIT>" + line_const + "<STR_LIT>" + req_const + "<STR_LIT>"<EOL>req_str += self.calc_crc16(req_str[<NUM_LIT:2>:].decode("<STR_LIT>"))<EOL>self.m_serial_port.write(req_str.decode("<STR_LIT>"))<EOL>if self.m_serial_port.getResponse(self.getContext()).encode("<STR_LIT>") == "<STR_LIT>":<EOL><INDENT>self.writeCmdMsg("<STR_LIT>")<EOL>result = True<EOL><DEDENT><DEDENT><DEDENT>self.serialPostEnd()<EOL><DEDENT>except:<EOL><INDENT>ekm_log(traceback.format_exc(sys.exc_info()))<EOL><DEDENT>self.setContext("<STR_LIT>")<EOL>return result<EOL>
Serial call to set pulse input ratio on a line.

        Args:
            line_in (int): Member of :class:`~ekmmeters.Pulse`
            new_cnst (int): New pulse input ratio
            password (str): Optional password

        Returns: