cancel
Showing results for 
Search instead for 
Did you mean: 

CR95HF Windows-USB source code library support for ISO15963 and M24LR protocols?

Jon Green
Associate II
Posted on March 31, 2014 at 16:27

I have a M24LR-DISCOVERY package, and I'm looking to use the CR95HF ''wand'' to program and communicate with an M24LR04E-R, preparatory to final manufacture of a high-volume (500k-to-millions units) product. We need to do block reads and writes using ISO15963/M24LR protocols.

I have the stsw-95hf002 (AN3954 v3) source code package for C++ development. Unfortunately, it does not include APIs for ISO15963 or M24LR-specific protocols; neither do the supplied Windows DLL and lib files.

I also downloaded the stsw-m24lr006 package, a firmware set for the board that does include ISO15963 and M24LR-specific support - however, these libraries do not, at first glance, appear easily or helpfully adaptable to Windows-USB software.

Before I burn time reinventing the wheel (and delaying the project), does ST (or anyone else here) have CR95HF Windows libraries for these protocols?

Many thanks in advance,

Jon

(Incidentally, the stsw-95hf002 source code package has serious buffer-overrun bugs. Specifically: using

scanf(''%s'',

[...]

)

with a pointer to a one character ''buffer'' is guaranteed to overrun if the user types anything at all before hitting ENTER. There are numerous examples of this bug in

source.cpp

.)

#cr95hf-iso15693 #cr95hf #m24lr-discovery #iso15693
1 ACCEPTED SOLUTION

Accepted Solutions
Posted on October 18, 2016 at 10:24

Hello

As described in the M24LR04E datasheet, error code 15 means «The specified block is read-protected». The blocks cannot be read because the sector where the blocks are, is locked (read mode).

You can use Get Miltiple Block Security Status command to read Lock status of each block (ref. to paragraph 4.1 of the datasheet tables 7 & 8 for Lock status.

There is no documents explaining the M24LR_Application_Software tools. Anyway this is some notes :

  • Autodetect has been developed using a Loop on Inventory command. The loop is done until a Tag is detected. The answer of the Inventory give us the UID of the Tag where 2nd bytes is the Manufacturer & 2rd is the Product ID

    then a Get System Info is issued on the tag to get informations such as memory size & block size.

  • For all other commands, inclding Read command, you can use CR95HFDll _SendReceive command.

    strRequestDatas = “022007�?

    02 : RF flag

    20 : Read command

    07 : Block number

    lngStatus = CR95HFDll_SendReceive(strRequestDatas, strResponseTag)

    Response = 80 08 000000000077CF 00

    80 : CR95HF tag answer Ok

    08 : Nb Btes Tag answer

    000000000077CF : tag answer

    00 : control byte ok

Following datasheet and AN3954, you will be able to send any request to the tag using CR95HFDll_SendReceive function.

Best regards

ST Customer support

View solution in original post

6 REPLIES 6
Anais GALLIGANI
Senior II
Posted on April 09, 2014 at 16:29

Hello Jon,

This is an example to allow customer to develop their own window USB software to manage CR95HF USB board and communicate with Tags (ISO15693 for example)

We don’t have more library, anyway all is available to manage RF communication with any tag :

1-

    

CR95HFDll_Select(strRequest ,strAnswer) to select ISO15693 protocol : strRequest =''010D�?

2-

    

CR95HFDll_SendReceive(strRequest,strTagAnswer) allows to send any RF request and receive the answer from the Tag

To understand how to format strRequest field, for example to be able to read or to write the iso15693 tag, you can refer to the Datasheet of the selected product.

Another way very usefull, is to use the cr95hf_development_software (stsw-95hf001 on st web site) to manage cr95hf :

-

      

Selects your product in ISO15693 tab.

-

      

You can now communicate with your product and send any rf command : inventory, read, write. Password management with this software.

-

      

Please have a look on Log or “request�? field to understand how to format your RFrequest and how the RF answer is formatted

I hope this is helping you,

Best regards,

ST NFC/RFID Dynamic tag support

I have a M24LR-DISCOVERY package, and I'm looking to use the CR95HF ''wand'' to program and communicate with an M24LR04E-R, preparatory to final manufacture of a high-volume (500k-to-millions units) product. We need to do block reads and writes using ISO15963/M24LR protocols.

I have the stsw-95hf002 (AN3954 v3) source code package for C++ development. Unfortunately, it does not include APIs for ISO15963 or M24LR-specific protocols; neither do the supplied Windows DLL and lib files.

I also downloaded the stsw-m24lr006 package, a firmware set for the board that does include ISO15963 and M24LR-specific support - however, these libraries do not, at first glance, appear easily or helpfully adaptable to Windows-USB software.

Before I burn time reinventing the wheel (and delaying the project), does ST (or anyone else here) have CR95HF Windows libraries for these protocols?

Many thanks in advance,

Jon

(Incidentally, the stsw-95hf002 source code package has serious buffer-overrun bugs. Specifically: using

scanf(''%s'',

[...]

)

with a pointer to a one character ''buffer'' is guaranteed to overrun if the user types anything at all before hitting ENTER. There are numerous examples of this bug in

source.cpp

.)
sasa
Associate II
Posted on October 05, 2016 at 12:03

Hello,

Although a strait forward task I am struggling to import the DLL file in to my Borland C++ IDE (BDS 2006). So is there a way to get the CR95HF.DLL in Borland OMF file format?

Another question regarding ST softwere for M24LR-Discovery kit.

When I read my device with the Demo board and SW I get data error 150690X00000604SdQAI.png

Thanks for the answer. Sash

sasa
Associate II
Posted on October 07, 2016 at 08:46

OK the first part related to DLL integration

http://wyw.dcweb.cn/stdcall.htm

.

Still to figure out what the error 15, error 10 is all about.

Thanks!

P.S. is there any document describing commands in used the M24LRxx Application Software, like auto detect, read region

Posted on October 18, 2016 at 10:24

Hello

As described in the M24LR04E datasheet, error code 15 means «The specified block is read-protected». The blocks cannot be read because the sector where the blocks are, is locked (read mode).

You can use Get Miltiple Block Security Status command to read Lock status of each block (ref. to paragraph 4.1 of the datasheet tables 7 & 8 for Lock status.

There is no documents explaining the M24LR_Application_Software tools. Anyway this is some notes :

  • Autodetect has been developed using a Loop on Inventory command. The loop is done until a Tag is detected. The answer of the Inventory give us the UID of the Tag where 2nd bytes is the Manufacturer & 2rd is the Product ID

    then a Get System Info is issued on the tag to get informations such as memory size & block size.

  • For all other commands, inclding Read command, you can use CR95HFDll _SendReceive command.

    strRequestDatas = “022007�?

    02 : RF flag

    20 : Read command

    07 : Block number

    lngStatus = CR95HFDll_SendReceive(strRequestDatas, strResponseTag)

    Response = 80 08 000000000077CF 00

    80 : CR95HF tag answer Ok

    08 : Nb Btes Tag answer

    000000000077CF : tag answer

    00 : control byte ok

Following datasheet and AN3954, you will be able to send any request to the tag using CR95HFDll_SendReceive function.

Best regards

ST Customer support

Hi, I'm trying to compile the project in C++ but I get these errors
What is required to be done? 

Brian TIDAL
ST Employee

Hi,

I would recommend to create a new thread rather that posting on an old and already answered one. 

This is linker errors: the symbols from the CR95HF.DLL are not found. Make sure to have the CR95HF.lib  DLL import lib in the linker command. Also, make sure to includeCR95HFDLL.h in your sources using the DLL APIs.

Rgds

BT

In order to give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.