Go to advanced search

by mmkw43
Tue Dec 08, 2020 8:15 pm
Forum: Python
Topic: WTF? -- Idle won't save, can't delete files -- WEIRD
Replies: 3
Views: 269

WTF? -- Idle won't save, can't delete files -- WEIRD

This is a first. I go to home/pi and actually delete a file(s) in File manager. (Pcmanfm) I close file manager and reopen it later and check to see if the files are deleted and they are. I reboot (or even shutdown completely and repower) and -- open file manager and the files are there ! Not only th...
by mmkw43
Tue Dec 08, 2020 5:30 pm
Forum: Python
Topic: 3.4 to 3.7 -- new shebang etc?
Replies: 2
Views: 261

3.4 to 3.7 -- new shebang etc?

If I have code that uses 3.4 in the shebang line or other references to 3.4 like in a subprocess call but I'm now using python3.7, do I have to change the wording from 3.4 to 3.7? !#/usr/bin/env python3.4 or subprocess.call("sudo python3.4 script.py") ok? I would guess it's alright but pay...
by mmkw43
Tue Dec 08, 2020 3:14 pm
Forum: General discussion
Topic: SD cards -- not enough space -- 8kb?
Replies: 7
Views: 382

Re: SD cards -- not enough space -- 8kb?

Ok thanks very much. I remember running into problems a few years back but it didn't register -- so I may try to do my original on an 8gb card and then make images on 16. And will definitely try that clone program. Thanks -- problem solved.
by mmkw43
Mon Dec 07, 2020 9:16 pm
Forum: General discussion
Topic: SD cards -- not enough space -- 8kb?
Replies: 7
Views: 382

SD cards -- not enough space -- 8kb?

I have a dozen Sandisk class 10 micro sd cards that I had written an image file to that were a python script running with Raspian Jessie. I've been spending way too much time trying to figure out how to make these all 100% empty and formatted just like the day I bought them. It's an embarrassingly b...
by mmkw43
Sun Dec 06, 2020 11:49 pm
Forum: Python
Topic: Python3.7 -- imagetk
Replies: 1
Views: 98

Re: Python3.7 -- imagetk

DISREGARD --- PROBLEM SOLVED. python3 image tk isn't installed with python 3.7
by mmkw43
Sun Dec 06, 2020 10:14 pm
Forum: Python
Topic: Python3.7 -- imagetk
Replies: 1
Views: 98

Python3.7 -- imagetk

My script runs fine in python 3.4. Thought I'd try it on the latest rpi os and get the error "can't import ImageTk from PIL". ? And -- should I even be attempting to run a script I wrote with 3.4 in 3.7.1 ? Are they backwards compatible or am I asking for trouble? Changed the shebag line t...
by mmkw43
Sun Dec 06, 2020 10:04 pm
Forum: Python
Topic: Event triggered by how long GPIO device is active.
Replies: 4
Views: 174

Re: Event triggered by how long GPIO device is active.

I use counters a lot rather than time.sleep

var = var + 1
makes it easy to "associate" the value with something and doesn't halt the program.
by mmkw43
Wed Dec 02, 2020 3:03 pm
Forum: Graphics programming
Topic: Tkinter -- widgets on topmost layer?
Replies: 6
Views: 574

Re: Tkinter -- widgets on topmost layer?

Scotty -- Why shouldn't place be used? I only used it because I need very specific locations for 15 labels (and other widgets) in this program. And thanks for the tip about update. Fact is, there were certain widgets that only wouldn't appear unless I used it -- so, perhaps I'm doing something wrong...
by mmkw43
Sat Nov 28, 2020 2:11 pm
Forum: General discussion
Topic: Recording Currently Playing Audio
Replies: 3
Views: 124

Re: Recording Currently Playing Audio

If you do any python, you could have a program identify the mp3 title then manipulate the gpio pins -- could even use multiple pins and decode the binary data for a ton of songs. -- or, if you don't want a specific light show for a song you could simply have the start of each song play a random ligh...
by mmkw43
Thu Nov 26, 2020 11:50 pm
Forum: General discussion
Topic: MPG123 -- first 1 or 2 seconds of audio cut off
Replies: 11
Views: 328

Re: MPG123 -- first 1 or 2 seconds of audio cut off

It's on my list to try them. Which is "leaner"? Do you know? That's what I like about mpg123.
Thanks.
by mmkw43
Thu Nov 26, 2020 7:21 pm
Forum: General discussion
Topic: MPG123 -- first 1 or 2 seconds of audio cut off
Replies: 11
Views: 328

Re: MPG123 -- first 1 or 2 seconds of audio cut off

I was hoping playing silence would do it but no luck, I can create a silence file at freetts -- even tried 4 seconds. Adding silence at beginning helps but sure would be nice if the problem were addressed by the brainicacs at it's very source. -- hint
major problem for me.
by mmkw43
Tue Nov 24, 2020 10:08 pm
Forum: General discussion
Topic: MPG123 -- first 1 or 2 seconds of audio cut off
Replies: 11
Views: 328

Re: MPG123 -- first 1 or 2 seconds of audio cut off

It's funny you should bring that up because I tried 2 seconds of silence and it worked well -- problem is I wasn't sure why, which always makes me uptight. Yeah I did the audio at freettss.com and you can add a pause if you want. The only problem with that is if I ask users to "add silence"...
by mmkw43
Tue Nov 24, 2020 9:40 pm
Forum: General discussion
Topic: MPG123 -- first 1 or 2 seconds of audio cut off
Replies: 11
Views: 328

