Reconstructing OpenFlow Packets in Matlab
3 次查看(过去 30 天)
显示 更早的评论
Hello Matlab Community
I am new to using Matlab. I am actually having hard time writing codes that are written in C and converting them to Matlab. I have heard about MEX files, that makes C codes work in Matlab. However, I don't know if this will be of any use to my needs.
I am building certain types of packets used in OpenFlow Protocol (related to SDN) using Matlab, I am in need to know how should I build Structs written in C into Matlab?
An example
/* Header on all OpenFlow packets. */
struct ofp_header {
uint8_t version; /* OFP_VERSION. */
uint8_t type; /* One of the OFPT_ constants. */
uint16_t length; /* Length including this ofp_header. */
uint32_t xid; /* Transaction id associated with this packet. Replies use the same id as was in the request to facilitate pairing. */
};
How should I construct such a packet then call a function/method to create it with desired payloads and such?
I am not asking someone to do my work. All in need is a bit of help to keep moving forward.
Thank you!
0 个评论
回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Data Type Conversion 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!