Random allocation bit stream

3 views (last 30 days)
Noninzi Gugwana
Noninzi Gugwana on 27 May 2019
Answered: Walter Roberson on 27 May 2019
How do i generate a data packet with 16 bits, randomly allocated on Matlab?

Answers (1)

Walter Roberson
Walter Roberson on 27 May 2019
If you have the Instrument Control toolbox, then you can use tcp() or udp() to create connections and then fwrite() the two-byte payloads.
Otherwise you might be able to use tcpclient() and write(), provided that you are talking to a server.
Otherwise you could look in the File Exchange, at the tcpudpip contribution that uses wireshark.
If you want to construct an entire packet for the purposes of the Communications Toolbox then there are various options, depending on the level of detail you want to get into. If you want to construct packets for Software Defined Radio then see https://www.mathworks.com/help/supportpkg/usrpradio/ug/what-to-do-after-installation.html . You could also consider the LTE toolbox and the 5G toolbox.

Categories

Find more on Instrument Control Toolbox Supported Hardware in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!