Rfid read procedure


+ Reply to Thread
Results 1 to 11 of 11

Thread: Rfid read procedure8 days old

  1. #1
    Junior Member cemati's Avatar
    Join Date
    Oct 2019
    Posts
    6
    Thumbs Up
    Received: 0
    Given: 1
    Total Downloaded
    0

    0 Not allowed!

    Default Rfid read procedure

    Hi.
    I am using rc 522 chip rfid module. I can read test data. Now, I want read rfid card. Which register do I need to change to read the cards?

Attention

This valuable resource relies upon the very small amount of revenue generated by displaying online advertisements to our visitors.

The advertisements we display are relevant to this web site and your browsing history

Please consider supporting us by disabling your ad blocker.


Note: Some users have reported issues related to ad-blockers rendering parts of this wesite unusable,
where possible we will rectify the issues to enable you to use this resource with adblocking enabled.

If you can, please report issues in the forum area WebSite / Forum Issues


Thank you for your attention.

  • #2
    Prolific Poster RGV250's Avatar
    Join Date
    Aug 2005
    Posts
    2,325
    Thumbs Up
    Received: 29
    Given: 7
    Total Downloaded
    802.58 MB

    0 Not allowed!

    Default Re: Rfid read procedure

    Hi,
    Have you read this post http://www.protonbasic.co.uk/showthr...C522-RFID-Code
    it might explain why you cannot read different cards.

    Regards,
    Bob

  • Attention

    This valuable resource relies upon the very small amount of revenue generated by displaying online advertisements to our visitors.

    The advertisements we display are relevant to this web site and your browsing history

    Please consider supporting us by disabling your ad blocker.


    Note: Some users have reported issues related to ad-blockers rendering parts of this wesite unusable,
    where possible we will rectify the issues to enable you to use this resource with adblocking enabled.

    If you can, please report issues in the forum area WebSite / Forum Issues


    Thank you for your attention.

  • #3
    Junior Member cemati's Avatar
    Join Date
    Oct 2019
    Posts
    6
    Thumbs Up
    Received: 0
    Given: 1
    Total Downloaded
    0

    0 Not allowed!

    Default Re: Rfid read procedure

    Quote Originally Posted by RGV250 View Post
    Hi,
    Have you read this post http://www.protonbasic.co.uk/showthr...C522-RFID-Code
    it might explain why you cannot read different cards.

    Regards,
    Bob
    Hi Bob.
    I read this post. bu I don't understand reading procedure. I think I changed the register correctly. But, I dont understand the reading block in the program. I would appreciate it if you can explain it in a simple way.
    Thank you for information and answer.

  • Attention

    This valuable resource relies upon the very small amount of revenue generated by displaying online advertisements to our visitors.

    The advertisements we display are relevant to this web site and your browsing history

    Please consider supporting us by disabling your ad blocker.


    Note: Some users have reported issues related to ad-blockers rendering parts of this wesite unusable,
    where possible we will rectify the issues to enable you to use this resource with adblocking enabled.

    If you can, please report issues in the forum area WebSite / Forum Issues


    Thank you for your attention.

  • #4
    Prolific Poster RGV250's Avatar
    Join Date
    Aug 2005
    Posts
    2,325
    Thumbs Up
    Received: 29
    Given: 7
    Total Downloaded
    802.58 MB

    0 Not allowed!

    Default Re: Rfid read procedure

    Hi,
    I have not used these RFID, only 125khz but would think they are similar in operation. Perhaps you could give more detail in what you have done as I am not sure what you mean by "Read test data". Have you read any cards? as I would expect it to be the same for all devices.

    Reards,
    Bob

  • Attention

    This valuable resource relies upon the very small amount of revenue generated by displaying online advertisements to our visitors.

    The advertisements we display are relevant to this web site and your browsing history

    Please consider supporting us by disabling your ad blocker.


    Note: Some users have reported issues related to ad-blockers rendering parts of this wesite unusable,
    where possible we will rectify the issues to enable you to use this resource with adblocking enabled.

    If you can, please report issues in the forum area WebSite / Forum Issues


    Thank you for your attention.

  • #5
    Junior Member cemati's Avatar
    Join Date
    Oct 2019
    Posts
    6
    Thumbs Up
    Received: 0
    Given: 1
    Total Downloaded
    0

    0 Not allowed!

    Default Re: Rfid read procedure

    I couldn't read any cards.
    Click image for larger version

