0

i got a problem with receiving a raw data stream from the lan connection of a time of flight camera (mesa sr4500) to my pc via simulink. the ip adress and the port of the simulink block tcp/ip receive seems to be chosen correctly (it is the ip adress and port of my network card). here's a picture of the further settings of the simulink block:

remote address: 192.168.1.1
port : 139
data size: [25344 1] -> should receive an array of this size due to the image resolution
data type uint16 -> each pixel of the camera is encoded with 16 bits
bye order: BigEndian
enable blocking mode is turned on
timeout: 10 (seconds)
block sample time: 0.1 (seconds) -> camera fps = 10

and this is the error msg, that i'm receiving.

Block error -> Error evaluating registered method 'outputs' of MATLAB S-Function 'stciprb' in 'decoding/TCP/IP Receive'

Caused by: The specified amount of data was not returned within the Timeout period. Please ensure that data is being sent to the specified port of specify a greater timeout value.

i think a greater timeout wouldnt help, because the camera is already streaming with 10 fps. so the timeout should be long enough.

have i misunderstood any of the setting options? has someone worked with a similar camera?

tim
  • 9,896
  • 20
  • 81
  • 137
bluhub
  • 129
  • 1
  • 2
  • 10
  • Welcome to Stack Overflow. Questions should include all relevant material. Links to external sites aren't acceptable as they can break, leaving the question with no permanent value. Edit the information into your post. – user207421 Jan 06 '14 at 00:18
  • 1
    sorry for the external sources but i wasnt allowed to upload the pictures to this site due to the fact that i need 10 posts at least. hope its fine now. – bluhub Jan 06 '14 at 09:50
  • No, it isn't, see closure. You need to garnish some reputation, and you won't do it by breaking site rules. On the contrary. – user207421 Jan 06 '14 at 09:55

1 Answers1

1

Since you're getting Timeout error, it's probably, because Simulink doesn't see your camera, so either you have assigned the wrong IP address or port in the TCP/IP Receive block. The IP address and port of your network card (by that I presume you meant network card of your PC?) won't work, you need to assign IP of the camera.

Open TCP/IP Receive block and click Verify address and port connectivity, with that you'll get the output message whether Simulink sees your camera's IP and port. By the way I see you have set your port to 139 (that's port for NetBIOS session services). I don't know if your camera uses some special dedicated port (for example some cameras with very low fps send pictures through FTP on port 20, but with 10 fps I doubt that's the case with your camera?). Try to assign a free port (i.e. number between 1024 and 65536).

MCLenc
  • 31
  • 4