# varch **Repository Path**: Lamdonn/varch ## Basic Information - **Project Name**: varch - **Description**: 嵌入式C语言常用代码模块库,包含了嵌入式中常用的算法库(查找、校验、过滤、哈希、排序等)、数据结构/容器库(通用队列、栈、堆、列表、动态数组、字符串、集合、字典、映射、图等)、解析器库(csv、ini、json、xml、yaml等)、数学库(大数运算、数学运算)、独立C语言std库、工具库等等。 具有简单、通用、高效的特点,目的为了学习以及在开发中拿来就用,提高开发效率以及代码可靠稳定性。 - **Primary Language**: Unknown - **License**: GPL-2.0 - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 271 - **Forks**: 120 - **Created**: 2024-04-22 - **Last Updated**: 2025-09-07 ## Categories & Tags **Categories**: utils **Tags**: None ## README # varch ![logo](/image/logo.png) [![Version](https://img.shields.io/badge/version-0.3.4-blue.svg)](https://gitee.com/Lamdonn/varch) [![License](https://img.shields.io/badge/license-GPL%202.0-brightgreen.svg)](LICENSE) [![Author](https://img.shields.io/badge/author-Lamdonn%20%20%20%20%20-brightblue.svg)](Lamdonn@163.com) ![Supported Platforms](https://img.shields.io/badge/platform-Linux%20&%20MinGW-yellow.svg) ## Introduction [中文版](README.md) varch (we architecture, meaning our framework library) is a commonly used code module library for embedded C language, including the commonly used embedded algorithm library (search, check, filter, hash, sort, etc.), data structure/container library (general queue, stack, heap, list, dynamic array, string, set, dictionary, map, graph, etc.), parser library (csv, ini, json, xml, etc.), mathematical library (large number operation, mathematical operation), independent C language st d library, utility library, etc. It has the characteristics of **simplicity, universality, and efficiency**, with the aim of **learning** and **using it immediately** in development, improving development efficiency and code reliability and stability. ## Content | module | version | usage | path | describe | |:-------------|:---------|:-----------------------------|:------------------------------------------|:--------------------------------------| | overall | 00.03.03 | [link](README.en.md) | [path](./) | Overall | init | 01.00.00 | [link](/doc/init.en.md) | [path](./source/00_application) | Initialize export module | console | 01.00.01 | [link](/doc/console.en.md) | [path](./source/00_application/console) | Console command input, combined with the 'command' module, parsing commands entered in the console | arg | 01.00.00 | [link](/doc/arg.en.md) | [path](./source/01_general) | Indefinite parameters, obtain the number of indefinite parameters and specified parameters | calculate | 01.01.00 | [link](/doc/calculate.en.md) | [path](./source/01_general) | Calculation module, input calculation expression to obtain calculation result | command | 01.00.00 | [link](/doc/command.en.md) | [path](./source/01_general) | Command parsing module, input string commands (similar to shell commands), execute corresponding command functions | cPatten | 01.00.00 | [link](/doc/cPatten.en.md) | [path](./source/01_general) | Artistic character patterns | cQueue | 01.00.01 | [link](/doc/cQueue.en.md) | [path](./source/01_general) | Universal queue controller | sList | 01.00.01 | [link](/doc/sList.en.md) | [path](./source/01_general) | Universal single-link list controller | dList | 01.00.01 | [link](/doc/dList.en.md) | [path](./source/01_general) | Universal double-link list controller | fsm | 01.00.00 | [link](/doc/fsm.en.md) | [path](./source/01_general) | Universal finite state machine module | kern | 01.00.00 | [link](/doc/kern.en.md) | [path](./source/01_general) | The kernel module for scheduling periodic tasks is mostly used in varch testing | oscp | 01.00.00 | [link](/doc/oscp.en.md) | [path](./source/01_general) | Analog oscilloscope module, can easily monitor the waveform of variable changes | tool | 01.01.00 | [link](/doc/tool.en.md) | [path](./source/01_general) | General tools code | valloc | 01.00.00 | [link](/doc/valloc.en.md) | [path](./source/01_general) | Dynamic memory usage testing tool | vlog | 01.01.00 | [link](/doc/vlog.en.md) | [path](./source/01_general) | Log output module | date | 01.00.00 | [link](/doc/date.en.md) | [path](./source/01_general) | Date calculation module, calculating date differences, printing calendars, etc | vctype | 01.00.00 | [link](/doc/vctype.en.md) | [path](./source/02_vstd) | Similar to the C standard library ctype | vmath | 01.00.00 | [link](/doc/vmath.en.md) | [path](./source/02_vstd) | Similar to the C standard library math | vmem | 01.00.00 | [link](/doc/vmem.en.md) | [path](./source/02_vstd) | Simple implementation of memory pool | vstddef | 01.00.00 | [link](/doc/vstddef.en.md) | [path](./source/02_vstd) | Similar to the C standard library stddef | vstdint | 01.00.00 | [link](/doc/vstdint.en.md) | [path](./source/02_vstd) | Similar to the C standard library stdint | vstdlib | 01.00.00 | [link](/doc/vstdlib.en.md) | [path](./source/02_vstd) | Similar to the C standard library stdlib | vstring | 01.00.00 | [link](/doc/vstring.en.md) | [path](./source/02_vstd) | Similar to the C standard library string | queue | 01.00.00 | [link](/doc/queue.en.md) | [path](./source/03_container) | Universal queue container | stack | 01.00.00 | [link](/doc/stack.en.md) | [path](./source/03_container) | Universal stack container | deque | 01.00.00 | [link](/doc/deque.en.md) | [path](./source/03_container) | Universal double-end queue container | list | 01.00.00 | [link](/doc/list.en.md) | [path](./source/03_container) | Universal list container, single-link and internal iteration | vector | 01.00.00 | [link](/doc/vector.en.md) | [path](./source/03_container) | Universal vector(array) container | str | 01.00.00 | [link](/doc/str.en.md) | [path](./source/03_container) | String class | dict | 01.00.00 | [link](/doc/dict.en.md) | [path](./source/03_container) | Universal dictionarie container, implementation based on hash table | heap | 01.00.00 | [link](/doc/heap.en.md) | [path](./source/03_container) | Universal heap container | set | 01.00.00 | [link](/doc/set.en.md) | [path](./source/03_container) | Universal set container, implementation based on RB-tree | map | 01.00.00 | [link](/doc/map.en.md) | [path](./source/03_container) | Universal map container, implementation based on RB-tree | tree | 01.00.00 | [link](/doc/tree.en.md) | [path](./source/03_container) | Universal tree container | graph | 01.00.00 | [link](/doc/graph.en.md) | [path](./source/03_container) | Universal graph container | check | 01.00.00 | [link](/doc/check.en.md) | [path](./source/04_algorithm) | Verification algorithm, sum check, parity check, XOR check, LRC check | crc | 01.00.00 | [link](/doc/crc.en.md) | [path](./source/04_algorithm) | Universal and standard CRC algorithms | encrypt | 01.00.00 | [link](/doc/encrypt.en.md) | [path](./source/04_algorithm) | Encryption and decryption algorithms | filter | 01.00.00 | [link](/doc/filter.en.md) | [path](./source/04_algorithm) | Filter algorithms, median, kalman, average | hash | 01.00.00 | [link](/doc/hash.en.md) | [path](./source/04_algorithm) | Hash algorithms, bkdr, ap, djb, js, rs, sdbm, pjw, elf, dek, bp, fnv, jdk6 | pid | 01.00.00 | [link](/doc/pid.en.md) | [path](./source/04_algorithm) | PID control algorithm calculator | search | 01.00.00 | [link](/doc/search.en.md) | [path](./source/04_algorithm) | Universal search algorithms, linear, binary | sort | 01.00.00 | [link](/doc/sort.en.md) | [path](./source/04_algorithm) | Universal sorting algorithms (various data structures), bubble, select, insert, hill, quick, heap | csv | 01.00.00 | [link](/doc/csv.en.md) | [path](./source/05_parser) | CSV file parsing generator | ini | 01.00.00 | [link](/doc/ini.en.md) | [path](./source/05_parser) | INI configuration file parsing generator | json | 01.00.00 | [link](/doc/json.en.md) | [path](./source/05_parser) | JSON file parsing generator | txls | 01.01.00 | [link](/doc/txls.en.md) | [path](./source/05_parser) | TXLS file parsing generator | xml | 01.00.00 | [link](/doc/xml.en.md) | [path](./source/05_parser) | XML file parsing generator | yaml | 00.01.00 | [link](/doc/yaml.en.md) | [path](./source/05_parser) | YAML file parsing generator | ramt | 01.00.00 | [link](/doc/ramt.en.md) | [path](./source/06_performance) | RAM test module | romt | 01.00.00 | [link](/doc/romt.en.md) | [path](./source/06_performance) | ROM test module | cant | 00.01.00 | [link](/doc/cant.en.md) | [path](./source/06_performance) | CAN test module | slup | 00.01.00 | [link](/doc/slup.en.md) | [path](./source/06_performance) | serial link universal protocol | cpul | 01.00.00 | [link](/doc/cpul.en.md) | [path](./source/06_performance) | CPU load test module, including obtaining and increasing load | unitt | 01.00.00 | [link](/doc/unitt.en.md) | [path](./source/06_performance) | Simple unit test module | intl | 01.01.00 | [link](/doc/intl.en.md) | [path](./source/07_math) | Large integer arithmetic module | floatl | 01.01.01 | [link](/doc/floatl.en.md) | [path](./source/07_math) | Large floating-point arithmetic module | flmath | 01.00.00 | [link](/doc/flmath.en.md) | [path](./source/07_math) | Large floating-point arithmetic math module ## Usage The code is compiled and tested in a Linux environment. It can be compiled by configuring the files to be compiled in the `makefile` directory under the `build` directory, or by directly running the `run. sh` file to compile and run. The varch module should be kept as independent as possible, and in order to reduce dependence on other modules, most files can be directly extracted and used separately. If there are dependencies on other modules during compilation to solve dependency problems, but only data type dependencies, you can refer to defining the required types. ## Install * linux ``` make install ``` * MinGW ``` make install LIBP= ``` demo: ``` make install LIBP=D:/MinGW ``` ## License GNU GENERAL PUBLIC LICENSE Version 2, June 1991 ## Contach Lamdonn@163.com