I've written a matlab script that receives data over udp and successfully graphs it realtime...however I'm having some trouble with the script crashing over what I assume is a problem with the inputBuffer becoming too full. (Not sure if this is the correct assumption)
Here's why I think that... Program crashed after a few seconds when the InputBufferSize = 1000... When I increased the the buffer to InputBufferSize = 1000000 (Just any Huge Number) the program runs for about a two minutes before crashing. I'm wondering if there is a method to clear the inputBuffer of a udp object in matlab and if this would fix the problem. Anyone know? Thanks :)

 채택된 답변

Matthew Mellor
Matthew Mellor 2016년 6월 28일

1 개 추천

Figured this out myself. Use flushInput(udpObject) every so often...

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 Startup and Shutdown에 대해 자세히 알아보기

제품

질문:

2016년 6월 28일

답변:

2016년 6월 28일

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by