port 0: Ethernet Controller X710 for 10GbE SFP+
Port 0 : *** command 'start' cannot be executed on current state: 'IDLE on profile_id(_).
The example in TRex doc:
So if I write it close to 100% like the example (except using my client variable that is connected instead of 'c' rest even rest ports is the same) above it does not send.
But yesterday, I created another branch and tried to use 'load_pcap' to load streams into a profile and do start like I usually do when I craft the packets myself and that worked...
Problem with that is I want to be able at some point to replay big files and I think the doc mentions that the functions that load the packets as streams are pretty much limited to 1 MB files.
So this works, with the same file:
def generateFromPcap(pcap_file, ipg_usec, loop_count, client_id, trex_client_port):
print(f' Send traffic of Pcap file {pcap_file}: trex port: {trex_client_port} loop count: {loop_count}')
return STLProfile.load_pcap(pcap_file, ipg_usec = 10, loop_count = loop_count).get_streams()
Full output of test using 'load_pcap':