code: def get_net_configuration(self, channel=None, gateway_macs=True):
          
          if channel is None:
              channel = self.get_network_channel()
          retdata = {}
          v4addr = self._fetch_lancfg_param(channel, 3)
          if v4addr is None:
              retdata['ipv4_address'] = None
          else:
              v4masklen = self._fetch_lancfg_param(channel, 6, prefixlen=True)
              retdata['ipv4_address'] = '{0}/{1}'.format(v4addr, v4masklen)
          v4cfgmethods = {
              0: 'Unspecified',
              1: 'Static',
              2: 'DHCP',
              3: 'BIOS',
              4: 'Other',
          }
          retdata['ipv4_configuration'] = v4cfgmethods[self._fetch_lancfg_param(
              channel, 4)]
          retdata['mac_address'] = self._fetch_lancfg_param(channel, 5)
          retdata['ipv4_gateway'] = self._fetch_lancfg_param(channel, 12)
          retdata['ipv4_backup_gateway'] = self._fetch_lancfg_param(channel, 14)
          if gateway_macs:
              retdata['ipv4_gateway_mac'] = self._fetch_lancfg_param(channel, 13)
              retdata['ipv4_backup_gateway_mac'] = self._fetch_lancfg_param(
                  channel, 15)
          self.oem_init()
          self._oem.add_extra_net_configuration(retdata)
          return retdata
docs: Get network configuration data
  
          Retrieve network configuration from the target
  
          :param channel: Channel to configure, defaults to None for 'autodetect'
          :param gateway_macs: Whether to retrieve mac addresses for gateways
          :returns: A dictionary of network configuration data