<commit_before># lightmodbus 3lightmodbus "25 March 2017" "v1.3"

## NAME
**lightmodbus** - a lightweight, cross-platform Modbus RTU library.

## DESCRIPTION
The **lightmodbus** library allows communication with use of the Modbus RTU protocol. **lightmodbus** contains functions for parsing and creating Modbus frames, but **it is not** capable of sending or receiving them. Modbus functions supported by library include: 01, 02, 03, 04, 05, 06, 15, 16 and 22.
Library itself, is easy to compile and modular - only necessary modules can be included while building. Default version available for PC is complete and it contains all modules by default. Needless to say, the library is possible to build at any little-endian platform.

## BUILDING
There are three makefiles attached to the library.
Usual `makefile` simply compiles source code, creating object files (`obj` directory), as well as static library files in `lib` directory. Modules to be linked into the library can be specified by `MMODULES` and `SMODULES` variables passed to make from command line. Depending on their value, makefile compiles and links modules. Default settings are:

`   
	MMODULES = master-registers master-coils
	SMODULES = slave-registers slave-coils
`

Example make call would be: `make MMODULES="master-reisters" SMODULES=""` which would affect in having only master side register operations module compiled.

`makefile-coverage` builds library all on its own for coverage testing purposes (you probably don't need that, go on).

## AVR
`makefile-avr` works exactly as normal `makefile`, but instead it uses `avr-gcc` compiler to build the library. Additionally, it requires MCU type to be specified by `MCU` variable passed from command line.

## ROUTINES
Full listing of routines included in `lightmodbus` library available for user.

| Routine name                  | Module name            		 	            |
|-------------------------------|-----------------------------------------------|
| **modbusCRC**                 |  core                   						|
| **modbusSwapEndian**          |  core           								|
| **modbusMaskRead**            |  core               							|
| **modbusMaskWrite**           |  core              							|
| **modbusMasterInit**       	|  master-base          						|
| **modbusMasterEnd**       	|  master-base          						|
| **modbusParseResponse**       |  master-base          						|
| **modbusParseException**      |  master-base         							|
| **modbusSlaveInit**      		|  slave-base     		    					|
| **modbusSlaveEnd**     		|  slave-base     		    					|
| **modbusBuildException**      |  slave-base         							|
| **modbusParseRequest**   	   	|  slave-base         							|
| **modbusBuildRequest0102**   	|  master-coils         						|
| **modbusBuildRequest0304**   	|  master-registers         					|
| **modbusBuildRequest05**   	|  master-coils         						|
| **modbusParseRequest06**   	|  master-registers         					|
| **modbusBuildRequest15**   	|  master-coils         						|
| **modbusBuildRequest16**   	|  master-registers         					|
| **modbusBuildRequest22**   	|  master-registers         					|


| Routine name                  | Manpage                  		 	            |
|-------------------------------|-----------------------------------------------|
| **modbusCRC**                 |  modbusCRC(3lightmodbus)                      |
| **modbusSwapEndian**          |  modbusSwapEndian(3lightmodbus)               |
| **modbusMaskRead**            |  modbusMaskRead(3lightmodbus)                 |
| **modbusMaskWrite**           |  modbusMaskWrite(3lightmodbus)                |
| **modbusMasterInit**       	|  modbusMasterInit(3lightmodbus)            	|
| **modbusMasterEnd**       	|  modbusMasterEnd(3lightmodbus)            	|
| **modbusParseResponse**       |  modbusParseResponse(3lightmodbus)            |
| **modbusParseException**      |  modbusParseException(3lightmodbus)           |
| **modbusSlaveInit**      		|  modbusSlaveInit(3lightmodbus)     		    |
| **modbusSlaveEnd**     		|  modbusSlaveEnd(3lightmodbus)     		    |
| **modbusBuildException**      |  modbusBuildException(3lightmodbus)           |
| **modbusParseRequest**   	   	|  modbusParseRequest(3lightmodbus)         	|
| **modbusBuildRequest0102**   	|  modbusBuildRequest(3lightmodbus)         	|
| **modbusBuildRequest0304**   	|  modbusBuildRequest(3lightmodbus)         	|
| **modbusBuildRequest05**   	|  modbusBuildRequest(3lightmodbus)         	|
| **modbusBuildRequest06**   	|  modbusBuildRequest(3lightmodbus)         	|
| **modbusBuildRequest15**   	|  modbusBuildRequest(3lightmodbus)         	|
| **modbusBuildRequest16**   	|  modbusBuildRequest(3lightmodbus)         	|
| **modbusBuildRequest22**   	|  modbusBuildRequest(3lightmodbus)         	|
<commit_msg>Nah, I really broke it now..<commit_after># lightmodbus 3lightmodbus "25 March 2017" "v1.3"

## NAME
**lightmodbus** - a lightweight, cross-platform Modbus RTU library.

## DESCRIPTION
The **lightmodbus** library allows communication with use of the Modbus RTU protocol. **lightmodbus** contains functions for parsing and creating Modbus frames, but **it is not** capable of sending or receiving them. Modbus functions supported by library include: 01, 02, 03, 04, 05, 06, 15, 16 and 22.
Library itself, is easy to compile and modular - only necessary modules can be included while building. Default version available for PC is complete and it contains all modules by default. Needless to say, the library is possible to build at any little-endian platform.

## BUILDING
There are three makefiles attached to the library.
Usual `makefile` simply compiles source code, creating object files (`obj` directory), as well as static library files in `lib` directory. Modules to be linked into the library can be specified by `MMODULES` and `SMODULES` variables passed to make from command line. Depending on their value, makefile compiles and links modules. Default settings are:

`   
	MMODULES = master-registers master-coils
	SMODULES = slave-registers slave-coils
`

Example make call would be: `make MMODULES="master-reisters" SMODULES=""` which would affect in having only master side register operations module compiled.

`makefile-coverage` builds library all on its own for coverage testing purposes (you probably don't need that, go on).

## AVR
`makefile-avr` works exactly as normal `makefile`, but instead it uses `avr-gcc` compiler to build the library. Additionally, it requires MCU type to be specified by `MCU` variable passed from command line.

## ROUTINES
Full listing of routines included in `lightmodbus` library available for user.

| Routine name                  | Module name            		 	            |
|-------------------------------|-----------------------------------------------|
| **modbusCRC**                 |  core                   						|
| **modbusSwapEndian**          |  core           								|
| **modbusMaskRead**            |  core               							|
| **modbusMaskWrite**           |  core              							|
| **modbusMasterInit**       	|  master-base          						|
| **modbusMasterEnd**       	|  master-base          						|
| **modbusParseResponse**       |  master-base          						|
| **modbusParseException**      |  master-base         							|
| **modbusSlaveInit**      		|  slave-base     		    					|
| **modbusSlaveEnd**     		|  slave-base     		    					|
| **modbusBuildException**      |  slave-base         							|
| **modbusParseRequest**   	   	|  slave-base         							|
| **modbusBuildRequest0102**   	|  master-coils         						|
| **modbusBuildRequest0304**   	|  master-registers         					|
| **modbusBuildRequest05**   	|  master-coils         						|
| **modbusParseRequest06**   	|  master-registers         					|
| **modbusBuildRequest15**   	|  master-coils         						|
| **modbusBuildRequest16**   	|  master-registers         					|
| **modbusBuildRequest22**   	|  master-registers         					|


| Routine name                  | Manpage                  		 	            |
|-------------------------------|-----------------------------------------------|
| **modbusCRC**                 |  modbusCRC( 3lightmodbus )                    |
| **modbusSwapEndian**          |  modbusSwapEndian( 3lightmodbus )             |
| **modbusMaskRead**            |  modbusMaskRead( 3lightmodbus )               |
| **modbusMaskWrite**           |  modbusMaskWrite( 3lightmodbus )              |
| **modbusMasterInit**       	|  modbusMasterInit( 3lightmodbus )          	|
| **modbusMasterEnd**       	|  modbusMasterEnd( 3lightmodbus )          	|
| **modbusParseResponse**       |  modbusParseResponse( 3lightmodbus )          |
| **modbusParseException**      |  modbusParseException( 3lightmodbus )         |
| **modbusSlaveInit**      		|  modbusSlaveInit( 3lightmodbus )     		    |
| **modbusSlaveEnd**     		|  modbusSlaveEnd( 3lightmodbus )     		    |
| **modbusBuildException**      |  modbusBuildException( 3lightmodbus )         |
| **modbusParseRequest**   	   	|  modbusParseRequest( 3lightmodbus )         	|
| **modbusBuildRequest0102**   	|  modbusBuildRequest( 3lightmodbus )         	|
| **modbusBuildRequest0304**   	|  modbusBuildRequest( 3lightmodbus )         	|
| **modbusBuildRequest05**   	|  modbusBuildRequest( 3lightmodbus )         	|
| **modbusBuildRequest06**   	|  modbusBuildRequest( 3lightmodbus )         	|
| **modbusBuildRequest15**   	|  modbusBuildRequest( 3lightmodbus )         	|
| **modbusBuildRequest16**   	|  modbusBuildRequest( 3lightmodbus )         	|
| **modbusBuildRequest22**   	|  modbusBuildRequest( 3lightmodbus )         	|

{'fraction_non_alphanumeric': 0.1255785251465597, 'fraction_numerical': 0.016867222050807363, 'mean_word_length': 2.0811153358681875, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 3, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1532279', 'n_tokens_mistral': 3055, 'n_tokens_neox': 2738, 'n_words': 702}