def convert_int_to_bits(num: int, bits_count: int = 6, signed: bool = False) -> str:
    """
    Converts int to bits string.
    """
    if signed:
        if num < 0:
            return format(num & (pow(2, bits_count) - 1), f'0{bits_count}b')
    return format(num, f'0{bits_count}b')