Spark Logic

[Solved] PN532 library from Adafruit not working

Hello,
Previously, I use ESP8266ESP8266Microcontrollers and processors…working, on the Arduino.cc forum The ESP thing looks similar, but at the moment, www. esp8266 .com is not responding, so I’ll take a look later to see if it seems to be the same b…View in hardware catalog to connect to PN532PN532Communications, navigation, interfaces and RFIDSpark Logic archive [Solved] PN532 library from Adafruit not working maman Tue May 22, 2018 5:43 am Hello, Previously, I use esp8266 t…View in hardware catalog NFC module, using this library :
https://github.com/elechouse/PN532

Now, I want to change to STM32F1STM32F1Microcontrollers and processors…w I am not able to compile. Error message: “C:\arduino-1.6.12\hardware\Arduino_STM32\ STM32F1 \cores\maple/boards.h:39:25: fatal error: board/board.h: No such file or directory” I…View in hardware catalog core as the processor. However, it seem that the wire.h
library of STM32arduino is not compatible with the wire.h of the ESP8266ESP8266Microcontrollers and processors…working, on the Arduino.cc forum The ESP thing looks similar, but at the moment, www. esp8266 .com is not responding, so I’ll take a look later to see if it seems to be the same b…View in hardware catalog arduino library.

Is there any alternative of wire.h STM32F1STM32F1Microcontrollers and processors…w I am not able to compile. Error message: “C:\arduino-1.6.12\hardware\Arduino_STM32\ STM32F1 \cores\maple/boards.h:39:25: fatal error: board/board.h: No such file or directory” I…View in hardware catalog arduino library ?

Thanks,
Regards,

Replies14

Tue May 22, 2018 6:07 am

This section is for people to post introduce themselves

After that you can post a question into the relevant section

Please read this post about where to find information

http://stm32duino.com/viewtopic.php?f=2&t=3111

Tue May 22, 2018 10:22 am

Let me introduce, I am from Indonesia, working in a university.
Previously, I have developed parking system using NFC/RFID card.
I used ESP8266ESP8266Microcontrollers and processors…working, on the Arduino.cc forum The ESP thing looks similar, but at the moment, www. esp8266 .com is not responding, so I’ll take a look later to see if it seems to be the same b…View in hardware catalog as the main processor, however, I found it is not stable in the I2C interface.
Therefore, I want to try to use STM32F1STM32F1Microcontrollers and processors…w I am not able to compile. Error message: “C:\arduino-1.6.12\hardware\Arduino_STM32\ STM32F1 \cores\maple/boards.h:39:25: fatal error: board/board.h: No such file or directory” I…View in hardware catalog as the main processor.

For the NFC reader, I use PN532PN532Communications, navigation, interfaces and RFIDSpark Logic archive [Solved] PN532 library from Adafruit not working maman Tue May 22, 2018 5:43 am Hello, Previously, I use esp8266 t…View in hardware catalog with the following library https://github.com/elechouse/PN532.
However, it is failed to compile. It seem that the wire.h library of STM32STM32Microcontrollers and processors…Map magic glue code, ethernet compiles, just WARNING: library LwIP claims to run on [ stm32 ] architecture(s) and may be incompatible with your current board which runs on [STM32]…View in hardware catalog arduino core is not
compatible with the wire library of ESP8266ESP8266Microcontrollers and processors…working, on the Arduino.cc forum The ESP thing looks similar, but at the moment, www. esp8266 .com is not responding, so I’ll take a look later to see if it seems to be the same b…View in hardware catalog .

Is there anyone have used PN532PN532Communications, navigation, interfaces and RFIDSpark Logic archive [Solved] PN532 library from Adafruit not working maman Tue May 22, 2018 5:43 am Hello, Previously, I use esp8266 t…View in hardware catalog module ? which PN532PN532Communications, navigation, interfaces and RFIDSpark Logic archive [Solved] PN532 library from Adafruit not working maman Tue May 22, 2018 5:43 am Hello, Previously, I use esp8266 t…View in hardware catalog library did you use ?

This is the error code when I compiled one of the example program,
In file included from C:\Users\LENOVO\AppData\Local\Temp\arduino_modified_sketch_142934\iso14443a_uid.pde:19:0:

