ycliper

Популярное

Музыка Кино и Анимация Автомобили Животные Спорт Путешествия Игры Юмор

Интересные видео

2025 Сериалы Трейлеры Новости Как сделать Видеоуроки Diy своими руками

Топ запросов

смотреть а4 schoolboy runaway турецкий сериал смотреть мультфильмы эдисон
Скачать

Raspberry Pi 3 GPIO Project For Beginners Part 2

Raspberry Pi 3 GPIO Project For Beginners Part 2

Raspberry Pi

Raspberry Pi Projects

Автор: Smart Spate

Загружено: 2017-08-29

Просмотров: 542

Описание: In this Part 2 video tutorial, we continue to show you how to use GPIO Connectors to light up some LED and make some kind of LED Stop light. This type of project requires more than a basic knowledge of Python and Linux but we will try to explain so that even beginners could understand it.

What you will need for this Project:

1) Raspberry Pi 3 B+ Model - https://www.google.ca/aclk?sa=L&ai=DC...
2) Ribbon Cable for Raspberry Pi - https://www.amazon.ca/s/?ie=UTF8&keyw...
3) T-Cobbler Plus GPIO Breakout GPIO - https://www.google.ca/url?sa=t&rct=j&...
4) Full-Size BreadBoard ( Would be the best for this project) - https://www.google.ca/url?sa=t&rct=j&...
5) A few of Male Connection Wire Jumpers - https://www.google.ca/url?sa=t&rct=j&...
6) A few of LED 5mm Light Bulb (Any color, but in our case, we will be using the red one) -https://www.google.ca/aclk?sa=L&ai=DC...
7) Resistors 100 Ohm or higher ( Minimum 60 Ohm so that your Bulb is not fried up ) - https://www.google.ca/aclk?sa=L&ai=DC...
8) Power Adapter for your Raspberry Pi - https://www.google.ca/aclk?sa=L&ai=DC...
9) Ethernet Cable CAT 5e, 6 if you don't want to use Wireless Connection - https://www.google.ca/aclk?sa=L&ai=DC...

In case if you don't know how to connect to your Raspberry Pi and use a Putty Software which allows you connect remotely then you have to have all of the listed below to make it work:
1) Monitor;
2) HDMI Cable;
3) Keyboard;
4) Mouse;

Script:

Here are the stop light commands...
import time
GPIO.setup(17, GPIO.OUT)
GPIO.setup(22, GPIO.OUT)
while True :
GPIO.output(22, True)
time.sleep(5)
GPIO.output(22, False)
GPIO.output(17, True)
time.sleep(2)
GPIO.output(17, False)
GPIO.output(4, True)
time.sleep(5)
GPIO.output(4, False)
CTRL-C to stop the while loop

Here is what should be in the rapidlink.py file...
import RPi.GPIO as GPIO
GPIO.setwarnings(False)
GPIO.setmode(GPIO.BCM)
GPIO.setup(4, GPIO.OUT)
GPIO.setup(17, GPIO.OUT)
GPIO.setup(22, GPIO.OUT)
import time
while True :
GPIO.output(4, True)
time.sleep(.1)
GPIO.output(4, False)
GPIO.output(17, True)
time.sleep(.1)
GPIO.output(17, False)
GPIO.output(22, True)
time.sleep(.1)
GPIO.output(22, False)
GPIO.output(17, True)
time.sleep(.1)
GPIO.output(17, False)
CTRL-C to stop the script

Here is what should be in the ledoff.py file...
import RPi.GPIO as GPIO
GPIO.setwarnings(False)
GPIO.setmode(GPIO.BCM)
GPIO.setup(4, GPIO.OUT)
GPIO.setup(17, GPIO.OUT)
GPIO.setup(22, GPIO.OUT)
GPIO.output(4, False)
GPIO.output(17, False)
GPIO.output(22, False)

Music by:

Eternal Hope by Kevin MacLeod is licensed under a Creative Commons Attribution License (https://creativecommons.org/licenses/...)
Source: http://incompetech.com/music/royalty-...
Artist: http://incompetech.com/

You can Fins Us at:

Our Official Web Page: http://www.smartspate.com
Our Twitter Page:   / smartspate  
Our Facebook Page:   / itblogforum  
Our Facebook IT Group:   / 15062  

Не удается загрузить Youtube-плеер. Проверьте блокировку Youtube в вашей сети.
Повторяем попытку...
Raspberry Pi 3 GPIO Project For Beginners Part 2

Поделиться в:

Доступные форматы для скачивания:

Скачать видео

  • Информация по загрузке:

Скачать аудио

Похожие видео

How to use a multimeter like a pro! The Ultimate guide

How to use a multimeter like a pro! The Ultimate guide

Step by Step Guide How To Install Python 3 and Set Up a Local Programming Environment on Windows 10

Step by Step Guide How To Install Python 3 and Set Up a Local Programming Environment on Windows 10

5V Regulator design tutorial - How it works, how to design PCB  altium

5V Regulator design tutorial - How it works, how to design PCB altium

ОСЕЧКИН:

ОСЕЧКИН: "А вот это очень интересная история": зачем спецборт РФ летит в США, трибунал для Путина

Украина сожгла пять систем С-400 в Крыму. Работали супер-дроны

Украина сожгла пять систем С-400 в Крыму. Работали супер-дроны

How LED Works - Unravel the Mysteries of How LEDs Work!

How LED Works - Unravel the Mysteries of How LEDs Work!

Максимальное унижение Зеленского

Максимальное унижение Зеленского

Stepper Motors and Arduino - The Ultimate Guide

Stepper Motors and Arduino - The Ultimate Guide

СЛИТЫЕ ДОКЛАДЫ ФСБ: КИТАЙ ВЕДЕТ КИБЕРВОЙНУ ПРОТИВ РОССИИ. И присматривается к Дальнему Востоку

СЛИТЫЕ ДОКЛАДЫ ФСБ: КИТАЙ ВЕДЕТ КИБЕРВОЙНУ ПРОТИВ РОССИИ. И присматривается к Дальнему Востоку

КОГДА ИСЧЕЗНЕТ УКРАИНА? | #ВзглядПанченко

КОГДА ИСЧЕЗНЕТ УКРАИНА? | #ВзглядПанченко

© 2025 ycliper. Все права защищены.



  • Контакты
  • О нас
  • Политика конфиденциальности



Контакты для правообладателей: [email protected]