Grove NFC v1.1 does not work with UART

Grove is a modulated, ready-to-use tool set.
Much like Lego, it takes a building block approach to assembling electronics.

Moderators: lily.li, violet, jeremy882, crail.lyu969

ryoku12345
Pre-kindergarten
Pre-kindergarten
Posts: 8
Joined: Wed Jul 10, 2019 2:57 pm

Grove NFC v1.1 does not work with UART

Post by ryoku12345 » Wed Jul 10, 2019 3:07 pm

Hello,

I have bought a Grove NFC module v1.1 from Seedstudio and want to connect it to my Arduino Leonardo via UART. I know that communication via UART is the default mode. I have followed the instructions on the seed wiki website and installed all the required libraries. I have uploaded the example code for reading NFC tags via UART but it does not work.
I know that my NFC Tags are working with the Grove NFC module, because I can read them with another Grove NFC module connected via I2C.
I have tried using the Module with 3,3V and 5V. I have tried switching TX and RX.

I would appreciate any helpful advice.

595355940
Pre-kindergarten
Pre-kindergarten
Posts: 34
Joined: Tue Oct 23, 2018 5:33 pm

Re: Grove NFC v1.1 does not work with UART

Post by 595355940 » Fri Jul 12, 2019 2:25 pm

Hi there!
Arduino Leonardo only one UART,So not support the UART mode of Grove NFC v1.1.And ,When I used mage2560 to run the demo, it succeeded. :D

ryoku12345
Pre-kindergarten
Pre-kindergarten
Posts: 8
Joined: Wed Jul 10, 2019 2:57 pm

Re: Grove NFC v1.1 does not work with UART

Post by ryoku12345 » Wed Jul 24, 2019 9:34 pm

Hi,

thank you for replying to my post. I thought connecting via UART with a Leonoardo should work because it is recommended on the Wiki.
I tried connecting the Grove NFC module to my Arduino UNO via UART and it worked.

bill.yu
Junior-7
Junior-7
Posts: 732
Joined: Mon Apr 02, 2018 11:05 am

Re: Grove NFC v1.1 does not work with UART

Post by bill.yu » Fri Jul 26, 2019 5:58 pm

Hi there~

Please post your code and we can test it here. thanks.

ryoku12345
Pre-kindergarten
Pre-kindergarten
Posts: 8
Joined: Wed Jul 10, 2019 2:57 pm

Re: Grove NFC v1.1 does not work with UART

Post by ryoku12345 » Tue Jul 30, 2019 2:35 pm

Hi,
I am using the example Code from the wiki plus adding a few lines for visual feedback.
I get the "Scan a NFC tag" message on my serial monitor but it does not detect a Tag.

It worked with my Arduino UNO when I changed Serial1 to Serial, but that does not work with Leonardo. I get an error message
during compilation.

Code: Select all

#include "PN532_HSU.h"
#include "PN532.h"
#include "NfcAdapter.h"

PN532_HSU interface(Serial1);
NfcAdapter nfc = NfcAdapter(interface);

#define rLED 8

void setup(void) {
  Serial.begin(115200);
  nfc.begin();
  Serial.println("NDEF Reader");
  pinMode(rLED, OUTPUT);

  // testing LED functionality
  digitalWrite(rLED, HIGH);
  delay(200);
  digitalWrite(rLED, LOW);
  delay(200);
  digitalWrite(rLED, HIGH);
  delay(200);
  digitalWrite(rLED, LOW);


}

void loop(void) {
  Serial.println("\nScan a NFC tag\n");
  if (nfc.tagPresent())
  {
    digitalWrite(rLED, HIGH);
    delay(500);
    digitalWrite(rLED, LOW);
    NfcTag tag = nfc.read();
    tag.print();
  }
  delay(5000);
}

testpresta2
Pre-kindergarten
Pre-kindergarten
Posts: 5
Joined: Thu Aug 01, 2019 5:45 pm

Re: Grove NFC v1.1 does not work with UART

Post by testpresta2 » Thu Aug 01, 2019 5:49 pm

I have exactly the same problem.

Is there someone from seeed company which can answer to this questions:

- The officiel documentation is talking about 1.0 NFC module. But i have 1.1 NFC Module. There are no documentations about 1.1 version. The soldering jumpers are not the same than the ones describes on the documentation. So does UART enabled by default ?

- The official documentation connects the NFC Grove Module to UART on Grove base shield. This connector is mapped on Serial (pins 0 and 1 of Arduino). but the sample program contains Serial1. Where is the mistake ?

- And i have a last question: How can i connect 3 NFC modules to the same Arduino. I have a base shield with 4 I2C connectors. But how can i "address" my modules ?

Your documentation is very poor. I regret choosing your module. Please answer and update your documentation.

Thanks

bill.yu
Junior-7
Junior-7
Posts: 732
Joined: Mon Apr 02, 2018 11:05 am

