Go to advanced search

by rjhazeld
Sat Jul 25, 2015 10:36 pm
Forum: Python
Topic: Getting result out of while loop
Replies: 7
Views: 1255

Re: Getting result out of while loop

Thanks, I had been hoping to have the 'current' view ahead available in 'real time' as it were so the forward/reverse slider output variable which is continuously refreshed would be revised to zero if the view ahead was 'blocked' and the speed variable is greater than zero. There will, if I can crac...
by rjhazeld
Sat Jul 25, 2015 9:02 pm
Forum: Python
Topic: Getting result out of while loop
Replies: 7
Views: 1255

Re: Getting result out of while loop

Thanks. Having taken the 'def...' out and added the 'breaks' in it does now pass the value back. The problem now is that I need some way of restarting the loop so that an obstacle is detected as it comes into range. The script doesn't give a continuous read of the GPIO pins as it did within the loop...
by rjhazeld
Sat Jul 25, 2015 4:42 pm
Forum: Python
Topic: Getting result out of while loop
Replies: 7
Views: 1255

Re: Getting result out of while loop

Sorry thought the attachment would suffice here is the code: #!/usr/bin/python2.7 import RPi.GPIO as GPIO, time, os GPIO.setmode(GPIO.BCM) GPIO.setup(20, GPIO.IN) GPIO.setup(21, GPIO.IN) IR_L = 21 #GPIO pin number left sensor IR_R = 20 #GPIO pin number right sensor var = 1 global ahead ahead = "" #p...
by rjhazeld
Sat Jul 25, 2015 2:57 pm
Forum: Python
Topic: Getting result out of while loop
Replies: 7
Views: 1255

Getting result out of while loop

I have built a cambot with a python control script and html front end that works fine. I have added a pair of infrared distance sensors with the aim of overriding the forward speed when an obstacle is in the way of cambot.. Seemed sensible to put the code in a separate module and import it into the ...
by rjhazeld
Wed Jun 17, 2015 9:09 pm
Forum: Raspbian
Topic: Pi user display settings messed up
Replies: 0
Views: 259

Pi user display settings messed up

After wrestling with a bad install and connecting to a different hdmi display startx opened but doesn't show the menu bar at the top and the trash bin and another icon below it flicker. If I use sudo startx display is normal. I created a new user and the display is normal too. I have looked at the v...
by rjhazeld
Sat Mar 28, 2015 6:38 pm
Forum: Automation, sensing and robotics
Topic: Cambot Web Control Issues
Replies: 0
Views: 513

Cambot Web Control Issues

I have converted an old RC Truck into a pi hearted vehicle with picam mounted on a pan and tilt unit. My Python script works fine with wired mouse and monitor and also via VNC over Wi-Fi on my home network. VNC is not an ideal route to control the device so I have set about trying to build a web bas...
by rjhazeld
Wed Mar 04, 2015 2:21 pm
Forum: Automation, sensing and robotics
Topic: Can tkinter gui be embedded in an html page ?
Replies: 5
Views: 4310

Re: Can tkinter gui be embedded in an html page ?

That's great, thank you. Hopefully I can work out the necessary code from the examples....more midnight oil to be burned!!
by rjhazeld
Wed Mar 04, 2015 9:46 am
Forum: Automation, sensing and robotics
Topic: Can tkinter gui be embedded in an html page ?
Replies: 5
Views: 4310

Re: Can tkinter gui be embedded in an html page ?

Thanks for the reply and the link which looks really helpful.
Currently the motors are controlled by sliders can they be replicated in html?
by rjhazeld
Tue Mar 03, 2015 9:01 pm
Forum: Automation, sensing and robotics
Topic: Can tkinter gui be embedded in an html page ?
Replies: 5
Views: 4310

Can tkinter gui be embedded in an html page ?

I'm new to coding and Rpi so forgive me if this is a stupid question or in the wrong place. I have just succeeded in getting a Rpi cambot, based on an old rc truck, working via a python script which generates a tkinter GUI. I can control the 4 motors on i2c and have several buttons to start and stop...
by rjhazeld
Tue Feb 24, 2015 11:12 am
Forum: Automation, sensing and robotics
Topic: Servos on I2C at start up
Replies: 3
Views: 829

Re: Servos on I2C at start up

Thanks for the suggestion. As the wiring is a little cobbled together at the moment I was able to try rebooting without the servo board powered up sadly as soon as I added power to the servo board the servos moved so this doesn't seem to be a solution.
by rjhazeld
Tue Feb 24, 2015 10:43 am
Forum: Automation, sensing and robotics
Topic: Servos on I2C at start up
Replies: 3
Views: 829

Servos on I2C at start up

I am new to Rpi etc. I am converting an old large Rc car to a cambot. I have finally got the servos of a pan and tilt system working and was near to getting the steering set correctly. However, when I rebooted the Rpi the servos move to the motors default start rather than staying where they were la...
by rjhazeld
Tue Feb 24, 2015 9:43 am
Forum: HATs and other add-ons
Topic: Battery RPi2+Servo hat & Picoborg reverse
Replies: 1
Views: 699

Re: Battery RPi2+Servo hat & Picoborg reverse

For anyone facing the same problem the Adafruit Servo Hat does not back feed 5v to the Rpi. I solved my problem by using a 2nd Battborg to provide a 5v supply to the Servo Hat. Otherwise circuit is as shown in the diagram.

Now to crack controlling the servos!!
by rjhazeld
Mon Feb 16, 2015 9:51 am
Forum: HATs and other add-ons
Topic: Battery RPi2+Servo hat & Picoborg reverse
Replies: 1
Views: 699

Battery RPi2+Servo hat & Picoborg reverse

Just got my first Rpi and I am converting an old RC truck to a Cambot with it. To control the drive motors I hav a Picoborg reverse and a Battborg to take power from a 9.6v battery pack and deliver the required 5v to the Rpi. I also need to control several servos - pan & tilt etc. for this I got an ...

Go to advanced search