arduino / arduino/Arduino

[Documentation] ArduinoModbus Server, wrong return value for configure* functions

Open
#10,795 2 comments 0 reactions 1 assignee Claimed by @kengdahl View on GitHub
Component: Documentation Library: Other Type: Bug
Dominant language
Java
Stars
14.6k
Forks
7k
PR merge metrics
No merged PRs in 30d

Description

In documentation for ArduinoModbus library, all configure function for Server have wrong return value in documentation.
For example [https://www.arduino.cc/en/ArduinoModbus/ModbusServerconfigureDiscreteInputs](https://www.arduino.cc/en/ArduinoModbus/ModbusServerconfigureDiscreteInputs)
The function allocate memory for Moddus registers and coils.
```
Returns
0 on success, 1 on failure
```
Return should be ( according to source code )
-1 Invalid argument
0 on failure
1 on success

Same for all configure function

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.