To debug your program, I built your program using debug build
configuration and used gdb to look at the assert. The problem was not
detectable (on my system) using the default build configuration.
I configured as:
./ns3 configure -d debug
I ran the program as:
./ns3 run --gdb UAM202508
Then I ran at the gdb prompt.
The debug build and the gdb backtrace revealed that the code was
asserting because a YansWifiChannel object did not have a propagation
loss model installed.
This led me to look at how you are configuring the channels. The
problem is there. First of all, for the gNB PHYs, you are creating a
separate channel object for each gNB. Then for the STA, you are
creating a channel without a propagation loss model. The error is
triggered by an assert on this STA channel.
However, the fundamental problem is that you should instantiate only one
channel object (outside of the for loop) and then call SetChannel()
using this single channel object. If you create a separate channel for
every PHY, the program cannot work because the sender and receiver have
to be on the same channel.
> --
> Posting to this group should follow these guidelines https://
>
www.nsnam.org/wiki/Ns-3-users-guidelines-for-posting <https://
>
www.nsnam.org/wiki/Ns-3-users-guidelines-for-posting>
> ---
> You received this message because you are subscribed to the Google
> Groups "ns-3-users" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to
ns-3-users+...@googlegroups.com <mailto:
ns-3-
>
users+un...@googlegroups.com>.
> To view this discussion visit
https://groups.google.com/d/msgid/ns-3-
> users/50cb0273-95ab-4702-9ff3-314132f0ed1an%
40googlegroups.com <https://
>
groups.google.com/d/msgid/ns-3-
> users/50cb0273-95ab-4702-9ff3-314132f0ed1an%
40googlegroups.com?
> utm_medium=email&utm_source=footer>.