Template:PT3 PYTHON SBC TRM: Difference between revisions
From Phidgets Support
																
																								|  (Created page with "<div class="phd-slide-deck" data-deck="PT3_PYTHON_SBC_TRM"> <div class="phd-slide-deck-header"><h3>Language - Python</h3></div> <div class="phd-slides"> <div class="phd-slide"...") | No edit summary | ||
| (One intermediate revision by the same user not shown) | |||
| Line 23: | Line 23: | ||
| </p> | </p> | ||
| <p>●  | <p>● Connection to local Network</p> | ||
| <p>● Administrator password</p> | <p>● Administrator password</p> | ||
| Line 36: | Line 36: | ||
| <div class="phd-slide"> | <div class="phd-slide"> | ||
| <h2> | <h2>Installing Python</h2> | ||
| <p> | |||
| The quickest way to install Python is through the SBC web interface. Open the Phidget Control Panel on your external machine and click on the | |||
| <b>Network Phidgets</b> tab. | |||
| </p> | |||
| <p> | <p>Double click on your SBC in the device list.</p> | ||
| <div class="phd- | <div class="phd-lazy-image" data-src="https://www.phidgets.com/decks/PT3_PYTHON_SBC_TRM/-x260/50/pysbc1.png"></div> | ||
| </div> | |||
| <div class="phd-slide"> | |||
| <h2>Installing Python</h2> | |||
| <p>Once you're logged in to the web interface, click on <b>System</b> and <b>Packages</b>.</p> | |||
| <div class="phd-lazy-image" data-src="https://www.phidgets.com/decks/PT3_PYTHON_SBC_TRM/-x127/50/pysbc2.png"></div> | |||
| <p>It may take a minute or two to load this page.</p> | |||
| </div> | |||
| <div class="phd-slide"> | |||
| <h2>Installing Python</h2> | |||
| <p>Finally, click on the <b>Install</b> button next to Python Support.</p> | |||
| <div class="phd-lazy-image" data-src="https://www.phidgets.com/decks/PT3_PYTHON_SBC_TRM/-x152/50/pysbc3.png"></div> | |||
| <p>It will take a few minutes to install. Once it's complete you can click on the <b>Back</b> button.</p> | |||
| </div> | </div> | ||
| Line 54: | Line 79: | ||
| <br /> | <br /> | ||
| <p> | <p>Since the <span>[https://www.phidgets.com/docs/OS_-_Phidget_SBC SBC OS Guide]</span> covers the web interface in detail, this guide will cover SSH.</p> | ||
| Since the <span>[https://www.phidgets.com/docs/ | |||
| cover SSH. | |||
| </p> | |||
| </div> | </div> | ||
| Line 138: | Line 160: | ||
| <div class="phd-command-line"><code>scp /path/to/source root@phidgetsbc.local:/path/to/destination</code></div> | <div class="phd-command-line"><code>scp /path/to/source root@phidgetsbc.local:/path/to/destination</code></div> | ||
| </div> | </div> | ||
| Line 201: | Line 188: | ||
| <h2>Setting up a New Project</h2> | <h2>Setting up a New Project</h2> | ||
| <p> | <p>When developing on an external computer, you should write and test your programs on that machine. When you are ready, upload your program to the SBC.</p> | ||
| When developing on an external computer, you  | |||
| to the SBC  | |||
| </p> | |||
| </div> | </div> | ||
| Line 248: | Line 232: | ||
| <p> | <p> | ||
| To run a Python script as a standalone application, you will need to add a line  | To run a Python script as a standalone application or to run it in the web interface, you will need to add a line to the top of the script with the path to your | ||
| executable. If you have followed the steps in this guide,  | Python executable. If you have followed the steps in this guide, it will be: | ||
| </p> | </p> | ||
| <div class="phd-command-line"><code>#!/usr/bin/ | <div class="phd-command-line"><code>#!/usr/bin/env python3</code></div> | ||
| <p>Click on the sections below for various automation options:</p> | <p>Click on the sections below for various automation options:</p> | ||