Name:	Screenshot_20191108-225844_Drive.jpg
Views:	5
Size:	50.1 KB
ID:	3822
    There are information about the test. But, read the card more different. I dont understand datasheet because my english is weak
    http://www.hobbytronics.co.uk/datash...rs/MFRC522.pdf
    This is the datasheet.
    Thank you.

  • Attention

    This valuable resource relies upon the very small amount of revenue generated by displaying online advertisements to our visitors.

    The advertisements we display are relevant to this web site and your browsing history

    Please consider supporting us by disabling your ad blocker.


    Note: Some users have reported issues related to ad-blockers rendering parts of this wesite unusable,
    where possible we will rectify the issues to enable you to use this resource with adblocking enabled.

    If you can, please report issues in the forum area WebSite / Forum Issues


    Thank you for your attention.

  • #6
    Prolific Poster RGV250's Avatar
    Join Date
    Aug 2005
    Posts
    2,325
    Thumbs Up
    Received: 29
    Given: 7
    Total Downloaded
    802.58 MB

    0 Not allowed!

    Default Re: Rfid read procedure

    Hi,
    Can you explain a bit more.
    Are you using the code from the post I mentioned.
    Are you using the same device.
    Do you get several responses from the serial port such as
    "Loading..."
    "Online..."
    "ATQA: "
    "Token Length: "
    "Card read UID: "
    Regards,
    Bob

  • Attention

    This valuable resource relies upon the very small amount of revenue generated by displaying online advertisements to our visitors.

    The advertisements we display are relevant to this web site and your browsing history

    Please consider supporting us by disabling your ad blocker.


    Note: Some users have reported issues related to ad-blockers rendering parts of this wesite unusable,
    where possible we will rectify the issues to enable you to use this resource with adblocking enabled.

    If you can, please report issues in the forum area WebSite / Forum Issues


    Thank you for your attention.

  • #7
    Junior Member cemati's Avatar
    Join Date
    Oct 2019
    Posts
    6
    Thumbs Up
    Received: 0
    Given: 1
    Total Downloaded
    0

    0 Not allowed!

    Default Re: Rfid read procedure

    I'm trying to write the codes myself from the datasheet. I'm looking at ready code just to understand. so I'm trying to find out which way to take while reading. I understand most of the code section. But I didn't understand RC522_ToCard label. Can you explain these codes?

    Code:
    RC522_ToCard:
      Clear RC522_backLen
      RC522_Status=RC522_MI_ERR
      Clear RC522_irqEn
      Clear RC522_waitIRq
      Clear RC522_lastBits
      Clear n
      Clear i
      
      If RC522_Command=RC522_PCD_AUTHENT Then
        RC522_irqEn=0x12
        RC522_waitIRq=0x10
      End If
      If RC522_Command=RC522_PCD_TRANSCEIVE Then
        RC522_irqEn=0x77
        RC522_waitIRq=0x30
      End If 
      
      RC522_Address=RC522_Reg_ComIEnReg
      RC522_Value=RC522_irqEn | 0x80
      GoSub RC522_Write
      RC522_Address=RC522_Reg_ComIrqReg
      RC522_BitMask=0x80
      GoSub RC522_ClearBitMask
      RC522_Address=RC522_Reg_FIFOLevelReg
      RC522_BitMask=0x80
      GoSub RC522_SetBitMask
      RC522_Address=RC522_Reg_CommandReg
      RC522_Value=RC522_PCD_IDLE
      GoSub RC522_Write
      While i0
        RC522_Address=RC522_Reg_ComIrqReg
        GoSub RC522_Read
        n=RC522_Value
        Dec i
        RC522_Temp=RC522_Value & RC522_waitIRq
        If RC522_Temp>0 Then Break
      Wend
      RC522_Address=RC522_Reg_BitFramingReg
      RC522_BitMask=0x80
      GoSub RC522_ClearBitMask
      If i=0 Then Return
      RC522_Address=RC522_Reg_ErrorReg
      GoSub RC522_Read
      RC522_Temp=RC522_Value & 0x1B
      If RC522_Temp=0 Then
        RC522_Status=RC522_MI_OK
        RC522_Temp=n & RC522_irqEn & 0x01 '?????????????????????????
        If RC522_Temp>0 Then RC522_Status=RC522_MI_NOTAGERR
        If RC522_Command=RC522_PCD_TRANSCEIVE Then
          RC522_Address=RC522_Reg_FIFOLevelReg
          GoSub RC522_Read
          RC522_backLen=RC522_Value
          RC522_Address=RC522_Reg_ControlReg
          GoSub RC522_Read
          RC522_lastBits=RC522_Value & 0x07
          RC522_bitLen=RC522_backLen * 8
          If RC522_lastBits<>0 Then
            RC522_bitLen=RC522_bitLen - 8 + RC522_lastBits
          End If
          If n=0 Then n=1
          If n>RC522_MaxLen Then n=RC522_MaxLen
          Clear i
          While i
    

  • Attention

    This valuable resource relies upon the very small amount of revenue generated by displaying online advertisements to our visitors.

    The advertisements we display are relevant to this web site and your browsing history

    Please consider supporting us by disabling your ad blocker.


    Note: Some users have reported issues related to ad-blockers rendering parts of this wesite unusable,
    where possible we will rectify the issues to enable you to use this resource with adblocking enabled.

    If you can, please report issues in the forum area WebSite / Forum Issues


    Thank you for your attention.

  • #8
    Prolific Poster RGV250's Avatar
    Join Date
    Aug 2005
    Posts
    2,325
    Thumbs Up
    Received: 29
    Given: 7
    Total Downloaded
    802.58 MB

    1 Not allowed!

    Default Re: Rfid read procedure

    Hi,
    Why reinvent the wheel, someone has written code so why not use that.
    I would try the code that is on the forum first at least prove the hardware, one you have done that then you can try your own code.

    Regards,
    Bob

  • Attention

    This valuable resource relies upon the very small amount of revenue generated by displaying online advertisements to our visitors.

    The advertisements we display are relevant to this web site and your browsing history

    Please consider supporting us by disabling your ad blocker.


    Note: Some users have reported issues related to ad-blockers rendering parts of this wesite unusable,
    where possible we will rectify the issues to enable you to use this resource with adblocking enabled.

    If you can, please report issues in the forum area WebSite / Forum Issues


    Thank you for your attention.

  • #9
    Junior Member cemati's Avatar
    Join Date
    Oct 2019
    Posts
    6
    Thumbs Up
    Received: 0
    Given: 1
    Total Downloaded
    0

    0 Not allowed!

    Default Re: Rfid read procedure

    My purpose was to understand and write code. I'll try to code.

    Thank you very much for answers..

    Regards...

  • Attention

    This valuable resource relies upon the very small amount of revenue generated by displaying online advertisements to our visitors.

    The advertisements we display are relevant to this web site and your browsing history

    Please consider supporting us by disabling your ad blocker.


    Note: Some users have reported issues related to ad-blockers rendering parts of this wesite unusable,
    where possible we will rectify the issues to enable you to use this resource with adblocking enabled.

    If you can, please report issues in the forum area WebSite / Forum Issues


    Thank you for your attention.

  • #10
    Prolific Poster RGV250's Avatar
    Join Date
    Aug 2005
    Posts
    2,325
    Thumbs Up
    Received: 29
    Given: 7
    Total Downloaded
    802.58 MB

    0 Not allowed!

    Default Re: Rfid read procedure

    Hi,
    I appreciate you want to understand and write the code yourself but from personal experience knowing that the hardware works first is a great help. I have spent many a time struggling and doubting my code only to find the hardware was at fault.
    If I buy a module and there is an Arduino library for it I generally test it out on the Arduino first to make sure it works before I try to convert over to Proton. I do not try to do a bit for bit conversion as Proton generally makes the codeing a lot neater and simpler.

    Regards,
    Bob

  • Attention

    This valuable resource relies upon the very small amount of revenue generated by displaying online advertisements to our visitors.

    The advertisements we display are relevant to this web site and your browsing history

    Please consider supporting us by disabling your ad blocker.


    Note: Some users have reported issues related to ad-blockers rendering parts of this wesite unusable,
    where possible we will rectify the issues to enable you to use this resource with adblocking enabled.

    If you can, please report issues in the forum area WebSite / Forum Issues


    Thank you for your attention.

  • #11
    Prolific Poster towlerg's Avatar
    Join Date
    Mar 2012
    Posts
    2,208
    Thumbs Up
    Received: 74
    Given: 180
    Total Downloaded
    5.15 GB

    0 Not allowed!

    Default Re: Rfid read procedure

    I have spent many a time struggling and doubting my code only to find the hardware was at fault.
    Ain't that the truth!
    George.

  • Attention

    This valuable resource relies upon the very small amount of revenue generated by displaying online advertisements to our visitors.

    The advertisements we display are relevant to this web site and your browsing history

    Please consider supporting us by disabling your ad blocker.


    Note: Some users have reported issues related to ad-blockers rendering parts of this wesite unusable,
    where possible we will rectify the issues to enable you to use this resource with adblocking enabled.

    If you can, please report issues in the forum area WebSite / Forum Issues


    Thank you for your attention.

    Thread Information

    Users Browsing this Thread

    There are currently 1 users browsing this thread. (0 members and 1 guests)

       

    Similar Threads

    1. RC522 RFID Code
      By mjturner in forum The Lounge
      Replies: 8
      Last Post: 25th August 2018, 12:31
    2. procedure to print
      By Jezsmith in forum Proton 24
      Replies: 8
      Last Post: 14th December 2014, 11:01
    3. Rfid
      By hassawfaa in forum Proton Plus Compiler v3
      Replies: 11
      Last Post: 13th August 2014, 18:06
    4. [SOLVED !] Rfid with EM4095
      By Mat_Jonno in forum Proton Plus Compiler v3
      Replies: 3
      Last Post: 18th September 2010, 06:45
    5. Replies: 0
      Last Post: 8th February 2008, 09:30

    Members who have read this thread : 34

    Actions :  (Set Date)

    You do not have permission to view the list of names.

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts