import ctypes


def c_str(string):
    """
    Create ctypes char* from a python string

    Parameters:
    ---------
    string : string type
             python string

    Returns:
    ---------
    str: c_char_p
       A char pointer that can be passed to C API
    """
    return ctypes.c_char_p(string.encode('utf-8'))