Go to advanced search

by RogerW
Sat Oct 03, 2015 6:17 pm
Forum: C/C++
Topic: qtcreator on jessie
Replies: 18
Views: 15494

Re: qtcreator on jessie

fruitoftheloom wrote: TY :D
?
by RogerW
Sat Oct 03, 2015 3:56 pm
Forum: C/C++
Topic: qtcreator on jessie
Replies: 18
Views: 15494

Re: qtcreator on jessie

For anyone else trying to use QtCreator this got me going
viewtopic.php?t=99129&p=688095
Add "-noload Welcome" to the command line. I would still like to hear of a proper fix though.
by RogerW
Sat Oct 03, 2015 1:40 pm
Forum: C/C++
Topic: qtcreator on jessie
Replies: 18
Views: 15494

Re: qtcreator on jessie

Thanks for your help No, it will auto install dependencies when run sudo apt-get update sudo apt-get install qtcreator Done that - nothing installed. However I used synaptic to chack the packes installed against that list and three appear to be missing: qtbase-abi-5-3-2 qtdeclarative-abi-5-3-2 qtqui...
by RogerW
Sat Oct 03, 2015 1:15 pm
Forum: C/C++
Topic: qtcreator on jessie
Replies: 18
Views: 15494

Re: qtcreator on jessie

That seems to list 30 dependent packages - do I have to install them all one by one?
by RogerW
Sat Oct 03, 2015 12:42 pm
Forum: C/C++
Topic: qtcreator on jessie
Replies: 18
Views: 15494

Re: qtcreator on jessie

Yes I installed from the repository. As far as I can remember
sudo apt-get install qt5-default
This was probably a mistake as I thought it would give a basic installation.

Then
sudo apt-get install qtcreator
by RogerW
Sat Oct 03, 2015 11:09 am
Forum: C/C++
Topic: qtcreator on jessie
Replies: 18
Views: 15494

qtcreator on jessie

I am trying to install qtcreator on jessie. I get this when I try to run it from a command window. libEGL warning: DRI2: failed to authenticate No tool chain set from kit "Desktop". No tool chain set from kit "Desktop". Unable to find an X11 visual which matches EGL config 125 Could not initialize O...
by RogerW
Wed Sep 30, 2015 1:43 pm
Forum: Troubleshooting
Topic: Between symbol
Replies: 14
Views: 1573

Re: Between symbol

