You must be registered and logged in to post to this forum.
Hi all, I am in need of some basic help. I don't know if anyone here is familiar with the Matlab environment, but since you seem to be way more into these things than I am you might be able to help anyway. I want to connect and control Spykee from Matlab, but I run into problems right away. Shortly, what I have done is (I run Vista if that is important): 1. Connected via wifi to the spykee ip. 2. Create the tcpip-object to port 9000: t = tcpip('172.17.6.1',9000); 3. Open the port: fopen(t); 4. The port status is now: ByteOrder = bigEndian BytesAvailable = 0 BytesAvailableFcn = BytesAvailableFcnCount = 48 BytesAvailableFcnMode = terminator BytesToOutput = 0 ErrorFcn = InputBufferSize = 512 Name = TCPIP-172.17.6.1 ObjectVisibility = on OutputBufferSize = 512 OutputEmptyFcn = RecordDetail = compact RecordMode = overwrite RecordName = record.txt RecordStatus = off Status = closed Tag = Timeout = 10 TimerFcn = TimerPeriod = 1 TransferStatus = idle Type = tcpip UserData = [] ValuesReceived = 7 ValuesSent = 5 TCPIP specific properties: LocalHost = LocalPort = 63417 LocalPortMode = auto ReadAsyncMode = continuous RemoteHost = 172.17.6.1 RemotePort = 9000 Terminator = LF TransferDelay = on 5. Send first line (login: admin, passw: oporodo): fwrite(t,['PK' char(10) char(0) char(5+7+2)],'uchar'); No problem so far! 6. Send second line: fwrite(t,[char(5); 'admin'; char(7); 'oporodo'],'uchar'); Now I get an error: ??? Error using ==> icinterface.fwrite at 191 Connection closed by RemoteHost. Use FOPEN to connect to RemoteHost. If anyone can help me I would be extremely grateful! Cheers, Patrik