Re: MPG123 -- first 1 or 2 seconds of audio cut off

Thanks. Yeah, this is a serious problem for what I want to do. At least you know I'm not imagining things. If anyone has ANY ideas on how to get around this it would be much appreciated. I have mpg123 in a script and yeah, the audio may not be called that often. Maybe I can just open it at regular i...
by mmkw43
Tue Nov 24, 2020 7:04 pm
Forum: General discussion
Topic: MPG123 -- first 1 or 2 seconds of audio cut off
Replies: 11
Views: 328

MPG123 -- first 1 or 2 seconds of audio cut off

Been spending days on this, so thought I'd throw this out there to see if anyone has experienced it. Using RPI 3 and Raspian (even tried this with latest OS and other Pi's. Even tried mpg321. And it's NOT the hdmi cable or TV avc control. Simplest way I can explain this is to do this -- reboot the P...
by mmkw43
Thu Nov 19, 2020 10:44 pm
Forum: General discussion
Topic: New RPI OS -- screen blanking --xscreensaver?
Replies: 3
Views: 181

Re: New RPI OS -- screen blanking --xscreensaver?

no wonder I didn't see it -- it was grayed out after I tried to install xscreensaver. uninstalled it and all is well.
by mmkw43
Thu Nov 19, 2020 9:44 pm
Forum: General discussion
Topic: New RPI OS -- screen blanking --xscreensaver?
Replies: 3
Views: 181

New RPI OS -- screen blanking --xscreensaver?

Installed the new OS after using Jessie forever. I can't believe there isn't a simple option somewhere to keep the screen from turning off (unless I'm missing it). I had to install xscreensaver before and then defeat it (weird) -- but on the new OS, xsceensaver won't install.
by mmkw43
Wed Nov 18, 2020 5:33 pm
Forum: Graphics programming
Topic: Tkinter -- widgets on topmost layer?
Replies: 6
Views: 574

Re: Tkinter -- widgets on topmost layer?

MY BAD.

I forgot to put place.update() after my new frame (with my help text) and it pops up fine. Not the first time I forgot that. Works great now.
by mmkw43
Wed Nov 18, 2020 5:00 pm
Forum: Graphics programming
Topic: Tkinter -- widgets on topmost layer?
Replies: 6
Views: 574

Re: Tkinter -- widgets on topmost layer?

I'm using PLACE throughout. Haven't looked into it yet but can frame "toplevel" or "raise" be of any value? Saw something regarding those used with frame. Can't provide an example because I don't know how to do it. Simply placing another label on my screen puts the label behind m...
by mmkw43
Tue Nov 17, 2020 8:32 pm
Forum: Graphics programming
Topic: Tkinter -- widgets on topmost layer?
Replies: 6
Views: 574

Tkinter -- widgets on topmost layer?

How do you create a widget (a label in my case) that supersedes anything behind it (another label)? I want to put up a help screen with a "close" button, so it will just be there temporarily but I have no empty space to put it in. Do I have to create a frame first? Or is there something I ...
by mmkw43
Mon Nov 16, 2020 9:08 pm
Forum: Python
Topic: Open Lxterminal window in script?
Replies: 4
Views: 153

Re: Open Lxterminal window in script?

SWEET ! Actually when you go through the process in raspi-config for localization and click finish, it closes the window. ! -- thanks much. actually, my mistake was not creating a list in subprocess -- my bad -- I've always just done one command. from now on, step 1 is to go back and READ the python...
by mmkw43
Mon Nov 16, 2020 8:59 pm
Forum: Python
Topic: Open Lxterminal window in script?
Replies: 4
Views: 153

Re: Open Lxterminal window in script?

Thanks, this works fine -- subprocess.run(["lxterminal","-e","sudo", "raspi-config"]) had to use "call" instead. and now like you say, how do I get rid of the window. which from what I just read, is pretty much impossible. anyway, thanks. amateur que...
by mmkw43
Mon Nov 16, 2020 7:14 pm
Forum: Python
Topic: Open Lxterminal window in script?
Replies: 4
Views: 153

Open Lxterminal window in script?

Friends -- Probably asking the impossible (I'm good at that) but is there any way to open the Lxterminal window in a script? I need to have it open to display raspi-config. Have tried all sorts of things with subprocess.call -- even tried root.bind for the ctl-alt-t keys etc etc. Perhaps I'm asking ...
by mmkw43
Mon Nov 16, 2020 4:36 pm
Forum: General discussion
Topic: US timezone expert -- timedatectl and PI
Replies: 13
Views: 1187

Re: US timezone expert -- timedatectl and PI

and thanks clever -- I'll delve into that as well. what I really wanted to do is bring up raspi-config in a python script using subprocess.call but can't get it done. keeps crashing.
by mmkw43
Mon Nov 16, 2020 4:34 pm
Forum: General discussion
Topic: US timezone expert -- timedatectl and PI
Replies: 13
Views: 1187

Re: US timezone expert -- timedatectl and PI

Yeah and I hate DST but let me ask, if I get the timezone choices right, the PI's clock will take care of the back and forth of DST?
by mmkw43
Mon Nov 16, 2020 4:32 pm
Forum: General discussion
Topic: US timezone expert -- timedatectl and PI
Replies: 13
Views: 1187

Re: US timezone expert -- timedatectl and PI

Ok thanks WH. I'll add Indianapolis and Phoenix to it and do some searching for a comprehensive "short list". It's for a python script and don't want to have a lot of choices in a pull down menu I want to do. I could just do an entry box and have them type it in to be on the safe side but ...

Go to advanced search