Building Raspberry Pi Controllers with Python

Slides:



Advertisements
Similar presentations
QUICK QUIZ 28.1 You would like to construct an RC circuit with a time constant that is equal to 1 second (in other words, the current from the battery.
Advertisements

10/09/1999© 1999 CNRI, Guido van Rossum 1 Computer Programming for Everybody Guido van Rossum CNRI (Corporation for National Research Initiatives, Reston,
Unit 8 Combination Circuits
Lecture 5 Current/Voltage Measurement Resistance Measurement.
Response of First-Order Circuits
Circuits Series and Parallel. Series Circuits Example: A 6.00 Ω resistor and a 3.00 Ω resistor are connected in series with a 12.0 V battery. Determine.
Ohm’s Law V = IR.
By Alfredo Alvarez. Agenda: Find out who the instructor is. Talk about goals and why you want to learn python. Discuss the materials and the methodology.
Comprehension Check 1.You are given a 12V power supply with a light bulb with a resistance of 6.5Ω; what current flows in this circuit? 2.Using an ammeter,
CSC 110 A 1 CSC 110 Introduction to Python [Reading: chapter 1]
Startup – Chapter 1.
Series Circuits Circuits in which there is only one path for current to flow through All elements of the circuit (resistors, switches etc…) are in the.
Unit 6 Series Circuits.
Introduction to Electronics. Basic Electronics What is electricity? How is it measured? Terms Ohm’s Law Kirchhoff's Laws Power Putting it together Power.
Introduction to Circuits – Practical Resources.  Reading resistors ▪
A Falkirk High School presentation Ohm’s Law For each of the questions, click the letter of the correct answer Click to start the test.
Computer Science 111 Fundamentals of Programming I Overview of Programming.
COMP 171: Principles of Computer Science I John Barr.
 We are going to learn about programming in general…How to think logically and problem solve. The programming language we will use is Python. This is.
The First Pune Python meet organized by PythonThreads.com The First Pune Python meet organized by PythonThreads.com What is it? Python is a Free, Open.
Electronics Series Resistive Circuits 1 Copyright © Texas Education Agency, All rights reserved.
Parallel Circuits – Chapter 5
PARALLEL CIRCUITS HAVE MORE THAN ONE POSSIBLE PATHWAY FOR ELECTRONS.
The Math for Ohms Law along in DC Circuits
ITEC 109 Lecture 12 Higher level concerns. Higher concerns Review JES– What did you learn? Questions?
Python – May 11 Briefing Course overview Introduction to the language Lab.
Welcome to Phase III Understanding & Calculating Parallel Circuits This phase should only be opened if you are finished with Phase II.
Regents Physics Chapters 17/18 Circuits  Series Circuits.
Regents Physics Parallel Circuits –Ohm’s Law in Parallel Circuits.
Chapter 20 Circuits And Circuit Elements Schematic Diagrams and Circuits Objectives 1.Interpret and construct circuit diagrams 2. Identify circuits.
Ohm’s Law Resistance in Series Circuits
CHAPTER 6 SERIES CIRCUITS
Parallel Circuits. I _ + VR R I1I1 I2I2 I Parallel Circuit Rules A parallel circuit has two or more paths for current to flow through. Voltage is the.
Units to be measured and calculated VoltageVoltsV or E ResistanceOhmsR or Ω Current AmpsI or A.
#21. Find the following quantities R T = I T =V 30  = I 50  
The Series Circuit Summary 1. The sum of the _____________or voltage equals the potential rise of the source. 2. The current is ______________ everywhere.
5. Algorithm 1: Variables, Operators, Sequences 1.
IT IS THE HELP GUIDE FOR BEGINNERS WHO ARE CONFUSE THAT WHY THEY SHOULD CHOOSE PYTHON BY SOFTCRAYONS. Why Python Is Good carrier Choice.
CST 1101 Problem Solving Using Computers
Ohm’s Law.
Example The voltage between node A and B is 4V
IST256 : Applications Programming for Information Systems
DC Circuits.
Tools for Teaching Programming Aid Entry level programming course
Response of First-Order Circuits
Lesson 1 An Introduction
Python programming language
Electricity.
Building Raspberry Pi Controllers with Python
Chapter 20 Circuits And Circuit Elements.
Click here for the answer. Click here for the answer.
Introduction to Programmng in Python
Click here for the answer. Click here for the answer.
Click here for the answer. Click here for the answer.
Circuit Introduction Section 1:
Training on Real-time project With 100 % assistance support Training by IT professionals Trainers have 5+ years experience
Do you know this browser?...
Example 30k We want to calculate the voltage Vac. To solve this problem the circuit can be redrawn as.
What Is a Program? A program is like an algorithm, but describes a process that is ready or can be made ready to run on a real computer Retrieved from:
G10 Review… Simple circuit…
Comparing Series and Parallel Circuits
THE REAL WORLD APPLICATIONS OF PYTHON. INTRODUCTION Python is an interpreted, high-level, general-purpose programming language. Created by Guido van Rossum.
CS 1111 Introduction to Programming Spring 2019
Nodal and Mesh Analysis
Chapter 1: Programming Basics, Python History and Program Components
Fill in the gaps for the unknown Voltage and current readings
Parallel Circuits.
Example Example 1: An electric lamp is rated 110 W, 200 V. When the lamp is operated at its rated power and voltage, calculate a) the current flowing through.
Introduction to Computer Science
Presentation transcript:

Building Raspberry Pi Controllers with Python Class 2: Introduction to the Python Programming Language July 7, 2015 Don Wilcher

Introduction to the Python Programming Language Day 2 Agenda: Concepts of the Python Programming Language Review of the Python IDLE and shell sudo Python IDLE and shell Coding with Python using interpretive programming Building a simple calculator

Introduction to the Python Programming Language Learning Objectives: Learn about the Python Programming Language Learn about Python IDLE and shell Learn about sudo Python IDLE and shell Learn how to build simple Python calculators

Concepts of the Python Programming Language Python is: An object oriented language An interpretive programming language An easy to learn programming language A rapid prototyping tool for object models and algorithms A creative programming language for creating games and graphics

Concepts of the Python Programming Language… Who created Python? Guido Van Rossum (A Dutch Computer Programming) He created the language in 1986 He worked for Google from 2005 -2012 Started working for Dropbox in 2013

Python Question 1: What type of programming language is Python?

Concepts of the Python Programming Language… Why did Guido Van Rossum created Python? He was looking for a hobby programming language to keep him occupied during the Christmas season. He wanted code that is as understandable as plain English To teach programming in elementary and secondary schools (DARPA proposal: Computer Programming for Everyone

Python Question 2: Why did Guido Van Rossum created the Python programming language?

Review of Python IDLE and Shell How to gain access to the Python Shell !

Review of Python IDLE and Shell… The Python Shell allows you to test algorithms and code interactively!

Python Question 3 IDLE is the abbreviation for what Python development tool?

Review of Python IDLE and Shell… Help is just 2-clicks away!

Review of Python IDLE and Shell… Online Help: Python Documentation

vs What’s different between the two versions? Source: http://learntocodewith.me/programming/python/python-2-vs-python-3/

Python Question 4 What shell tool allows access to the Python Documentation?

Gaining access to sudo python

Gaining access to sudo python…

Interpretive Programming Example

Interpretive Programming: Let’s Build a Calculator Lets build a Python Application (Calculator) using interpretive programming to find the voltage drop across a dc motor! Problem: A dc motor’s resistance is equal to 4Ω. The current that flows through the resistor is 500mA. What is the voltage drop across the dc motor? Equation: Vmotor = Rmotor x Imotor

Interpretive Programming: Let’s Build a Calculator Here’s the DC Motor Circuit for the Python Calculator Analysis!

Interpretive Programming: Let’s Build a Calculator… Solution: Rmotor = 4Ω Imotor = 250mA Equation: Vmotor = Imotor x Rmotor Vmotor = 250mA x4Ω Vmotor = 1V

Interpretive Programming: Let’s Build a Calculator… Solution:

Interpretive Programming: Let’s Build a Calculator… The circuit analysis result value is less than the Python Calculator answer because of model component variations!

Python Question 5: Why is there a slight difference in Imotor values between the Python calculation and the Microcap circuit model?