Search icon CANCEL
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Raspberry Pi Zero W Wireless Projects

You're reading from   Raspberry Pi Zero W Wireless Projects Go mobile with the world's most popular microprocessor

Arrow left icon
Product type Paperback
Published in Aug 2017
Publisher Packt
ISBN-13 9781788290524
Length 240 pages
Edition 1st Edition
Languages
Arrow right icon
Author (1):
Arrow left icon
Vasilis Tzivaras Vasilis Tzivaras
Author Profile Icon Vasilis Tzivaras
Vasilis Tzivaras
Arrow right icon
View More author details
Toc

Startup

At this point, your WeatherPi Station should be ready. There is one more thing to do here. We can set our Python script to start when the Raspberry Pi Zero W board is booting. To do this, we need to install a package named dos2unix that actually converts DOS style line endings into something that is Unix friendly. Apart from this, you can use crontab (install it if you don't have it) or edit your /etc/init.d/ to add some lines and make your script start with the other Raspberry Pi Zero W built-in services. To install the package mentioned previously, we have to run the following code:

sudo apt-get install dos2unix  

Next, we have to set up our Python script as a service, so we can start it at the Raspberry Pi Zero W boot. To do this, we will create a new script that will allow us to start/stop it and handle the Python script as we want. As always, open your favorite...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at €18.99/month. Cancel anytime