Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.arch.embedded > #27004 > unrolled thread

FTP (or similar) over serial port of an embedded linux system

Started bypozz <pozzugno@gmail.com>
First post2017-07-06 09:44 +0200
Last post2017-07-07 20:11 -0500
Articles 9 — 8 participants

Back to article view | Back to comp.arch.embedded


Contents

  FTP (or similar) over serial port of an embedded linux system pozz <pozzugno@gmail.com> - 2017-07-06 09:44 +0200
    Re: FTP (or similar) over serial port of an embedded linux system Reinhardt Behm <rbehm@hushmail.com> - 2017-07-06 16:08 +0800
      Re: FTP (or similar) over serial port of an embedded linux system Theo Markettos <theom+news@chiark.greenend.org.uk> - 2017-07-06 11:03 +0100
    Re: FTP (or similar) over serial port of an embedded linux system Rob Gaddi <rgaddi@highlandtechnology.invalid> - 2017-07-06 09:30 -0700
    Re: FTP (or similar) over serial port of an embedded linux system Tauno Voipio <tauno.voipio@notused.fi.invalid> - 2017-07-06 22:41 +0300
    Re: FTP (or similar) over serial port of an embedded linux system Don Y <blockedofcourse@foo.invalid> - 2017-07-06 12:53 -0700
      Re: FTP (or similar) over serial port of an embedded linux system edward.ming.lee@gmail.com - 2017-07-06 13:24 -0700
      Re: FTP (or similar) over serial port of an embedded linux system pozz <pozzugno@gmail.com> - 2017-07-08 01:18 +0200
    Re: FTP (or similar) over serial port of an embedded linux system Les Cargill <lcargill99@comcast.com> - 2017-07-07 20:11 -0500

#27004 — FTP (or similar) over serial port of an embedded linux system

Frompozz <pozzugno@gmail.com>
Date2017-07-06 09:44 +0200
SubjectFTP (or similar) over serial port of an embedded linux system
Message-ID<ojkpgu$jja$1@dont-email.me>
Maybe this question should be posted in a linux development group, 
however the use of a serial port is more typical in an embedded 
environment, so I try to post here.

I have an embedded Linux box (based on a Raspberry) with a serial port 
converted to a USB port through a UART-USB transceiver from Microchip. 
This USB port is seen as a COM port under Windows OS.

I need to do simple operations on the filesystem through the serial 
port, mainly:
- list files in a directory
- download files
- upload files
- remove files

The user on the Windows PC should launch a simple script (it will be 
written in Python) that make all the operations in sequence.

Do you know of some technology/protocol that could be used in a simple way?

I have two ideas, maybe there's another one that is better.

The first is to configure a PPP over serial line and use classic FTP 
server for filesystem operations. However this solution implies that the 
user should configure the PPP link, but she will not have so much knowledge.

The second is to run the classical console on the serial port, with 
login and prompt. The python script should type/send commands at the 
prompt (ls, rm, ...). The download could be done with hexdump command 
(the python script could convert to binary again).
The upload should be done with echo command, writing a ASCII hex file 
and launching a simple script to convert from ASCII to binary on the 
embedded Linux.

Do you have other better solutions?

[toc] | [next] | [standalone]


#27005

FromReinhardt Behm <rbehm@hushmail.com>
Date2017-07-06 16:08 +0800
Message-ID<ojkqu9$lq7$2@dont-email.me>
In reply to#27004
AT Thursday 06 July 2017 15:44, pozz wrote:

> Maybe this question should be posted in a linux development group,
> however the use of a serial port is more typical in an embedded
> environment, so I try to post here.
> 
> I have an embedded Linux box (based on a Raspberry) with a serial port
> converted to a USB port through a UART-USB transceiver from Microchip.
> This USB port is seen as a COM port under Windows OS.
> 
> I need to do simple operations on the filesystem through the serial
> port, mainly:
> - list files in a directory
> - download files
> - upload files
> - remove files
> 
> The user on the Windows PC should launch a simple script (it will be
> written in Python) that make all the operations in sequence.
> 
> Do you know of some technology/protocol that could be used in a simple
> way?
> 
> I have two ideas, maybe there's another one that is better.
> 
> The first is to configure a PPP over serial line and use classic FTP
> server for filesystem operations. However this solution implies that the
> user should configure the PPP link, but she will not have so much
> knowledge.
> 
> The second is to run the classical console on the serial port, with
> login and prompt. The python script should type/send commands at the
> prompt (ls, rm, ...). The download could be done with hexdump command
> (the python script could convert to binary again).
> The upload should be done with echo command, writing a ASCII hex file
> and launching a simple script to convert from ASCII to binary on the
> embedded Linux.
> 
> Do you have other better solutions?

I have not fully investigated if it might work, but how about rz/sz?

-- 
Reinhardt

[toc] | [prev] | [next] | [standalone]


