gonzopi

git clone https://git.tarina.org/gonzopi
Log | Files | Refs | README | LICENSE

commit 226a38e704b9530716a19634c66af026494d60c3
parent 77ff9a0c1461939243c471382645f64978d2c8b7
Author: rbckman <rob@tarina.org>
Date:   Thu, 18 Jan 2024 09:42:59 +0000

Merge branch 'master' of https://git.tarina.org/gonzopi

Diffstat:
MREADME.md | 3+++
Mgonzopi.py | 19++++++++++---------
Msrv/gonzopiserver.py | 14+++++++-------
3 files changed, 20 insertions(+), 16 deletions(-)

diff --git a/README.md b/README.md @@ -1,6 +1,9 @@ Gonzo Pi ============= +Go Gonzo with the Ultimate Filmmaking Device! +How to build and use it here [https://github.com/rbckman/gonzopi_build](https://github.com/rbckman/gonzopi_build) +======= Turn a Raspberry Pi to the Ultimate Filmmaking Device! Demonstration of the device here [https://github.com/rbckman/gonzopi_build](https://github.com/rbckman/gonzopi_build) diff --git a/gonzopi.py b/gonzopi.py @@ -2386,15 +2386,16 @@ def getconfig(camera): config.write(f) time.sleep(0.02) - if filmfolder != '': - return version, camera_revision, filmfolder+'/' - else: - filmfolder = namesomething('Your film folder: ', home+'/Videos') - config['USER'] = {} - config['USER']['filmfolder'] = filmfolder - with open(configfile, 'w') as f: - config.write(f) - return camera_model, camera_revision, filmfolder+'/' + return version, camera_revision, home+'/gonzopifilms/' + #if filmfolder != '': + # return version, camera_revision, filmfolder+'/' + #else: + # filmfolder = namesomething('Your film folder: ', home+'/Videos') + # config['USER'] = {} + # config['USER']['filmfolder'] = filmfolder + # with open(configfile, 'w') as f: + # config.write(f) + # return camera_model, camera_revision, filmfolder+'/' #-------------Calc folder size with du----------- diff --git a/srv/gonzopiserver.py b/srv/gonzopiserver.py @@ -41,12 +41,12 @@ def usbfilmfolder(): break home = os.path.expanduser('~') -configfile = home + '/.gonzopi/config.ini' -configdir = os.path.dirname(configfile) -config = configparser.ConfigParser() -if config.read(configfile): - filmfolder = config['USER']['filmfolder']+'/' - +#configfile = home + '/.gonzopi/config.ini' +#configdir = os.path.dirname(configfile) +#config = configparser.ConfigParser() +#if config.read(configfile): +# filmfolder = config['USER']['filmfolder']+'/' +filmfolder = '/home/pi/gonzopifilms/' os.system("unlink static/*") #CHECK IF FILMING TO USB STORAGE @@ -58,7 +58,7 @@ if filmfolderusb: filmfolder='static/gonzopifilms/' else: os.system("ln -s -t static/ " + filmfolder) - filmfolder='static/Videos/' + filmfolder='static/gonzopifilms/' #fix filmfolder root to Videos/gonzopifilms basedir = os.path.dirname(os.path.realpath(__file__))