Skip to content

Adding auto-drive demo - #80

Merged
rhempel merged 1 commit into
ev3dev:masterfrom
ddemidov:demo
Nov 7, 2015
Merged

rhempel merged 1 commit into
ev3dev:masterfrom
ddemidov:demo

Conversation

@ddemidov

@ddemidov ddemidov commented Nov 7, 2015

Copy link
Copy Markdown
Member

Ref #47

@ddemidov

ddemidov commented Nov 7, 2015

Copy link
Copy Markdown
Member Author

The demo depends on #76.

rhempel added a commit that referenced this pull request Nov 7, 2015
@rhempel
rhempel merged commit ac18ae1 into ev3dev:master Nov 7, 2015
@ddemidov
ddemidov deleted the demo branch November 7, 2015 15:47
@rhempel

rhempel commented Nov 7, 2015

Copy link
Copy Markdown
Member

Thanks for adding this, what I'll do is post about it to the ev3dev.org site - there's not much going on there right now.

@ddemidov

ddemidov commented Nov 7, 2015

Copy link
Copy Markdown
Member Author

There is a slight issue I had with the new bindings while implementing this. The boostc version stopped the motors in their destructors, and pure python version does not. When something goes wrong in the middle of the script (that is, an exception is thrown and the script exits prematurely), motors keep rotating, and there is no easy way to stop the motors. May be we should reintroduce the boostc behavior?

@ensonic

ensonic commented Nov 7, 2015

Copy link
Copy Markdown
Contributor

+1 I'll do this on the code generated by open-roberta too.

@rhempel

rhempel commented Nov 7, 2015

Copy link
Copy Markdown
Member

Good idea - destructors should reset the peripheral - this may apply for sensors as well...

@ddemidov

ddemidov commented Nov 7, 2015

Copy link
Copy Markdown
Member Author

How do you reset a sensor?

@ddemidov ddemidov mentioned this pull request Nov 7, 2015
@ensonic

ensonic commented Nov 7, 2015

Copy link
Copy Markdown
Contributor

Maybe @rhempel meant to restore e.g. the mode.

@ddemidov

ddemidov commented Nov 7, 2015

Copy link
Copy Markdown
Member Author

But then we either need a concept of default mode for each sensor type, or to remember the state the sensor had at construction time.

@rhempel

rhempel commented Nov 7, 2015

Copy link
Copy Markdown
Member

I just mean to consider resetting the sensor. For example the NXT light sensor allowed to use the LED as a multi colored light. The destructor should turn the light off. I see the motor destructor PR is done - leave the sensors for later - it won't break anything :-)

@ddemidov ddemidov mentioned this pull request Nov 7, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants