View Full Version : confusing function names- ....Pin...('pin',...
korda
05-28-2008, 01:07 PM
There are set of functions to work with GPIO with misleading name and parameter:
setPinDir, setPinPullup, setPinSlew, monitorPin, pulsePin, readPin, writePin
By the name of these functions and the parameter ('pin') you assume you are working with a pin number, but in fact it is GPIO number.
And guess what - they are not the same! Very inconvenient.
kbanks
05-28-2008, 07:07 PM
The mapping of generic "GPIO" pins to "physical pins" is shown on the RFE data sheet.
I suppose we could have named the functions like:
setGPIOdir()
readGPI()
writeGPO()
pulseGPO()
etc.
We just thought "pin" was a generic enough term.
If we had made the pin numbers match, then people could also be confused by "pins" 1, 21, 22, 23, and 24 (GND, VCC, Reserved, RESET_L, and GND), since these pins are neither definable or programmable.
korda
05-28-2008, 08:55 PM
This can be easy fixed by better function description. Right now PDF manual simply states 'pin' - this is where confusion is located.
I would prefer the three pages with function names listed be expanded with very detailed function details, and may be some examples. Most confusing for a beginner in PY the function parameters. For example ...NvParameter functions parameters are still foggy, even after your explanations on forum.
kbanks
06-03-2008, 09:25 AM
We will be expanding our documentation for the upcoming 2.1 release. Thanks for the feedback, it tells us what areas to concentrate on.
vBulletin® v3.8.0, Copyright ©2000-2012, Jelsoft Enterprises Ltd.