Re: Grove NFC v1.1 does not work with UART

Post by bill.yu » Fri Aug 02, 2019 4:37 pm

ryoku12345 wrote:
Tue Jul 30, 2019 2:35 pm
Hi,
I am using the example Code from the wiki plus adding a few lines for visual feedback.
I get the "Scan a NFC tag" message on my serial monitor but it does not detect a Tag.

It worked with my Arduino UNO when I changed Serial1 to Serial, but that does not work with Leonardo. I get an error message
during compilation.

Code: Select all

#include "PN532_HSU.h"
#include "PN532.h"
#include "NfcAdapter.h"

PN532_HSU interface(Serial1);
NfcAdapter nfc = NfcAdapter(interface);

#define rLED 8

void setup(void) {
  Serial.begin(115200);
  nfc.begin();
  Serial.println("NDEF Reader");
  pinMode(rLED, OUTPUT);

  // testing LED functionality
  digitalWrite(rLED, HIGH);
  delay(200);
  digitalWrite(rLED, LOW);
  delay(200);
  digitalWrite(rLED, HIGH);
  delay(200);
  digitalWrite(rLED, LOW);


}

void loop(void) {
  Serial.println("\nScan a NFC tag\n");
  if (nfc.tagPresent())
  {
    digitalWrite(rLED, HIGH);
    delay(500);
    digitalWrite(rLED, LOW);
    NfcTag tag = nfc.read();
    tag.print();
  }
  delay(5000);
}


Hi ~, We see the same issue and we are looking @ the issue and keep you posted. thanks.

testpresta2
Pre-kindergarten
Pre-kindergarten
Posts: 5
Joined: Thu Aug 01, 2019 5:45 pm

Re: Grove NFC v1.1 does not work with UART

Post by testpresta2 » Fri Aug 02, 2019 7:26 pm

Can anyone from seedstudio answer to this question: Does this devices works with SPI ?
The tutorials shows a SPI folder but it not written anywhere if we can use SPI

bill.yu
Junior-7
Junior-7
Posts: 732
Joined: Mon Apr 02, 2018 11:05 am

Re: Grove NFC v1.1 does not work with UART

Post by bill.yu » Mon Aug 05, 2019 3:00 pm

testpresta2 wrote:
Fri Aug 02, 2019 7:26 pm
Can anyone from seedstudio answer to this question: Does this devices works with SPI ?
The tutorials shows a SPI folder but it not written anywhere if we can use SPI

Hi there~,

It does not support SPI. You can see from below schematic that the SCL and MISO are not connected. thanks.

Image

bill.yu
Junior-7
Junior-7
Posts: 732
Joined: Mon Apr 02, 2018 11:05 am

Re: Grove NFC v1.1 does not work with UART

Post by bill.yu » Mon Aug 05, 2019 3:41 pm

testpresta2 wrote:
Thu Aug 01, 2019 5:49 pm
I have exactly the same problem.

Is there someone from seeed company which can answer to this questions:

- The officiel documentation is talking about 1.0 NFC module. But i have 1.1 NFC Module. There are no documentations about 1.1 version. The soldering jumpers are not the same than the ones describes on the documentation. So does UART enabled by default ?

- The official documentation connects the NFC Grove Module to UART on Grove base shield. This connector is mapped on Serial (pins 0 and 1 of Arduino). but the sample program contains Serial1. Where is the mistake ?

- And i have a last question: How can i connect 3 NFC modules to the same Arduino. I have a base shield with 4 I2C connectors. But how can i "address" my modules ?

Your documentation is very poor. I regret choosing your module. Please answer and update your documentation.

Thanks
Hi there~

Please see below replies.

- The officiel documentation is talking about 1.0 NFC module. But i have 1.1 NFC Module. There are no documentations about 1.1 version. The soldering jumpers are not the same than the ones describes on the documentation. So does UART enabled by default ?

The differences between v1.1 and v1.0 is 2 pads added on v1.1.
The UART is enabled by default for v1.1.
Image


- The official documentation connects the NFC Grove Module to UART on Grove base shield. This connector is mapped on Serial (pins 0 and 1 of Arduino). but the sample program contains Serial1. Where is the mistake ?

The code is used for the seeeduino lite(ATmega32u4), it has 2 uarts ports, one is serial1(digital 0/1) and the other is the micro usb port(serial). So the serial1 is right. But there is some issue with the whole code and we are looking @ the issue now.

- And i have a last question: How can i connect 3 NFC modules to the same Arduino. I have a base shield with 4 I2C connectors. But how can i "address" my modules ?

The Grove-RFC does not have the hardware i2c address configure, you can consider to use the software i2c.
https://github.com/felias-fogg/SoftI2CMaster

For the wiki and bazaar page, we sales with v1.1 now. We will update it by this week. thanks.

Post Reply