putfile命令不起作用

3次观看(最近30天)
Biruntha Gnaneswaran
Biruntha Gnaneswaran 2015年10月27日
嗨,我关注 将文件传输到Raspberry Pi硬件。在我发送图像时,它运行良好。但是,如果我发送文本文件会出现错误。我该如何解决?
mypi = raspi;
putfile(mypi,'output.txt',,,,'/home/pi/output.txt');
错误执行命令:pscp:output.txt:无法打开文件

答案(2)

穆拉特·贝尔(Murat Belge)
这对我来说很好。您可以执行以下命令帖子的结果:
>> a = dir('output.txt');
>> disp(a)
>>系统(mypi,'ls -al'
>>系统(mypi,'df -h'

Biruntha Gnaneswaran
Biruntha Gnaneswaran 2015年10月29日
fid = fopen('output.txt',,,,'W');
fprintf(fid,'%s',,,,'你好');
fclose(fid);
mypi = raspi;
putfile(mypi,'output.txt',,,,'/home/pi/output.txt');
在我使用pufile命令之后的fclose之前。现在此代码正在工作

社区寻宝

在Matlab Central中找到宝藏,发现社区如何为您提供帮助!

开始狩猎!