#27006

FromTheo Markettos <theom+news@chiark.greenend.org.uk>
Date2017-07-06 11:03 +0100
Message-ID<3ae*5k4vw@news.chiark.greenend.org.uk>
In reply to#27005
Reinhardt Behm <rbehm@hushmail.com> wrote:
> I have not fully investigated if it might work, but how about rz/sz?

They use zmodem - I've done similar things in the past, also with uuencode.
(zmodem was a lot faster than xmodem/ymodem back in the day, due to the
larger block size).

I'm not sure what would be a good tool to automate listing files, beyond
parsing the output of 'ls' and friends.

Theo

[toc] | [prev] | [next] | [standalone]


#27007

FromRob Gaddi <rgaddi@highlandtechnology.invalid>
Date2017-07-06 09:30 -0700
Message-ID<ojloch$res$1@dont-email.me>
In reply to#27004
On 07/06/2017 12:44 AM, pozz wrote:
> Maybe this question should be posted in a linux development group, 
> however the use of a serial port is more typical in an embedded 
> environment, so I try to post here.
> 
> I have an embedded Linux box (based on a Raspberry) with a serial port 
> converted to a USB port through a UART-USB transceiver from Microchip. 
> This USB port is seen as a COM port under Windows OS.
> 
> I need to do simple operations on the filesystem through the serial 
> port, mainly:
> - list files in a directory
> - download files
> - upload files
> - remove files
> 
> The user on the Windows PC should launch a simple script (it will be 
> written in Python) that make all the operations in sequence.
> 
> Do you know of some technology/protocol that could be used in a simple way?
> 
> I have two ideas, maybe there's another one that is better.
> 
> The first is to configure a PPP over serial line and use classic FTP 
> server for filesystem operations. However this solution implies that the 
> user should configure the PPP link, but she will not have so much 
> knowledge.
> 
> The second is to run the classical console on the serial port, with 
> login and prompt. The python script should type/send commands at the 
> prompt (ls, rm, ...). The download could be done with hexdump command 
> (the python script could convert to binary again).
> The upload should be done with echo command, writing a ASCII hex file 
> and launching a simple script to convert from ASCII to binary on the 
> embedded Linux.
> 
> Do you have other better solutions?
> 

Kermit?  I will say that any classic console based plan will probably be 
easier to implement in the modern age than PPP over serial; ESPECIALLY 
if you're having to deal with Windows.

-- 
Rob Gaddi, Highland Technology -- www.highlandtechnology.com
Email address domain is currently out of order.  See above to fix.

[toc] | [prev] | [next] | [standalone]


#27008

FromTauno Voipio <tauno.voipio@notused.fi.invalid>
Date2017-07-06 22:41 +0300
Message-ID<ojm3h8$1se$1@dont-email.me>
In reply to#27004
On 6.7.17 10:44, pozz wrote:
> Maybe this question should be posted in a linux development group, 
> however the use of a serial port is more typical in an embedded 
> environment, so I try to post here.
> 
> I have an embedded Linux box (based on a Raspberry) with a serial port 
> converted to a USB port through a UART-USB transceiver from Microchip. 
> This USB port is seen as a COM port under Windows OS.
> 
> I need to do simple operations on the filesystem through the serial 
> port, mainly:
> - list files in a directory
> - download files
> - upload files
> - remove files
> 
> The user on the Windows PC should launch a simple script (it will be 
> written in Python) that make all the operations in sequence.
> 
> Do you know of some technology/protocol that could be used in a simple way?
> 
> I have two ideas, maybe there's another one that is better.
> 
> The first is to configure a PPP over serial line and use classic FTP 
> server for filesystem operations. However this solution implies that the 
> user should configure the PPP link, but she will not have so much 
> knowledge.
> 
> The second is to run the classical console on the serial port, with 
> login and prompt. The python script should type/send commands at the 
> prompt (ls, rm, ...). The download could be done with hexdump command 
> (the python script could convert to binary again).
> The upload should be done with echo command, writing a ASCII hex file 
> and launching a simple script to convert from ASCII to binary on the 
> embedded Linux.
> 
> Do you have other better solutions?
> 

Why not use the Ethernet on the Raspberry?

-- 

-TV

[toc] | [prev] | [next] | [standalone]


#27009

FromDon Y <blockedofcourse@foo.invalid>
Date2017-07-06 12:53 -0700
Message-ID<ojm49f$438$1@dont-email.me>
In reply to#27004
On 7/6/2017 12:44 AM, pozz wrote:
> Maybe this question should be posted in a linux development group, however the 
> use of a serial port is more typical in an embedded environment, so I try to 
> post here.
> 
> I have an embedded Linux box (based on a Raspberry) with a serial port 

