ni.com is currently undergoing scheduled maintenance.

Some services may be unavailable at this time. Please contact us for help or try again later.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Setting up RFID system

Hi all,

 

My situation currently is setting up proper communication between the Arduino and a UHF reader/ writer.

I am using

 

-Arduino Mega 2560

-Arduino compatible Compiler for LabVIEW

-Reader “CF-RU5106”

-Shield for Serial communication “RS232”

 

Tested the Arduino Compiler for LabVIEW and it works. I set up serial settings, and now starting to create serial instances for data flow. One mistake I made is that I totally forgot to take into consideration of the CRC-16. I tried setting up CRC computation code provided by the manufacturer using Formula Node in LabVIEW but was unsuccessful.

 

Any feedback or suggestions is much appreciated.

0 Kudos
Message 1 of 15
(6,044 Views)

Hi jp978,

 

I think the following links should prove to be helpful in your application:

 

CRC16 Checksum:

https://forums.ni.com/t5/Example-Code/CRC16-checksum/ta-p/3996191

 

Tutorial: Formula Nodes:

https://knowledge.ni.com/KnowledgeArticleDetails?id=kA03q000000x30HCAQ&l=en-US

 

In order to receive the most sufficient help, I would also recommend posting your code.

0 Kudos
Message 2 of 15
(5,942 Views)

Thanks

I came across various CRC LabVIEW examples and found two that seem to fit my application requirements. I am currently changing my code, and I will post it as soon as it looks decent enough to read.

0 Kudos
Message 3 of 15
(5,938 Views)

This is what my code is looking like. So far I dont quite understand the CRC portion, but most of it consist of formulating the command for the reader.

Any feedback will help.

0 Kudos
Message 4 of 15
(5,870 Views)

Hi jp978,

Here are some links that should prove to be useful for developing a CRC code:

 

Inline CRC Reference Library:

https://forums.ni.com/t5/Example-Code/Inline-CRC-Reference-Library-CRC-32-CRC-16-and-CRC-8/ta-p/3500...

 

CRC16 Checksum:

https://forums.ni.com/t5/Example-Code/CRC16-checksum/ta-p/3996191

 

CRC -16 Reference Calculator:

https://forums.ni.com/t5/Example-Code/CRC-16-Calculator/ta-p/3996194

 

CRC CCIT 16bits:

https://forums.ni.com/t5/Example-Code/CRC-CCITT-16bits/ta-p/3996269

 

CRC codes are something that we do not necessarily specialize in developing. I would recommend developing a CRC code based on a predeveloped algorithm as shown in some of these examples.

 

I hope this helps!

0 Kudos
Message 5 of 15
(5,842 Views)

Here is a CRC-16.vi that I got from the LabVIEW Code Exchange a few years ago when I had to deal with them.

 

 

========================
=== Engineer Ambiguously ===
========================
0 Kudos
Message 6 of 15
(5,828 Views)

I will look at the links. Thank you. 

0 Kudos
Message 7 of 15
(5,826 Views)

Thanks for the sample. I will test it with my code.

0 Kudos
Message 8 of 15
(5,825 Views)

I managed to get a value for the CRC code. I verified with some example code from the arduino forums and also some online CRC calculators. I managed to create a serial command using VISA, i will post the code below.

The problem currently is either setting the command and not receiving a string from the reader. Any suggestions will help.

RedoProj is the main code.

 

 

Download All
0 Kudos
Message 9 of 15
(5,807 Views)

Hi jp978,

 

If you wouldn't mind elaborating on the error you are seeing I think that would help in this case. I am a bit unclear on the scope of the problem. Specifically, what error are you seeing when the string does not come through to the reader? Also, what is your expected output?

 

 

0 Kudos
Message 10 of 15
(5,790 Views)