The dynamic library name: test. DLL
The function name: int testfun (s_struct * dev_handle, int ch_id, t_struct bufs [], int n_bufs);
Among them:
Typedef struct
{
Int device_id;
} s_struct;
Typedef struct
{
Uint8_t * data;
Uint64_t timestamp;
Int data_len;
Uint8_t iface;
} t_struct.
How to call in c #?? Consult,,,,,,,,,,
CodePudding user response:
I think the byte [] for processing, only need to change my lineCodePudding user response:
The.net also have struct unsafe or MarshalCodePudding user response:
Has not been used for the unsafe and marshal, how to define, can this structure, for example? Thank you for theCodePudding user response:
The C structure is defined inTypedef struct
{
Unsigned char * data;
Unsigned long long timestamp;
Int data_len;
Unsigned char iface;
}. How to convert instead???????
CodePudding user response:
3/f thank you comment on the second floor