Closed bmegli closed 10 years ago
I hadn't a chance to test the binding myself, but on a first view it looks pretty OK.
When do you plan to add the exception / connected
property stuff?
The only missing property that I see (and it isn't a big one) is the Device Index
sensor property, which is just the number at the end of the device's directory name. Everything else looks like it's there, although I haven't tested it on my brick.
@fdetro Next version, probably in two weeks time. I am busy at work. @WasabiFan Ooops, DeviceIndex coming in the same update.
For the Connected property - funny thing - this is not obvious in R. In basic R, objects can only by passed by value ;-) so chaniging the state of the object in the parent lexical scope (caller of the function) is tricky.
There are solutions for passing by reference ranging from dirty tricks, clever tricks and switching to the new reference class system R5 (yes, three separate systems of formal classes in core R now ;-)
I have to investigate and choose one of the solutions.
As for the exceptions: the script would simply stop execution with error message now. Its a matter of giving more informative error message.
For those reasons and the fact of targetting pre-release the pull request was made to branch develop (not master).
@fdetro Unless you see any other reasons not to, I'd say we can merge this. We can add an "experimental" tag to this one in the readme until those final few things are worked out.
Compatibility with ev3dev-jessie-2014-10-07 (pre-release).
Implementation follows wrapper-specification.md and naming conventions of cpp bindings and R language (e.g. Position for getter and SetPosition for setter, Run, Stop, Running for motor, ...).
What's working:
What was tested:
TO DO: