I have a C++ .dll function that I am accessing through python 3.2 with the syntax:
int Create(char argID)
and I am trying to access this function using python. I can access it, but I am confused on why it is telling for 'wrong type' whenever I try to pass the function an argument. Python Script:
Create.argtypes = [c_char]
Create.restype = c_int
ID = c_char
ID = input("Enter ID:")
Create(ID) #ctypes.ArgumentError: argument 1: <class 'TypeError'>: wrong type
Not sure where I am going wrong or is there a different way to pass a character or characters from the user input? Kindly help.
Cheers.
raw_inputinstead ofinput?