Skip to content

embrio-tech/phone-guest-book

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Wedding Phone Service

Python embrio.tech

An app to record audio guest book entries with a retro phone.

IMG_5604

💾 Setup for Raspberry Pi as a Service

This section explains how to manage the wedding-phone.service using systemctl.

Clone the repository

Clone this repository to your Raspberry Pi. And setup a new service file.

sudo nano /etc/systemd/system/wedding-phone.service

Add the following content to the service file and make sure to change the ExecStart line to point to the location of run.py on your Pi.

[Unit]
Description=Run Python Script on Boot
After=network.target

[Service]
ExecStart=/usr/bin/python3 /home/wedding/Development/phone-guest-book/run.py
WorkingDirectory=/home/wedding/Development/gpio-test
StandardOutput=inherit
StandardError=inherit
Restart=always
User=wedding

[Install]
WantedBy=multi-user.target

Connect the GPIO pins

Connect the receiver pins to the GPIO pins as follows:

  • GPIO 4 --> Pull-down resistor (10kΩ) --> GND
  • GPIO 4 --> switch side 1
  • switch side 2 --> 3.3V

Use USB Sound Card

Use a USB Sound Card to connect the reciever microphone and speaker.

For example the Icy Box IB-AC527

Starting the Service

To start the wedding-phone service, use the following command:

sudo systemctl start wedding-phone.service

Stopping the Service

To stop the wedding-phone service, use the following command:

sudo systemctl stop wedding-phone.service

Checking the Service Status

To check the status of the wedding-phone service, use the following command:

sudo systemctl status wedding-phone.service

Enabling the Service on Boot

To enable the wedding-phone service to start automatically on boot, use the following command:

sudo systemctl enable wedding-phone.service

Disabling the Service on Boot

To disable the wedding-phone service from starting automatically on boot, use the following command:

sudo systemctl disable wedding-phone.service

Restarting the Service on run.py Change

If you need to make changes to the script, remember to restart the service:

sudo systemctl restart wedding-phone.service

Viewing Logs

To view the logs of the wedding-phone service, use the following command:

sudo journalctl -u wedding-phone.service

💬 Contact

EMBRIO.tech
hello@embrio.tech

🔏 License

The code is licensed under the MIT License

About

An app to record audio guest book entries with a retro phone and a raspberry pi.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages