Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #98313
| From | input/ldompeling@casema.nl |
|---|---|
| Newsgroups | comp.lang.python |
| Subject | Re: raw_input and break |
| References | <mailman.58.1446743214.16136.python-list@python.org> |
| Message-ID | <8lM_x.24516$cf7.4240@fx02.am1> (permalink) |
| Organization | Pure Usenet - Usenet for everyone |
| Date | 2015-11-05 17:28 +0000 |
Oke, lets try your code.Can you help me with that.
This is my code:
-------------------------------------------------
from gopigo import *
import time
set_right_speed(150)
set_left_speed(105)
enable_servo()
fwd()
print("forward 1x")
time.sleep(4)
stop()
while True:
servo(90)
mindist = 80
if mindist > us_dist(15):
bwd()
print ("backward 1x")
time.sleep(2)
stop()
right()
time.sleep(1)
stop()
print("right 1x")
time.sleep(2)
stop()
fwd()
print("forward 2x")
time.sleep(3)
stop()
left()
time.sleep(1)
print("left 1x")
stop()
fwd()
print("forward 3x")
time.sleep(2)
stop()
------------------------------------------------------
In reply to "Peter Otten" who wrote the following:
> input/ldompeling@casema.nl wrote:
>
> > > The code in capture_key.py may look a bit scary, but just as I took it
> > > without bothering the details you can take the resulting module without
> > > caring about the code in it. Alternatively you can search
> >
> > > https://pypi.python.org
> >
> > Thanks for the link. I realy appreciate it.
> > Can you also tell me what I am looking for in https://pypi.python.org for
> > a result.
>
> I didn't have a particular module in mind. Pypy, or the "Python Package
> Index", is a repository for all kinds of modules and libraries. If you don't
> yet feel comfortable looking around (peferrably using the search engine of
> your choice) and experimenting a bit I recommend that you try the piece of
> code I posted (or wait for someone else to chime in with a better
> suggestion).
--
--------------------------------- --- -- -
Posted with NewsLeecher v7.0 Beta 2
Web @ http://www.newsleecher.com/?usenet
------------------- ----- ---- -- -
Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
raw_input and break input/ldompeling@casema.nl - 2015-11-04 21:44 +0000
Re: raw_input and break Ian Kelly <ian.g.kelly@gmail.com> - 2015-11-04 14:54 -0700
Re: raw_input and break Joel Goldstick <joel.goldstick@gmail.com> - 2015-11-04 16:56 -0500
Re: raw_input and break input/ldompeling@casema.nl - 2015-11-04 22:37 +0000
Re: raw_input and break Steven D'Aprano <steve@pearwood.info> - 2015-11-05 11:44 +1100
Re: raw_input and break tian.su.yale@gmail.com - 2015-11-04 21:39 -0800
Re: raw_input and break input/ldompeling@casema.nl - 2015-11-05 09:22 +0000
Re: raw_input and break Peter Otten <__peter__@web.de> - 2015-11-05 11:01 +0100
Re: raw_input and break input/ldompeling@casema.nl - 2015-11-05 10:40 +0000
Re: raw_input and break Peter Otten <__peter__@web.de> - 2015-11-05 12:38 +0100
Re: raw_input and break input/ldompeling@casema.nl - 2015-11-05 12:59 +0000
Re: raw_input and break Peter Otten <__peter__@web.de> - 2015-11-05 15:16 +0100
Re: raw_input and break input/ldompeling@casema.nl - 2015-11-05 14:34 +0000
Re: raw_input and break Peter Otten <__peter__@web.de> - 2015-11-05 18:06 +0100
Re: raw_input and break input/ldompeling@casema.nl - 2015-11-05 17:28 +0000
Re: raw_input and break Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2015-11-05 20:09 -0500
Re: raw_input and break input/ldompeling@casema.nl - 2015-11-06 05:08 +0000
Re: raw_input and break input/ldompeling@casema.nl - 2015-11-06 11:50 +0000
Re: raw_input and break Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2015-11-06 08:25 -0500
csiph-web