Monotouch Binding to Linea Pro SDK

Posted by jeffrapp on Stack Overflow See other posts from Stack Overflow or by jeffrapp
Published on 2012-09-15T21:34:05Z Indexed on 2012/09/15 21:37 UTC
Read the original article Hit count: 375

Filed under:
|
|
|

I'm trying to create a binding to the Linea Pro (it's the barcode scanner they use in the Apple Stores, Lowes) SDK. I'm using David Sandor's bindings as a reference, but the SDK has been updated a few times since January of 2011.

I have most everything working, except for the playSound call, which is used to, well, play a sound on the Linea Pro device.

The .h file from the SDK has the call as follows:

-(BOOL)playSound:(int)volume beepData:(int *)data length:(int)length error:(NSError **)error;

I've tried using int[], NSArray, and an IntPtr to the int[], but nothing seems to work.

The last unsuccessful iteration of my binding looks like:

[Export ("playSound:beepData:length:")]
void PlaySound (int volume, NSArray data, int length);

Now, this doesn't work at all. Also note that I have no idea what to do with the error:(NSError **)error part, either.

I am lacking some serious familiarity with C, so any help would be extremely appreciated.

© Stack Overflow or respective owner

Related posts about c#

Related posts about ios