Dan911 wrote:IMO.... I think the plugin writer has to take all preventive measures to make sure your code regardless what user inputs doesn't make program crash. After that the user has to be held accountable for reading/following instruction, otherwise you can end up with pages of code.
Basically I agree, error checking and preventive control, data validation are important. But there is no way you or anyone else can cover every possible mistake which can be made. If the instructions are given and clear then it is up to the user to either follow them or ask for support, help or clarifications. But there must be instructions which explain as much as possible, clearly but not too wordy so that users can read them without losing patience. Many people read manuals and instructions, and those who don't, ...well, they learn the hard way.
Dan911 wrote:As far as Modbusez goes... Does it really matter if you instruct to input decimal or hex? With a search you can get dozens of converters with a click. Besides my goal here was...
"If you have this VFD input this".
In the case of the easy Modbus plugin, I think it is more complicated. For addresses it does not matter if they must be entered in decimal or hex format, as long as it is clear which one is expected and proper checks are made inside the plugin to validate the entered value. As you say, there are plenty converters freely available so if one manual states the addresses in decimal format it is easy to convert to hex. Regarding the commands it is not that simple any more because they are normally not stated as any other values than bit information and different bits in a word can have different meanings, and it is up to the users to interpret and convert those bits to a binary value which then of course easily can be converted to decimal or hex, whichever is needed. So, in my opinion, if it is supposed to be an easy interface than the commands should be entered in binary format because that is what the VFD manuals are using, but of course, that would make it more complicated for the programmer.
But then, what you (and I and many others) are doing is free labor for others who can't figure out all the bits and pieces needed for making it work, so at least some user effort should not be entirely unexpected. The main thing is that instructions are short, clear and easily understood.