But probably not very good from a performance point of view ! PeterO True but not that bad import time as tm count = 1000 t1 = tm.perf_counter() while count: if(1 << count << 500): pass count -= 1 print(tm.perf_counter() - t1) count = 1000 t1 = tm.perf_counter() while count: if(count in range(1,500...
by RogerW
Wed Sep 30, 2015 12:38 pm
Forum: C/C++
Topic: A batch of questions about C# and geany
Replies: 8
Views: 1876

Re: A batch of questions about C.

1) In my view no. C# was invented by microsoft because Java was copyright. C# and C++ no doubt have similarities and other people might disagree with me. 2) I doubt it. C# may be written in C but as far as I know the syntax is not compatible. 3) Yes Geany probably does what it is claimed for. I have...
by RogerW
Wed Sep 30, 2015 10:41 am
Forum: Troubleshooting
Topic: Between symbol
Replies: 14
Views: 1573

Re: Between symbol

Perhaps more pythonesque:

Code: Select all

if x in range(lowerlimit, upperlimit):
by RogerW
Wed Sep 30, 2015 8:00 am
Forum: C/C++
Topic: const char *const *Args,
Replies: 4
Views: 1212

Re: const char *const *Args,

I think Args is a const pointer to a const pointer to char.
by RogerW
Tue Sep 29, 2015 4:32 pm
Forum: Python
Topic: os.getlogin() fails under Jessie
Replies: 5
Views: 975

Re: os.getlogin() fails under Jessie

Interesting but that is unix only. getlogin() works in Windows. What really puzzled me is why it works from a command line but not under X.
by RogerW
Tue Sep 29, 2015 4:17 pm
Forum: Python
Topic: os.getlogin() fails under Jessie
Replies: 5
Views: 975

Re: os.getlogin() fails under Jessie

Sorry but I don't know how to get a screenshot from the pi ont my PC. It works if I putty (SSH) into the pi.
Start idle (or idle3) and then
>>>import os
>>>os.getlogin()
by RogerW
Tue Sep 29, 2015 4:04 pm
Forum: Python
Topic: os.getlogin() fails under Jessie
Replies: 5
Views: 975

os.getlogin() fails under Jessie

I do not know if this should be in the Rasbian forum. If I start python from the command line os.getlogin() works. However if I run in the GUI (startx) it fails, even in a command window. The error says 'No such file or directory'.
by RogerW
Tue Sep 29, 2015 1:05 pm
Forum: Raspbian
Topic: STICKY: Jessie (now defunct and replaced with Stretch) Q&A
Replies: 396
Views: 213229

Re: Jessie Q&A

Just tried again and everything worked as normal. Ithink there must have been a hiccup on the server.
by RogerW
Tue Sep 29, 2015 1:00 pm
Forum: Troubleshooting
Topic: Raspbian Jessie zip appears corrupt
Replies: 71
Views: 30938

Re: Raspbian Jessie zip appears corrupt

Windows 10 reports the zip file as 1,301,744KB and the IMG file as 4224,000KB. I put it on an SD card and it seems to boot and run ok but I am having problems with apt-get which are probably unrelated.
How do you check the SHA-1?
by RogerW
Tue Sep 29, 2015 11:30 am
Forum: Raspbian
Topic: STICKY: Jessie (now defunct and replaced with Stretch) Q&A
Replies: 396
Views: 213229

Re: Jessie Q&A

I am getting errors from apt-get update and an attempt to install geany failed with a problem accessing 'mirrordirector.raspian.org'. Is this down to heavy traffic or something more fundamental? Was this during an upgrade to jessie or just during normal administration of the system? (if the latter ...
by RogerW
Tue Sep 29, 2015 11:13 am
Forum: Raspbian
Topic: STICKY: Jessie (now defunct and replaced with Stretch) Q&A
Replies: 396
Views: 213229

Re: Jessie Q&A

I am getting errors from apt-get update and an attempt to install geany failed with a problem accessing 'mirrordirector.raspian.org'. Is this down to heavy traffic or something more fundamental?
by RogerW
Mon Sep 28, 2015 3:47 pm
Forum: Python
Topic: [newbie] advice needed on code
Replies: 10
Views: 1930

Re: [newbie] advice needed on code

That code should run just as it is. The line: App().mainloop() creates an App object and then calls its mainloop function. It could have been written: myapp = App() myapp.mainloop() but I prefer not to introduce uneccessary variables. You have used different GPIO pins so you will need to change thes...
by RogerW
Sat Sep 26, 2015 3:57 pm
Forum: Python
Topic: threading
Replies: 17
Views: 5395

Re: threading

You need to be aware that on a pi2 threading will not make use of the 4 cores. Google "Global interpreter lock'. The manual suggests using the multiprocessing module instead.
by RogerW
Sat Sep 26, 2015 2:31 pm
Forum: Troubleshooting
Topic: GPIO cleanup
Replies: 4
Views: 554

Re: GPIO cleanup

BENSALVAGE wrote:Well it won't allow me to use the GPIO pins
Are you sure you are running with sudo priviledge?
by RogerW
Sat Sep 26, 2015 2:29 pm
Forum: Python
Topic: [newbie] advice needed on code
Replies: 10
Views: 1930

Re: [newbie] advice needed on code

You could try this. # led.py # written by Roger Woollett import RPi.GPIO as gp import Tkinter as tk # class for a non dimmable LED class Switch: def __init__(self,pin): # save the pin number self.pin = pin gp.setup(pin,gp.OUT) # initialise to off self.off() def on(self): gp.output(self.pin,gp.HIGH) ...
by RogerW
Fri Sep 25, 2015 9:07 am
Forum: General discussion
Topic: Why are some GPIO giving 3.3V at startup?
Replies: 8
Views: 1271

Re: Why are some GPIO giving 3.3V at startup?

GPIOs 0-8 default to inputs with a weak pull-up to 3V3 at power-on. The other GPIOs default to inputs with a weak pull-down to ground at power-on. Some GPIOs will be updated depending on what modules such as SPI you load during boot. I have no explanation for GPIO19. Interestingly this seems to var...
by RogerW
Thu Sep 24, 2015 3:16 pm
Forum: General discussion
Topic: Why are some GPIO giving 3.3V at startup?
Replies: 8
Views: 1271

Re: Why are some GPIO giving 3.3V at startup?

> No. The pull states are held in hardware latches, not registers, and the interface to them is write-only.

I had a feeling it might be something like that - thanks for the reply.
by RogerW
Thu Sep 24, 2015 3:05 pm
Forum: General discussion
Topic: Why are some GPIO giving 3.3V at startup?
Replies: 8
Views: 1271

Re: Why are some GPIO giving 3.3V at startup?

Hi, not quite what your asking, but in a round about way it does answer the question : https://www.raspberrypi.org/forums/viewtopic.php?f=91&t=120984&p=817560 Texy I don't think that answers my question. I have a python program (using pigpio) that monitors the state of the gpios. It can show the cu...
by RogerW
Thu Sep 24, 2015 2:23 pm
Forum: General discussion
Topic: Why are some GPIO giving 3.3V at startup?
Replies: 8
Views: 1271

Re: Why are some GPIO giving 3.3V at startup?

Slightly off topic but is there any way for a program to detect the state of the internal pullup/down resistors? I know I can set them.

Go to advanced search