Registered User mNo edit summary |
Registered User mNo edit summary Tag: 2017 source edit |
||
(20 intermediate revisions by 5 users not shown) | |||
Line 1: | Line 1: | ||
<noinclude> | <noinclude>{{ApplicableFor | ||
{{ | |MPUs list=STM32MP13x, STM32MP15x, STM32MP25x | ||
|MPUs checklist=STM32MP13x, STM32MP15x, STM32MP25x | |||
}}</noinclude> | |||
</noinclude> | |||
==Article purpose== | ==Article purpose== | ||
The article aims to give some information useful to start with the '''''scp''''' Linux command. | The article aims to give some information useful to start with the '''''scp''''' Linux command. | ||
Line 25: | Line 22: | ||
==Getting started == | ==Getting started == | ||
* Your host PC and your board are connected to your local network through {{UpdateNeededForNewBoard|Point to the Ethernet connector (if any) of the new board}} | * Your host PC and your board are connected to your local network through {{UpdateNeededForNewBoard|Point to the Ethernet connector (if any) of the new board}} | ||
:* the [[ | :* the [[STM32MP135x-DK_-_hardware_description#Board_overview|STM32MP135x-DKx Discovery kit CN4 Ethernet connector or CN15 Ethernet connector]] | ||
:* the [[ | :* the [[STM32MP157x-DKx - hardware_description#MB1272-CN8|STM32MP157x-DKx Discovery kit CN8 Ethernet connector]] | ||
:* the [[STM32MP157x-EV1 - hardware description#MB1262-CN3|STM32MP157x-EV1 Evaluation board CN3 Ethernet connector]] | |||
:* the [[STM32MP257x-EV1 - hardware description#MB1936-CN16|STM32MP257x-EV1 Evaluation board CN16 Ethernet connector]] | |||
:* the [[STM32MP257x-DKx - hardware description#MB1605ComponentsLayout|STM32MP257x-DKx Discovery kit CN16 Ethernet connector]] | |||
* The board IP address (''<board ip address>'') has been retrieved thanks to the [[IP Linux command line|''ip'' Linux command line]] | * The board IP address (''<board ip address>'') has been retrieved thanks to the [[IP Linux command line|''ip'' Linux command line]] | ||
Line 40: | Line 40: | ||
Check the result on the board | Check the result on the board | ||
{{Board$}} cat /home/root/example.txt | {{Board$}} cat /home/root/example.txt | ||
scp example | scp example: from host PC to board | ||
* Download a file (''/<board file path>/<example.txt>'') from your board to your host PC: | * Download a file (''/<board file path>/<example.txt>'') from your board to your host PC: | ||
Line 57: | Line 57: | ||
<references /> | <references /> | ||
<noinclude> | |||
[[Category:How to run use cases]] | |||
[[Category:How to populate boards]] | |||
{{PublicationRequestId | 7893 | 2018-07-03 | AlainF}} | |||
</noinclude> |
Latest revision as of 20:07, 6 November 2024
1. Article purpose
The article aims to give some information useful to start with the scp Linux command.
2. Introduction
The scp[1] copies files between hosts on a network. It uses ssh[2] (remote login program) for data transfer, uses the same authentication and provides the same security as ssh.
This article focuses on the file transfer between a host PC and a STMicroelectronics board over a network connection.
3. Installation on your target
The scp is installed on the STMicroelectronics images via the package openssh.
4. Installation on your PC
The package openssh-client must be installed on your host PC to perform a file transfer over network with the scp.
On Ubuntu:
sudo apt-get install openssh-client
5. Getting started
- Your host PC and your board are connected to your local network through
- the STM32MP135x-DKx Discovery kit CN4 Ethernet connector or CN15 Ethernet connector
- the STM32MP157x-DKx Discovery kit CN8 Ethernet connector
- the STM32MP157x-EV1 Evaluation board CN3 Ethernet connector
- the STM32MP257x-EV1 Evaluation board CN16 Ethernet connector
- the STM32MP257x-DKx Discovery kit CN16 Ethernet connector
- The board IP address (<board ip address>) has been retrieved thanks to the ip Linux command line
- Upload a file (<host file path>/<example.txt>) from your host PC to your board:
scp <host file path>/<example.txt> root@<board ip address>:/<board file path>/
Example (assuming that <board ip address> is a.b.c.d):
Copy the example.txt host PC file in the /home/root/ board directory
echo "scp example: from host PC to board" > ./example.txt
scp ./example.txt root@a.b.c.d:/home/root
Check the result on the board
cat /home/root/example.txt
scp example: from host PC to board
- Download a file (/<board file path>/<example.txt>) from your board to your host PC:
scp root@<board ip address>:/<board file path>/<example.txt> <host file path>/
Example (assuming that <board ip address> is a.b.c.d):
Copy the example.txt board file in the current directory of the host PC
echo "scp example: from board to host PC" > /home/root/example.txt
scp root@a.b.c.d:/home/root/example.txt ./
Check the result on the host PC
cat ./example.txt
scp example: from board to host PC
6. References