C:\Users\LENOVO\Documents\Arduino\libraries\PN532PN532Communications, navigation, interfaces and RFIDSpark Logic archive [Solved] PN532 library from Adafruit not working maman Tue May 22, 2018 5:43 am Hello, Previously, I use esp8266 t…View in hardware catalog _I2C/PN532PN532Communications, navigation, interfaces and RFIDSpark Logic archive [Solved] PN532 library from Adafruit not working maman Tue May 22, 2018 5:43 am Hello, Previously, I use esp8266 t…View in hardware catalog _I2C.h: In member function 'uint8_t PN532PN532Communications, navigation, interfaces and RFIDSpark Logic archive [Solved] PN532 library from Adafruit not working maman Tue May 22, 2018 5:43 am Hello, Previously, I use esp8266 t…View in hardware catalog _I2C::write(uint8_t)':

C:\Users\LENOVO\Documents\Arduino\libraries\PN532PN532Communications, navigation, interfaces and RFIDSpark Logic archive [Solved] PN532 library from Adafruit not working maman Tue May 22, 2018 5:43 am Hello, Previously, I use esp8266 t…View in hardware catalog _I2C/PN532PN532Communications, navigation, interfaces and RFIDSpark Logic archive [Solved] PN532 library from Adafruit not working maman Tue May 22, 2018 5:43 am Hello, Previously, I use esp8266 t…View in hardware catalog _I2C.h:29:37: error: void value not ignored as it ought to be

return _wire->write(data);

Tue May 22, 2018 1:03 pm

As the write() function of the Wire library from libmaple core does not return any value, you should change line 29 of the header file to:
  _wire->write(data);
return 1;

Tue May 22, 2018 9:50 pm

Steve,

I just checked Ardunos SAMD core and and it’s write() functions return size_t, so I need to change the function signatures

Wed May 23, 2018 3:16 am

Thanks, Steve and Rogerclark.
I have been check the PN532PN532Communications, navigation, interfaces and RFIDSpark Logic archive [Solved] PN532 library from Adafruit not working maman Tue May 22, 2018 5:43 am Hello, Previously, I use esp8266 t…View in hardware catalog library of Adafruit, too.
https://github.com/adafruit/Adafruit-PN532.
it can be compiled, but it does’nt worked.
It runs the setup part of the program, but halt at the loop part.
I used one of the examples of the library.

Regards,
Maman

Wed May 23, 2018 8:08 am

I’ve updated the Wire library to be compatible with the Arduino API

However that library still won’t compile because it defaults to defining WIRE to wire1 for the STM32STM32Microcontrollers and processors…Map magic glue code, ethernet compiles, just WARNING: library LwIP claims to run on [ stm32 ] architecture(s) and may be incompatible with your current board which runs on [STM32]…View in hardware catalog because of IMHO incorrect programming

#if defined(__AVR__) || defined(__i386__) || defined(ARDUINO_ARCH_SAMD) || defined(ESP8266) || defined(ARDUINO_ARCH_STM32)
#define WIRE Wire
#else // Arduino Due
#define WIRE Wire1
#endif

Wed May 23, 2018 9:23 am

[RogerClark – Wed May 23, 2018 8:08 am] –
But I find it pointless to put PR’s into Adafruit as they usually have their own agenda and these libs are primarily written to support products they sell.

I’ve already submit a PR to Adafruit and it has been merged ;)
https://github.com/adafruit/Adafruit_MQ … ry/pull/95

Wed May 23, 2018 9:31 am

I think it depends if the PR is to fix a bug or to support another board.

If the @op wants to send a PR to Adafruit he can do that, but there are probably loads of other Adafruit libs that also don’t work with the STM32STM32Microcontrollers and processors…Map magic glue code, ethernet compiles, just WARNING: library LwIP claims to run on [ stm32 ] architecture(s) and may be incompatible with your current board which runs on [STM32]…View in hardware catalog

An alternative is to define

ARDUINO_ARCH_STM32STM32Microcontrollers and processors…Map magic glue code, ethernet compiles, just WARNING: library LwIP claims to run on [ stm32 ] architecture(s) and may be incompatible with your current board which runs on [STM32]…View in hardware catalog

As I see the STM core does this

I think thats probably the best option

Wed May 23, 2018 9:34 am

Yep.

