From 0641231c48fef338f8fe2c71920b70b3b90e5179 Mon Sep 17 00:00:00 2001 From: Hugh Barnard Date: Wed, 14 Dec 2022 17:17:25 +0000 Subject: [PATCH] picture preview --- db/memories.db | Bin 40960 -> 40960 bytes etc/mema.ini | 5 +++-- install.sh | 3 ++- take_picture.py | 3 ++- 4 files changed, 7 insertions(+), 4 deletions(-) diff --git a/db/memories.db b/db/memories.db index 391f116bbcd1c6f6b63d8459b221e806f039a569..cfda4791f6007fb809d2e6c8ebcf72545f8e0b68 100644 GIT binary patch delta 199 zcmZoTz|?SnX@WE(=R_H2M$U~1OY8;Mcn>h}FW`6Jd%)Mgr@(t)v!K8lUhX(HP6kU$ zUltBd@yUt)VnD1bYi?|Au9sDi&Xqii@oYgxeo1~DE2b(VLo*AAs+n)AA*xs~RT&x^ eSVC33l7gsW#!w|>Xk-jC>*Zyzs?84m2Lb?&OF9Su delta 38 ucmZoTz|?SnX@WE(>qHr6M%Il9OYAwA_#GJd7w|i578Eey-|XOjAOHZ^R0`k# diff --git a/etc/mema.ini b/etc/mema.ini index 6fd5146..bbe6a4a 100644 --- a/etc/mema.ini +++ b/etc/mema.ini @@ -23,6 +23,7 @@ use_external_ai = no #FIXME: now uses libcamera this is about the simplest set of options picture_command = libcamera-jpeg --nopreview -o +#picture command = DISPLAY=:0 libcamera-jpeg -o ## --- problematic video section --- ## # this doesn't do sound currently, need to recompile ffmpeg or move to cvlc? @@ -49,9 +50,9 @@ audio_maximum = 30 label_program = /home/pi/mema/label_video.py #FIXME: this is problematic, replace with jaro -xdg_open_command = handlr launch x-scheme-handler/http -- http://localhost:8000/memories.html +#xdg_open_command = handlr launch x-scheme-handler/http -- http://localhost:8000/memories.html #jaro_open_command = jaro http://localhost:8000/memories.html -#xdg_open_command = /home/hbarnard/projects/mema/browser.py +xdg_open_command = http://localhost:8000/memories.html #xdg_search_open = xdg-open https://google.com?q=mema keyword_slot_file = ~/.config/rhasspy/profiles/en/slots/keywords diff --git a/install.sh b/install.sh index 27ce6d8..b09b600 100755 --- a/install.sh +++ b/install.sh @@ -40,8 +40,9 @@ apt install ffmpeg apt install libcamera-apps apt install pulseaudio apt install vlc +apt install ntp # docker -sudo apt install docker.io +# no get_docker instead sudo apt install docker.io echo '*-------------------------------------------------------------------------------*' echo 'installing mema3' echo 'install python3 packages, make take a while' diff --git a/take_picture.py b/take_picture.py index 866a817..620365b 100755 --- a/take_picture.py +++ b/take_picture.py @@ -60,6 +60,7 @@ def main(): try: subprocess.call(picture_command_array, stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL) except subprocess.CalledProcessError as e: + logging.debug('taking picture error') raise RuntimeError("command '{}' return here with error (code {}): {}".format(e.cmd, e.returncode, e.output)) dots[0] = (0,255,0) # red else: @@ -81,7 +82,7 @@ def main(): else: mu.curl_speak(config['en_prompts']['done']) - + logging.debug('end of taking picture') dots.deinit() if pi else None print(result + "|" + media_path)