Sign In Start Free Trial
Account

Add to playlist

Create a Playlist

Modal Close icon
You need to login to use this feature.
  • Book Overview & Buying Python Programming for Arduino
  • Table Of Contents Toc
  • Feedback & Rating feedback
Python Programming for Arduino

Python Programming for Arduino

By : Pratik Desai
4.6 (22)
close
close
Python Programming for Arduino

Python Programming for Arduino

4.6 (22)
By: Pratik Desai

Overview of this book

This is the book for you if you are a student, hobbyist, developer, or designer with little or no programming and hardware prototyping experience, and you want to develop IoT applications. If you are a software developer or a hardware designer and want to create connected devices applications, then this book will help you get started.
Table of Contents (13 chapters)
close
close
12
Index

Plotting real-time Arduino data


In the previous chapter, while dealing with GUI and Arduino data, you must have noticed that the code was updating the interface with every new value that was obtained from the Arduino sensors. Similarly, in this exercise, we will be redrawing the plot every time we receive new values from Arduino. Basically, we will be plotting and updating a real-time chart instead of plotting the entire set of sensor values as we did in the previous exercise.

We will be using the same Arduino circuit that you built in the previous exercises. Here, we will utilize only the potentiometer section of the circuit to obtain the analog sensor values. Now, before we explain the new methods used in this exercise, let's first open the program file for this exercise. You can find the program file from this chapter's folder; it is named plotLive.py. In the code, change the appropriate parameters for the Arduino board and execute the code. While the code is running, rotate the knob of...

Unlock full access

Continue reading for free

A Packt free trial gives you instant online access to our library of over 7000 practical eBooks and videos, constantly updated with the latest in tech

Create a Note

Modal Close icon
You need to login to use this feature.
notes
bookmark search playlist font-size

Change the font size

margin-width

Change margin width

day-mode

Change background colour

Close icon Search
Country selected

Close icon Your notes and bookmarks

Delete Bookmark

Modal Close icon
Are you sure you want to delete it?
Cancel
Yes, Delete

Delete Note

Modal Close icon
Are you sure you want to delete it?
Cancel
Yes, Delete

Edit Note

Modal Close icon
Write a note (max 255 characters)
Cancel
Update Note

Confirmation

Modal Close icon
claim successful

Buy this book with your credits?

Modal Close icon
Are you sure you want to buy this book with one of your credits?
Close
YES, BUY