Linux Powered USB TableClock

by cyrixninja in Circuits > Clocks

975 Views, 6 Favorites, 0 Comments

Linux Powered USB TableClock

IMG_20200307_161747.jpg
IMG_20200307_161744.jpg
IMG_20200307_213346.jpg
IMG_20200307_213413.jpg
IMG_20200307_213338.jpg

Linux Power USB Table clock is Raspbian Lite Linux powered table clock. It is made to be used especially by night owls like me who want to see a quick time but it's too bright LCD to check the time on a mobile phone. Its look cool on my setup

Supplies

Raspberry Pi Zero W

Waveshare 3.5 inch Display

Micro-USB Cable

SD-Card

Format the SD Card and Burn It With Raspbian Lite Image

1.png
2.png

Format the SD Card so we can install fresh Raspbian in it

You can download Raspbian Lite Image from here -https://www.raspberrypi.org/downloads/raspbian/

You can also use Raspberry Pi Imager- https://downloads.raspberrypi.org/imager/imager.e...

Or Use Pre-Configured Clock OS-https://drive.google.com/file/d/1Hni6upFwmDCsuu1zF0F9jQucdxk_WYeU/view?usp=sharing

If using Pre-Configured Clock OS then directly connect all components and clock will work

Connect to Wifi-Headless

FU4P7XIK6JDVY3B.LARGE.jpg
FS2D44VK6JDVY6I.LARGE.jpg

1.Download the config files from the link given below

Link-https://github.com/Cyrixninja/Raspberry-pi-Headless

2.Edit it using notepad++ or vscode and add your wifi password and name

3.Power on the raspberry pi using Micro-USB cable

4. Raspberry pi will get connected to wifi

SSH Into Raspberry Pi

1.png

1.open your command prompt in Windows or terminal in Linux

2.type "ssh pi@Your_pi_ip"

Enter Following Commands

5.png
4.png
1.png

sudo apt-get update

sudo apt-get install git

sudo apt-get install ruby full

Install the Display Drivers

6.png
7.png

Enter the Following Commands-

git clone https://github.com/waveshare/LCD-show.git

cd LCD-show

chmod +x LCD35-show

./LCD35-show 180


After everything gets over the ssh will get disconnected and raspberry pi will restart

Download the Code

Enter the following commands

git clone https://github.com/Cyrixninja/term-clock

ruby ~/term-clock/term-clock.rb --download-conf

ruby ~/term-clock/term-clock.rb --download-characters

Configure the OS to Run Code on Startup

10.png
9.png
8.png
11.png
13.png

Enter following commands in raspberry pi-

1.sudo raspi-config

Then set the the boot to autologin to console

2.sudo nano /etc/profile

Then add the line -"sudo ruby ~/term-clock/term-clock.rb" and save it

Configure Screen Resolution

2.png
3.png
14.png

sudo raspi-config

Then set the resolution as 800x600 and save it

Time Configuration

1.png
2.png
3.png

The Default time of this clock is 0-GMT

You can change it according to your location

After the ssh click on terminal and press Ctrl+C

after that type "raspi-config" and follow the images to set time

after you have set the time finish and save the settings

Connect the Display and Power It Using Micro-USB Cable

IMG_20200307_162028.jpg
IMG_20200307_161947.jpg
IMG_20200307_162025.jpg
IMG_20200307_161923.jpg
IMG_20200307_161825.jpg
IMG_20200307_213429.jpg
IMG_20200307_213408.jpg

connect the display to raspberry pi zero and power it using micro-USB cable using your pc or laptop