The i.MX8M mini evk (see i.MX 8M Mini Evaluation Kit | NXP) featuring Raspberry Pi compliant connector, the OM5578/RPI PN7150 demo kit can be used to perform this porting (see NFC Development Kits for Arduino and more|NXP). However a small modification must be done because some of the signals required by PN7150 are not mapped to i.MX8M mini expansion connector pins.
OM5578 IRQ signal must be mapped to Raspberry Pi connector pin #19 and OM5578 VEN signal must be mapped to Raspberry Pi connector pin #21.
See below a picture of the modification:
Then, the two boards can fit together as shown in the picture below:
The demo image including support for PN7150, is based on Android P9.0.0 Pie (P9.0.0_1.0.0, 4.14 kernel) i.MX software release (see i.MX Software | NXP).
Related documentation can be downloaded from here: https://www.nxp.com/docs/en/supporting-information/android_p9.0.0_1.0.0-ga_docs.zip.
Just flash the demo image (downloaded from here:https://www.nxp.com/lgfiles/updates/NFC/ANDROID_P9-0-0_PN7150_IMAGE_8MMEVK.zip) following guidelines from i.MX_Android_Quick_Start document (part of Android P9.0.0_1.0.0 Documentation package mentioned above).
The NFC support is then included in the device settings, as shown in below screenshot of the device:
Approaching the NFC tag, provided as reference in the OM5578 demo kit, to the NFC Antenna will trigger a sound notification:
Unfortunately the Android demo image doesn't embed a web browser, so it won't be automatically open when the NFC tag content (an URL to the demo kit web page) is read. Otherwise (if a web browser is installed) you could see such page opening on the device:
If you wish to add PN7150 support to your imx-android-pie environment, just apply the patches (imx-p9.0.0_1.0.0-ga_pn7150_patches.tar.gz file attached) from the ${MY_ANDROID} source code root folder (refer to i.MX_Android_User_Guide document part of Android P9.0.0_1.0.0 Documentation package mentioned above).
$ patch -p1 -d device/fsl/ <device_fsl.patch
$ patch -p1 -d packages/apps/Nfc <packages_apps_Nfc.patch
$ patch -p1 -d hardware/nxp/nfc <hardware_nxp_nfc.patch$ patch -p1 -d vendor/nxp <vendor_nxp.patch
$ patch -p1 -d vendor/nxp-opensource/kernel_imx/ <vendor_nxp-opensource_kernel_imx.patch
When building, the PN7150 support will then be included to the android image, as shown in the demo image described above.
This porting have been done (demo image and patches creation) following guidelines provided in AN11690_NXP-NCI_Android_Porting_Guidelines document.
Hi Jeremy, this patch also fit with imx-p9.0.0_2.0.0-ga too?
Thank you!
Hi,
Yes the imx-p9.0.0_1.0.0-ga_pn7150_patches should applies quietly to imx-p9.0.0_2.0.0-ga version.
Regards,
Jeremy.
Thanks for reply,
After the patched, our PN7150 is working on our board with imx-p9.0.0_2.0.0-ga version!