- Learning BeagleBone Python Programming
- Alexander Hiam
- 454字
- 2021-07-16 13:37:33
Connecting to your BeagleBone
If you're running your BeagleBone with a monitor, keyboard, and mouse connected, you can use it like a standard desktop install of Debian. This book assumes you are running your BeagleBone headless (without a monitor). In that case, we will need a way to remotely connect to it.
The Cloud9 IDE
The BeagleBone Debian images include an instance of the Cloud9 IDE (https://c9.io) running on port 3000. To access it, simply navigate to your BeagleBone Black's IP address with the port appended after a colon, that is, http://192.168.7.2:3000
. If it's your first time using Cloud9, you'll see the welcome screen, which lets you customize the look and feel:

The left panel lets you organize, create, and delete files in your Cloud9 workspace. When you open a file for editing, it is shown in the center panel, and the lower panel holds a Bash shell and a Javascript REPL. Files and terminal instances can be opened in both the center and bottom panels. Bash instances start in the Cloud9 workspace, but you can use them to navigate anywhere on the BeagleBone's filesystem. If you've never used the Bash shell I'd encourage you to take a look at the Bash manual (https://www.gnu.org/software/bash/manual/), as well as walk through a tutorial or two. It can be very helpful and even essential at times, to be able to use Bash, especially with a platform such as BeagleBone without a monitor connected.
Another great use for the Bash terminal in Cloud9 is for running the Python interactive interpreter, which you can launch in the terminal by running python
without any arguments:

SSH
If you're a Linux user, or if you would prefer not to be doing your development through a web browser, you may want to use SSH to access your BeagleBone instead. SSH, or Secure Shell, is a protocol for securely gaining terminal access to a remote computer over a network. On Windows, you can download PuTTY from http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html, which can act as an SSH client.
Run PuTTY, make sure SSH is selected, and enter your BeagleBone's IP address and the default SSH port of 22:

When you press Open, PuTTY will open an SSH connection to your BeagleBone and give you a terminal window (the first time you connect to your BeagleBone it will ask you if you trust the SSH key; press Yes). Enter root
as the username and press Enter to log in; you will be dropped into a Bash terminal:

As in the Cloud9 IDE's terminals, from here, you can use the Linux tools to move around the filesystem, create and edit files, and so on, and you can run the Python interactive interpreter to try out and debug Python code.
- Vue 3移動(dòng)Web開發(fā)與性能調(diào)優(yōu)實(shí)戰(zhàn)
- Magento 2 Development Cookbook
- Podman實(shí)戰(zhàn)
- CKA/CKAD應(yīng)試教程:從Docker到Kubernetes完全攻略
- Learning Network Forensics
- 精通Python設(shè)計(jì)模式(第2版)
- Python編程實(shí)戰(zhàn)
- RabbitMQ Cookbook
- 西門子S7-200 SMART PLC編程從入門到實(shí)踐
- Kotlin開發(fā)教程(全2冊(cè))
- 區(qū)塊鏈架構(gòu)之美:從比特幣、以太坊、超級(jí)賬本看區(qū)塊鏈架構(gòu)設(shè)計(jì)
- 30天學(xué)通C#項(xiàng)目案例開發(fā)
- JavaScript高級(jí)程序設(shè)計(jì)(第4版)
- Daniel Arbuckle's Mastering Python
- Drools 8規(guī)則引擎:核心技術(shù)與實(shí)踐