I’m going to define ARDUINO_ARCH_STM32STM32Microcontrollers and processors…Map magic glue code, ethernet compiles, just WARNING: library LwIP claims to run on [ stm32 ] architecture(s) and may be incompatible with your current board which runs on [STM32]…View in hardware catalog in platform.txt

Edit.

Done.

Wed May 23, 2018 9:57 am

All cores provide the -DARDUINO_ARCH_{build.arch}

Wed May 23, 2018 9:58 am

I agree it won’t make it compatible with everything

But just a bit more compatible with some libs

Thu May 24, 2018 2:06 am

Today, I test the new STM32STM32Microcontrollers and processors…Map magic glue code, ethernet compiles, just WARNING: library LwIP claims to run on [ stm32 ] architecture(s) and may be incompatible with your current board which runs on [STM32]…View in hardware catalog arduino package.
It can be compiled and can read the MIFARE card.
But only at the beginning, after one or two time reading of the card,
the board will be hanged, need to reset.

Regards,

Thu May 24, 2018 4:25 am

[maman – Thu May 24, 2018 2:06 am] –
Today, I test the new STM32STM32Microcontrollers and processors…Map magic glue code, ethernet compiles, just WARNING: library LwIP claims to run on [ stm32 ] architecture(s) and may be incompatible with your current board which runs on [STM32]…View in hardware catalog arduino package.
It can be compiled and can read the MIFARE card.
But only at the beginning, after one or two time reading of the card,
the board will be hanged, need to reset.

Regards,

Unfortunately, some libraries only work when they are run on the hardware they were designed to run on.

A large percentage of libraries have to be “ported” to run on the STM32STM32Microcontrollers and processors…Map magic glue code, ethernet compiles, just WARNING: library LwIP claims to run on [ stm32 ] architecture(s) and may be incompatible with your current board which runs on [STM32]…View in hardware catalog as they are at least 5 times faster than the Arduino UnoArduino UnoDevelopment and computing boards…ime debugging. konczakp Mon Jul 18, 2016 12:18 pm OK, so I took working example from Arduino UNO . I’ve cut off everything from library that I don’t need and from rest I have crea…View in hardware catalog and have a completely different architecture, this involves debugging both the software and possible using a logic analyser to understand why the software is not working

You also need to confirm that you application code would work even when running on an AVRAVRMicrocontrollers and processors…Arduino\libraries\U8glib\U8glib.cpp, C:\Program Files (x86)\Arduino\hardware\arduino\ avr \cores\arduino\HardwareSerial.h, C:\Program Files (x86)\Arduino/Blink3.ino, D:\Users\me\A…View in hardware catalog (e.g Uno), as its not necessarily a fault in the library which is causing your problem

Sat May 26, 2018 7:20 am

Thanks Roger, for your help.

I confirmed that the PN532PN532Communications, navigation, interfaces and RFIDSpark Logic archive [Solved] PN532 library from Adafruit not working maman Tue May 22, 2018 5:43 am Hello, Previously, I use esp8266 t…View in hardware catalog library is working for UNO and ESP8266ESP8266Microcontrollers and processors…working, on the Arduino.cc forum The ESP thing looks similar, but at the moment, www. esp8266 .com is not responding, so I’ll take a look later to see if it seems to be the same b…View in hardware catalog .
https://github.com/elechouse/PN532
In the previous worked, I have been used this library many times.
It is no problem at all if we are using UNO, while on ESP8266ESP8266Microcontrollers and processors…working, on the Arduino.cc forum The ESP thing looks similar, but at the moment, www. esp8266 .com is not responding, so I’ll take a look later to see if it seems to be the same b…View in hardware catalog , it is not stable,
because actually in ESP8266ESP8266Microcontrollers and processors…working, on the Arduino.cc forum The ESP thing looks similar, but at the moment, www. esp8266 .com is not responding, so I’ll take a look later to see if it seems to be the same b…View in hardware catalog , I2C is not a hardware solution.

Probably, I have to try other PN532PN532Communications, navigation, interfaces and RFIDSpark Logic archive [Solved] PN532 library from Adafruit not working maman Tue May 22, 2018 5:43 am Hello, Previously, I use esp8266 t…View in hardware catalog board.

best regards,

Post a reply

Optional · up to 10 MiB