Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/majerle/lwjson
Lightweight JSON parser for embedded systems
https://github.com/majerle/lwjson
embedded javascript javascript-object-notation json lightweight microcontroller optimization parser reader stream streaming systems
Last synced: 4 days ago
JSON representation
Lightweight JSON parser for embedded systems
- Host: GitHub
- URL: https://github.com/majerle/lwjson
- Owner: MaJerle
- License: mit
- Created: 2020-11-30T22:14:06.000Z (about 4 years ago)
- Default Branch: develop
- Last Pushed: 2024-10-01T12:11:56.000Z (4 months ago)
- Last Synced: 2025-01-18T22:40:20.315Z (11 days ago)
- Topics: embedded, javascript, javascript-object-notation, json, lightweight, microcontroller, optimization, parser, reader, stream, streaming, systems
- Language: C
- Homepage: https://majerle.eu/projects/lwjson-lightweight-json-parser
- Size: 461 KB
- Stars: 151
- Watchers: 9
- Forks: 36
- Open Issues: 8
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Funding: .github/FUNDING.yml
- License: LICENSE
- Authors: AUTHORS
Awesome Lists containing this project
README
# Lightweight JSON text parser
Library provides generic JSON text parser, that is optimized for embedded systems.
Supports `streaming` parsing or classic parsing with full JSON data available in one big linear memory.
First one being optimized for ultra small microcontrollers, second one being ready for PC applications - or simply when several kB of RAM memory is available at any given point of timeRead first: Documentation
## Features
* Written in C (C11), compatible with ``size_t`` for size data types
* RFC 4627 and RFC 8259 compliant
* Based on static token allocation with optional application dynamic pre-allocation
* No recursion during parse operation
* Re-entrant functions
* Zero-copy, no ``malloc`` or ``free`` functions used
* Supports streaming parsing as secondary option
* Optional support for inline comments with `/* comment... */` syntax between any *blank* region of input string
* Advanced find algorithm for tokens
* Test coverage is available
* User friendly MIT license## Contribute
Fresh contributions are always welcome. Simple instructions to proceed:
1. Fork Github repository
2. Follow [C style & coding rules](https://github.com/MaJerle/c-code-style) already used in the project
3. Create a pull request to develop branch with new features or bug fixesAlternatively you may:
1. Report a bug
2. Ask for a feature request