CCID, Smartcard

Hi, for a customer I have to build an Win+Mac app with can read info of a smarcard.
They are using Mifare Smarcard’s already and want to use reader ACR122U .

Is there already a Xojo plugin for reading info from a CCID device like this?

We have a SmartCard class:

[quote=292654:@Christian Schmitz]We have a SmartCard class:[/quote]
Thx! It’s connecting, I mail you some questions about it!

Have fun!

Is there a sample code for test ?


did you get the version with this Transmit call?

oh, there may be an error.
The header must use 2 for T1, I think.

The code in your documents to get the Version is returning error -2146435064

Maybe I find time tonight to try it myself…

So, I wrote a sample which shows here version number and queries serial number.
Seems to work for me.

I’ve emailed it to Jaap and Valdemar.

I receive today my reader and test the sample. I get the same error when as Jaap when connect to reader. :frowning:

please try newer version of the example.

error -2146435060 is a missing smart card!

Hi, i can connect with example, but nothing possible after…

when i try to transmit, i never receive data

other ACR122 soft works well

my code used:

[code] dim header as new memoryBlock(8)

	header.Int32Value(0) = 2 // T1
	header.Int32Value(4) = 8 // size of this block
	dim command as new MemoryBlock(5)
	command.Int8Value(0) = &h0
	command.Int8Value(1) = &hCA
	command.Int8Value(2) = &h1
	command.Int8Value(3) = &h82
	command.Int8Value(4) = &h2
	dim buffer as new MemoryBlock(512)
	dim ReceiveHeader as new MemoryBlock(8)
	dim RecvLength as UInt32
	card.Transmit(header, command, command.Size, ReceiveHeader, buffer, RecvLength)
	DebugWindow.DebugWindow.AppendText(  "Received Header " + EncodeHex(ReceiveHeader,true)+" bytes" + chr(13) )
	DebugWindow.DebugWindow.AppendText(  "Received "+str(RecvLength)+" bytes" + chr(13) )

Thanks for help

I think you should set Recvlength to 512 to specify how much space is in buffer.