tianyu12345
Posts: 9
Joined: Tue Mar 15, 2016 2:14 am

transfer file from pi to pc automatic help

Thu Mar 31, 2016 3:25 am

any one know anyways to automatic transfer file from pi to pc i used winscp but the automatic part is only transfer file from pc to my pi , i did some research they told me to write script but i am a newbie i have no idea what i should do any help is appreciated thank you !

spock
Posts: 223
Joined: Sun Oct 02, 2011 10:33 am

Re: transfer file from pi to pc automatic help

Thu Mar 31, 2016 11:30 am

what exactly do you mean with automatic?

syncing a folder?

you could try to use bittorrent sync. it's very easy to set up.

User avatar
procount
Posts: 2411
Joined: Thu Jun 27, 2013 12:32 pm
Location: UK

Re: transfer file from pi to pc automatic help

Thu Mar 31, 2016 12:15 pm

Please be more specific - Do you want the Pi to PUSH the file to the (Windows?) PC?
Or do you want the (Windows) PC to PULL the file from the Pi?

In Windows, PUTTY has a command line version of WinSCP (PSCP?) that can be used in a script (batch file) to push files to, or pull files from the Pi.
On the Pi In Raspbian, you could use SCP, but you would need an SSH server running on Windows(?)

Or you could run an FTP file server on the Pi or the PC and (S)FTP files from one to the other.

Or you could use SAMBA to share a drive/folder onto the other device and just copy the files onto there, or use rsync...

There are many ways to skin a cat! - I hope these ideas point to something suitable for you.
PINN - NOOBS with the extras... https://www.raspberrypi.org/forums/viewtopic.php?f=63&t=142574

JimmyN
Posts: 1109
Joined: Wed Mar 18, 2015 7:05 pm
Location: Virginia, USA

Re: transfer file from pi to pc automatic help

Thu Mar 31, 2016 12:33 pm

Or you could share a folder on Windows and mount the share on the RPi.
You wouldn't have to transfer any files to the PC because they'd already be on the PC. You could work with them on the RPi just as if they were local, and changes made to the files would be in real time rather than waiting for a file transfer event of some type to update the PC.

User avatar
solar3000
Posts: 1059
Joined: Sat May 18, 2013 12:14 am

Re: transfer file from pi to pc automatic help

Thu Mar 31, 2016 1:26 pm

JimmyN wrote:Or you could share a folder on Windows and mount the share on the RPi.
You wouldn't have to transfer any files to the PC because they'd already be on the PC. You could work with them on the RPi just as if they were local, and changes made to the files would be in real time rather than waiting for a file transfer event of some type to update the PC.
I agree. I would also do this. Or ssh with a trusted key.
But samba share would probably be easiest. On the pi, you would just write a script to copy your files to a folder thats already mounted.
Antikythera

pksato
Posts: 295
Joined: Fri Aug 03, 2012 5:25 pm
Location: Brazil

Re: transfer file from pi to pc automatic help

Thu Mar 31, 2016 3:06 pm

Can use rsync.
install rsync and start the daemon.
install some rsync client on windows.
Suggestion: http://www.aboutmyip.com/AboutMyXApp/DeltaCopy.jsp

To install sync on raspbian:
sudo install rsync
sudo nano /etc/default/rsync
change
RSYNC_ENABLE=false
to
RSYNC_ENABLE=true
save file.
start rsync
sudo service rsync start

And configure windows client to connect and fetch files.

tianyu12345
Posts: 9
Joined: Tue Mar 15, 2016 2:14 am

Re: transfer file from pi to pc automatic help

Mon Apr 04, 2016 3:15 am

can you guys give me an example to write a script ? Because i am totally new to this kind of stuff . And as for file transfer i want to for example i have a folder in my raspberry pi desktop and in the folder have files so when i put in new files to that folder it will transfer the new files to my pc

Return to “General discussion”