Skip to main content

Parse or generate NDEF messages

Python Package Stable Documentation Latest Documentation Build Status Code Coverage

The ndeflib is an ISC-licensed Python package for parsing and generating NFC Data Exchange Format (NDEF) messages:

>>> import ndef
>>> hexstr = '9101085402656e48656c6c6f5101085402656e576f726c64'
>>> octets = bytearray.fromhex(hexstr)
>>> for record in ndef.message_decoder(octets): print(record)
NDEF Text Record ID '' Text 'Hello' Language 'en' Encoding 'UTF-8'
NDEF Text Record ID '' Text 'World' Language 'en' Encoding 'UTF-8'
>>> message = [ndef.TextRecord("Hello"), ndef.TextRecord("World")]
>>> b''.join(ndef.message_encoder(message)) == octets
True

The ndeflib documentation can be found on Read the Docs, the code on GitHub. It is continously tested for Python 2.7 and 3.5 with pretty complete test coverage.

Metadata

Release files for ndeflib 0.3.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ndeflib 0.3.0
File Size Uploaded
ndeflib-0.3.0.tar.gz 143.1 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for ndeflib 0.3.0
File Interpreter ABI Platform
ndeflib-0.3.0-py2.py3-none-any.whl Python 3, Python 2 none any Details

Total release size: 201.0 kB

Release files / ndeflib-0.3.0.tar.gz

Download URL ndeflib-0.3.0.tar.gz
Size 143.1 kB
Tags Source
SHA-256 checksum
How to use checksums
da79836df6bde86732b6110e5f4344cc051b5ec8d67680ac5552c59f005084c7
BLAKE2b-256 checksum
How to use checksums
961aa792c5fe410a81d71dc71aa31ef51427dbc9f48a7b422cb98cf4beacc363
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / ndeflib-0.3.0-py2.py3-none-any.whl

Download URL ndeflib-0.3.0-py2.py3-none-any.whl
Size 57.9 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
4d28449ac2bc9e14cc9dfe5f651d04488312ae910550540987e2618e1b4555a3
BLAKE2b-256 checksum
How to use checksums
605de7b16bef1fde87fa36464b20c51f6c8cbe7b007deccaa89f8fe35ce0a73c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

0.3.3

2 release files

0.3.2

2 release files

0.3.1

2 release files

This release

0.3.0 This release

2 release files

0.2.0

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page