8.2.4.3.4. Multicast

8.2.4.3.4.1. Mode

A multicast mode for a port. Ports can use the IGMPv2 protocol to join or leave multicast groups, either on an on-off basis or repeatedly.

Corresponding low-level API class: P_MULTICAST

# Multicast Mode
await port.multicast.mode.set(
    ipv4_multicast_addresses=[],
    operation=enums.MulticastOperation.JOIN,
    second_count=10)
await port.multicast.mode.set(
    ipv4_multicast_addresses=[],
    operation=enums.MulticastOperation.JOIN,
    second_count=10)
await port.multicast.mode.set(
    ipv4_multicast_addresses=[],
    operation=enums.MulticastOperation.LEAVE,
    second_count=10)
await port.multicast.mode.set(
    ipv4_multicast_addresses=[],
    operation=enums.MulticastOperation.OFF,
    second_count=10)
await port.multicast.mode.set(
    ipv4_multicast_addresses=[],
    operation=enums.MulticastOperation.ON,
    second_count=10)

resp = await port.multicast.mode.get()
resp.ipv4_multicast_addresses
resp.operation
resp.second_count

8.2.4.3.4.2. Extended Mode

A multicast mode for a port. Ports can use the IGMPv2/IGMPv3 protocol to join or leave multicast groups, either on an on-off basis or repeatedly.

Corresponding low-level API class: P_MULTICASTEXT

# Multicast Extended Mode
await port.multicast.mode_extended.set(
    ipv4_multicast_addresses=[],
    operation=enums.MulticastExtOperation.EXCLUDE,
    second_count=10,
    igmp_version=enums.IGMPVersion.IGMPV3
)
await port.multicast.mode_extended.set(
    ipv4_multicast_addresses=[],
    operation=enums.MulticastExtOperation.INCLUDE,
    second_count=10,
    igmp_version=enums.IGMPVersion.IGMPV3
)
await port.multicast.mode_extended.set(
    ipv4_multicast_addresses=[],
    operation=enums.MulticastExtOperation.JOIN,
    second_count=10,
    igmp_version=enums.IGMPVersion.IGMPV2
)
await port.multicast.mode_extended.set(
    ipv4_multicast_addresses=[],
    operation=enums.MulticastExtOperation.LEAVE,
    second_count=10,
    igmp_version=enums.IGMPVersion.IGMPV2
)
await port.multicast.mode_extended.set(
    ipv4_multicast_addresses=[],
    operation=enums.MulticastExtOperation.LEAVE_TO_ALL,
    second_count=10,
    igmp_version=enums.IGMPVersion.IGMPV2
)
await port.multicast.mode_extended.set(
    ipv4_multicast_addresses=[],
    operation=enums.MulticastExtOperation.GENERAL_QUERY,
    second_count=10,
    igmp_version=enums.IGMPVersion.IGMPV2
)
await port.multicast.mode_extended.set(
    ipv4_multicast_addresses=[],
    operation=enums.MulticastExtOperation.GROUP_QUERY,
    second_count=10,
    igmp_version=enums.IGMPVersion.IGMPV2
)
await port.multicast.mode_extended.set(
    ipv4_multicast_addresses=[],
    operation=enums.MulticastExtOperation.ON,
    second_count=10,
    igmp_version=enums.IGMPVersion.IGMPV2
)
await port.multicast.mode_extended.set(
    ipv4_multicast_addresses=[],
    operation=enums.MulticastExtOperation.OFF,
    second_count=10,
    igmp_version=enums.IGMPVersion.IGMPV2
)

resp = await port.multicast.mode_extended.get()
resp.ipv4_multicast_addresses
resp.operation
resp.second_count
resp.igmp_version

8.2.4.3.4.3. Source List

Multicast source list of the port. Only valid if the IGMP protocol version is IGMPv3 set by P_MULTICAST.

Corresponding low-level API class: P_MCSRCLIST

# Multicast Source List
await port.multicast.source_list.set(ipv4_addresses=[])

resp = await port.multicast.source_list.get()
resp.ipv4_addresses

8.2.4.3.4.5. IGMPv3 Group Record

Configure if a single membership report bundles multiple multicast group records to decrease the number of packets sent when using IGMPv3. This command returns <NOTVALID> when the IGMP version is not IGMPv3.

Corresponding low-level API class: P_IGMPV3_GROUP_RECORD_BUNDLE

# IGMPv3 Group Record
await port_obj.multicast.igmpv3_group_record_bundle.set(mode=enums.OnOff.ON)
await port_obj.multicast.igmpv3_group_record_bundle.set(mode=enums.OnOff.OFF)

resp = await port_obj.multicast.igmpv3_group_record_bundle.get()
resp.mode