Skip to content

ankushKun/clickoor

Repository files navigation

Clickoor Camera

Components

Hardware

Other common components such as microSD card, keyboard, mouse, hdmi display etc.

Software

Setup

Wifi (using `nmtui` if not already setup)
sudo nmtui

Has a nice ncurses interface to connect to wifi networks

Update and Upgrade always
sudo apt update
sudo apt upgrade
Pi HQ Camera

Connect the camera module to the camera port using the provided ribbon cable.

No specific setup is needed in case of pi 4b, the camera module should be detected automatically.

Touchscreen Display

No setup needed for the 4.3" Waveshare touchscreen display, it should be detected automatically.

If using a cheaper 3.5" display, follow these steps:

git clone https://github.com/goodtft/LCD-show
cd LCD-show
sudo ./LCD35-show

Display should start working after an automatic reboot

Install the touchscreen calibrator

cd LCD-show
sudo apt install ./xinput-calibrator_0.7.5-1_armhf.deb
xinput_calibrator
Python GUI (pygame)
cd clickoor
bash scripts/setup.sh
bash scripts/start.sh
i3

install i3wm

sudo apt install i3
sudo apt remove i3lock # we dont want lockscreen

Configure to boot into cli and autologin using raspi-config

run sudo raspi-config -> Boot Options -> Desktop / CLI -> Console Autologin

Configure to use i3 instead of lxde

open .bashrc and add this line at the end

startx /usr/bin/i3
Different method (Better way but doesnot always work, skill issue)
cd /etc/xdg/lxsession/LXDE-pi
  1. edit desktop.conf and set window_manager=i3 (located at first line)
  2. edit autostart and comment all lines about lxpanel, pcmanfm and xscreensaver because we dont want lxde stuff in i3

Add this to the end of your i3 config file (located at ~/.config/i3/config)

bindsym $mod+x exec "i3-msg exit"
bindsym $mod+c exec "bash /home/pi/clickoor/scripts/start.sh"
bindsym $mod+i exec "x-terminal-emulator -e nmtui"
exec_always --no-startup-id "bash /home/pi/clickoor/scripts/start.sh"

or copy the config file in configuration/config to ~/.config/i3/config

TODO:

  • Wifi connection in a different thread to stop main thread from blocking
  • Camera preview in a different thread for better performance?
  • Automated setup.sh script for configuring everything
  • Changable resolution
  • Video recording option
  • Exception handling wherever possible (starting with gallery image loading)
  • Options for creation of jwk for first time users
  • Turbo sdk integration (through ardrive-cli?)
  • Image compression under 500kb
  • Save each image as new timestamped file instead of overwriting
  • Gallery images view, incl. local and onchain images
  • Wallet options for change seed, upload jwk file (through a webserver)
  • Upload selected images from gallery to Arweave
  • Wifi connection from Wifi Screen
  • Pull latest code whenever there is an update