'Check all input params'

def check_params(self):

    if self.log_buff_size:
        if (not self.log_buff_size.isdigit()):
            self.module.fail_json(msg='Error:    log_buff_size    is    not    digit.')
        if ((int(self.log_buff_size) < 0) or (int(self.log_buff_size) > 10240)):
            self.module.fail_json(msg='Error:    log_buff_size    is    not    ranges    from    0    to    10240.')
    if self.channel_id:
        if (not self.channel_id.isdigit()):
            self.module.fail_json(msg='Error:    channel_id    is    not    digit.')
        if ((int(self.channel_id) < 0) or (int(self.channel_id) > 9)):
            self.module.fail_json(msg='Error:    channel_id    is    not    ranges    from    0    to    9.')
    if (bool(self.module_name) != bool(self.channel_id)):
        self.module.fail_json(msg='Error:    module_name    and    channel_id    must    be    set    at    the    same    time.')
