Reading Serial data through Simulink Input Packet is work in RealTime?
이전 댓글 표시
I'm using [Packet Input], [Packet output] Block in RealTime Window Target toolbox
tested both serial port, and UDP, with my Embedded board every 0.02 sec, I want to read new data from my board, and update state, but [Packet output]block missed alot of packet , and kill my labtop at last with blue screen
i guess that i need some script or funtion in init funtion which manage com port buffer or UDP buffer.
here is my environment what am I doing wrong?
matlab 2009b period 20ms packet size 36 bytes 1. C# UDP UDP = simulink through local network 2. Embedded board usb2uart = simulink
//----------------------------------------------------------------------// // Real TImw Windw Target descripstion //----------------------------------------------------------------------//
Real-time closed-loop execution of Simulink models on Microsoft Windows ▪ Signal visualization and parameter tuning while model is running ▪ Execution control directly from Simulink, creating a PC-in-the-loop prototyping environment ▪ Real-time performance approaching 500 Hz in normal execution mode ▪ Real-time performance approaching 20 kHz in external execution mode (with Simulink Coder) ▪ Blocks supporting more than 250 I/O modules (including analog I/O, digital I/O, counters, encoders, and frequency output) and communication protocols (including UDP, serial, and CAN)
댓글 수: 1
Jan Houska
2013년 3월 11일
I'm not aware of any such bug. 20ms of sampling period should work fine. Are you able to try a newer version of the software to see if you are getting the same problems?
답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 System Configuration에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!