Don't they all have an ethernet port?  If so, support TELNET or SSH as
the "console" (throw away the silly USB-to-serial converter) and
SMB shares to access the file system "directly" -- without having
to use a script (that you'll have to maintain) and install Python,
etc.

Far more intuitive and probably less total effort, in the long run.

> converted to a USB port through a UART-USB transceiver from Microchip. This USB 
> port is seen as a COM port under Windows OS.
> 
> I need to do simple operations on the filesystem through the serial port, mainly:
> - list files in a directory
> - download files
> - upload files
> - remove files
> 
> The user on the Windows PC should launch a simple script (it will be written in 
> Python) that make all the operations in sequence.
> 
> Do you know of some technology/protocol that could be used in a simple way?
> 
> I have two ideas, maybe there's another one that is better.
> 
> The first is to configure a PPP over serial line and use classic FTP server for 
> filesystem operations. However this solution implies that the user should 
> configure the PPP link, but she will not have so much knowledge.
> 
> The second is to run the classical console on the serial port, with login and 
> prompt. The python script should type/send commands at the prompt (ls, rm, 
> ...). The download could be done with hexdump command (the python script could 
> convert to binary again).
> The upload should be done with echo command, writing a ASCII hex file and 
> launching a simple script to convert from ASCII to binary on the embedded Linux.
> 
> Do you have other better solutions?
> 

[toc] | [prev] | [next] | [standalone]


#27010

Fromedward.ming.lee@gmail.com
Date2017-07-06 13:24 -0700
Message-ID<cca9f359-07f3-4e78-9d8a-688b9ce971d7@googlegroups.com>
In reply to#27009
On Thursday, July 6, 2017 at 12:54:04 PM UTC-7, Don Y wrote:
> On 7/6/2017 12:44 AM, pozz wrote:
> > Maybe this question should be posted in a linux development group, however the 
> > use of a serial port is more typical in an embedded environment, so I try to 
> > post here.
> > 
> > I have an embedded Linux box (based on a Raspberry) with a serial port 
> 
> Don't they all have an ethernet port?  If so, support TELNET or SSH as
> the "console" (throw away the silly USB-to-serial converter) and
> SMB shares to access the file system "directly" -- without having
> to use a script (that you'll have to maintain) and install Python,
> etc.

Actually, the newer rPi has WiFi.  It would be hard to find a window PC without WiFi anyway.  You can config the rPi as WiFi access point and forget about any wires, usb or ethernet.

[toc] | [prev] | [next] | [standalone]


#27011

Frompozz <pozzugno@gmail.com>
Date2017-07-08 01:18 +0200
Message-ID<ojp4ku$ivr$1@dont-email.me>
In reply to#27009
Il 06/07/2017 21:53, Don Y ha scritto:
> On 7/6/2017 12:44 AM, pozz wrote:
>> Maybe this question should be posted in a linux development group, 
>> however the use of a serial port is more typical in an embedded 
>> environment, so I try to post here.
>>
>> I have an embedded Linux box (based on a Raspberry) with a serial port 
> 
> Don't they all have an ethernet port?

No, not natively. I'm using Compute Module with a custom board where I 
didn't a derived Ethernet port.

[toc] | [prev] | [next] | [standalone]


#27013

FromLes Cargill <lcargill99@comcast.com>
Date2017-07-07 20:11 -0500
Message-ID<ojpb5d$3js$1@dont-email.me>
In reply to#27004
pozz wrote:
> Maybe this question should be posted in a linux development group,
> however the use of a serial port is more typical in an embedded
> environment, so I try to post here.
>
> I have an embedded Linux box (based on a Raspberry)

... but with no Ethernet? How odd.

> with a serial
> port converted to a USB port through a UART-USB transceiver from
> Microchip. This USB port is seen as a COM port under Windows OS.
>
> I need to do simple operations on the filesystem through the serial
> port, mainly: - list files in a directory - download files - upload
> files - remove files
>
> The user on the Windows PC should launch a simple script (it will be
> written in Python) that make all the operations in sequence.
>
> Do you know of some technology/protocol that could be used in a
> simple way?
>
> I have two ideas, maybe there's another one that is better.
>
> The first is to configure a PPP over serial line and use classic FTP
> server for filesystem operations. However this solution implies that
> the user should configure the PPP link, but she will not have so
> much knowledge.
>

Is SLIP still a thing? I dimly recall it potentially being simpler
if no modem was involved.

I have to wonder how automatable a PPP connection is.

> The second is to run the classical console on the serial port, with
> login and prompt. The python script should type/send commands at the
> prompt (ls, rm, ...). The download could be done with hexdump
> command (the python script could convert to binary again). The upload
> should be done with echo command, writing a ASCII hex file and
> launching a simple script to convert from ASCII to binary on the
> embedded Linux.
>
> Do you have other better solutions?
>

-- 
Les Cargill

[toc] | [prev] | [standalone]


Back to top | Article view | comp.arch.embedded


csiph-web