public RTL8139(PCIDevice device) { if (device == null) { throw new ArgumentException("PCI Device is null. Unable to get Realtek 8139 card"); } pciCard = device; // We are handling this device pciCard.Claimed = true; // Setup interrupt handling //Interrupts.IRQ11 += HandleNetworkInterrupt; //Interrupts.AddIRQHandler(device.InterruptLine, HandleNetworkInterrupt); // Get IO Address from PCI Bus io = pciCard.GetAddressSpace(0); // Enable the card pciCard.EnableDevice(); // Turn on the card io.Write8(0x52, 0x01); //Do a software reset SoftwareReset(); // Get the MAC Address byte[] eeprom_mac = new byte[6]; for (uint b = 0; b < 6; b++) { eeprom_mac[b] = io.Read8(b); } this.mac = new MACAddress(eeprom_mac); // Get a receive buffer and assign it to the card rxBuffer = new ManagedMemorySpace(RxBufferSize + 2048 + 16, 4); RBStartRegister = rxBuffer.Offset; // Setup receive Configuration RecvConfigRegister = 0xF381; // Setup Transmit Configuration TransmitConfigRegister = 0x3000300; // Setup Interrupts IntMaskRegister = 0x7F; IntStatusRegister = 0xFFFF; // Setup our Receive and Transmit Queues mRecvBuffer = new Queue <byte[]>(); mTransmitBuffer = new Queue <byte[]>(); }
private ProtectionDomain(AddressSpace space, string name, bool isKernelDomain) { this.space = space; this.name = name; this.kernelMode = isKernelDomain; this.initSpin = new SmartSpinlock(SpinLock.Types.ProtectionDomainInit); this.userMappingLock = new SmartSpinlock(SpinLock.Types.ProtectionDomainMapping); this.refCount = 1; // represents the table entry #if VERBOSE DebugStub.WriteLine("Created protection domain \"{0}\"", __arglist(name)); #endif }
private void ArrayRead32(AddressSpace bar, int barOffset, ref int[] data32, int startIndex, int num32BitWords) { if (data32.Length < (startIndex + num32BitWords)) { throw new Exception("Wrong ArrayRead32 : data32.Length < (startIndex + num32BitWords)"); } for (int i = startIndex; i < (startIndex + num32BitWords); i++) { data32[i] = RegRead(bar, barOffset + i); } }
public void ArrayWrite(AddressSpace bar, int barOffset, int[] data32, int length, int offset) { if (data32.Length < (offset + length)) { throw new Exception("Wrong ArrayWrite: offset + length > size"); } for (int i = offset; i < (offset + length); i++) { int val = data32[i]; RegWrite(bar, barOffset + i, val); } }
internal VirtualNetworkPeering(string id, string name, string etag, bool?allowVirtualNetworkAccess, bool?allowForwardedTraffic, bool?allowGatewayTransit, bool?useRemoteGateways, SubResource remoteVirtualNetwork, AddressSpace remoteAddressSpace, VirtualNetworkPeeringState?peeringState, ProvisioningState?provisioningState) : base(id) { Name = name; Etag = etag; AllowVirtualNetworkAccess = allowVirtualNetworkAccess; AllowForwardedTraffic = allowForwardedTraffic; AllowGatewayTransit = allowGatewayTransit; UseRemoteGateways = useRemoteGateways; RemoteVirtualNetwork = remoteVirtualNetwork; RemoteAddressSpace = remoteAddressSpace; PeeringState = peeringState; ProvisioningState = provisioningState; }
/// <summary> /// Construct a VISA session with the specified slot number "fallback register". /// NOTE: the "fallback register" is only used if reading VISA attribute VI_ATTR_SLOT fails /// </summary> /// <param name="slotNumberAddressSpace"></param> /// <param name="slotNumberRegisterAddress"></param> public VisaSession(AddressSpace slotNumberAddressSpace, short slotNumberRegisterAddress) { SlotNumberAddressSpace = slotNumberAddressSpace; SlotNumberRegisterAddress = slotNumberRegisterAddress; lock ( mResourceManagerLock ) { if (mResourceManager == 0) { CheckStatus(AgVisa32.viOpenDefaultRM(out mResourceManager)); } mResourceManagerCount++; } }
internal VpnSiteData(string id, string name, string type, string location, IDictionary <string, string> tags, string etag, WritableSubResource virtualWan, DeviceProperties deviceProperties, string ipAddress, string siteKey, AddressSpace addressSpace, BgpSettings bgpProperties, ProvisioningState?provisioningState, bool?isSecuritySite, IList <VpnSiteLinkData> vpnSiteLinks, O365PolicyProperties o365Policy) : base(id, name, type, location, tags) { Etag = etag; VirtualWan = virtualWan; DeviceProperties = deviceProperties; IPAddress = ipAddress; SiteKey = siteKey; AddressSpace = addressSpace; BgpProperties = bgpProperties; ProvisioningState = provisioningState; IsSecuritySite = isSecuritySite; VpnSiteLinks = vpnSiteLinks; O365Policy = o365Policy; }
public static BinaryFormat GetCorrespondingModernFormat(this AddressSpace addressSpace) { switch (addressSpace) { case AddressSpace.Int32: return(BinaryFormat.F2nd); case AddressSpace.Int64: return(BinaryFormat.X); default: throw new ArgumentOutOfRangeException(nameof(addressSpace), addressSpace, null); } }
public static int GetByteSize(this AddressSpace addressSpace) { switch (addressSpace) { case AddressSpace.Int32: return(4); case AddressSpace.Int64: return(8); default: throw new ArgumentOutOfRangeException(nameof(addressSpace)); } }
public AddressSpaceEntry(AddressSpace addressSpace) { this.type = addressSpace.Type; this.address = addressSpace.Address; this.cost = addressSpace.Cost; this.addressSpaceKey = string.Concat(new object[] { this.type, ":", this.address, ";", this.cost }); }
public LineAsm(AddressSpace Mem, M6502 Cpu) { // Setup form InitializeComponent(); mem = Mem; CPU = Cpu; // Create assembler and disassembler objects dasm = new M6502DASM(mem, CPU); asm = new Assembler(); // Init form fields txtLine.Text = ""; txtAddr.Text = "1000"; }
/// <summary> /// Internal method to initialize and populate the address space using the <paramref name="getNodesFromModel"/>. The <paramref name="getNodesFromModel"/> /// should be used while traversing the information model to add address space nodes and references. /// </summary> /// <param name="getNodesFromModel">The get nodes from model.</param> /// <returns>IAddressSpaceContent.</returns> protected override IElement[] InternalCreateInstance(Action <IAddressSpaceCreator> getNodesFromModel, Action <string> traceEvent) { m_TraceEvent = traceEvent; traceEvent("Starting address space compilation, the process could take minutes."); IElement[] _ret = new IElement[0]; m_AddressSpace = new AddressSpace(); getNodesFromModel(this); Validate(traceEvent); if (m_Root == null) { throw new ApplicationException("Cannot display the model because the Root element cannot ne found in the model."); } _ret = new IElement[] { AddressSpaceElement.CreateAddressSpaceElement(m_Root, this) }; traceEvent(String.Format("Created the Root element {0}", _ret[0].Name)); return(_ret); }
public void GetSemanticDataSourcesTest() { using (ISemanticDataSource _set = BoilersSet.Factory) { Assert.IsNotNull(_set); _set.GetSemanticDataSources((semanticDataSetRootBrowsePath, variableRelativeBrowsePath, variable) => AddressSpace.Add($"{semanticDataSetRootBrowsePath}:{variableRelativeBrowsePath}", variable)); Assert.AreEqual <int>(80, AddressSpace.Count); foreach (KeyValuePair <string, IVariable> _var in AddressSpace) { Debug.WriteLine($"{_var.Key}:{_var.Value.ValueType}"); } } Assert.IsTrue(AddressSpace.ContainsKey("BoilersArea_Boiler #1:CCX001_ControlOut")); Assert.IsTrue(AddressSpace.ContainsKey("BoilersArea_Boiler #2:CCX001_ControlOut")); Assert.IsTrue(AddressSpace.ContainsKey("BoilersArea_Boiler #3:CCX001_ControlOut")); Assert.IsTrue(AddressSpace.ContainsKey("BoilersArea_Boiler #4:CCX001_ControlOut")); }
internal VirtualNetworkPeeringData(ResourceIdentifier id, string name, ResourceType?resourceType, ETag?etag, bool?allowVirtualNetworkAccess, bool?allowForwardedTraffic, bool?allowGatewayTransit, bool?useRemoteGateways, WritableSubResource remoteVirtualNetwork, AddressSpace remoteAddressSpace, AddressSpace remoteVirtualNetworkAddressSpace, VirtualNetworkBgpCommunities remoteBgpCommunities, VirtualNetworkPeeringState?peeringState, VirtualNetworkPeeringLevel?peeringSyncLevel, NetworkProvisioningState?provisioningState, bool?doNotVerifyRemoteGateways, Guid?resourceGuid) : base(id, name, resourceType) { Etag = etag; AllowVirtualNetworkAccess = allowVirtualNetworkAccess; AllowForwardedTraffic = allowForwardedTraffic; AllowGatewayTransit = allowGatewayTransit; UseRemoteGateways = useRemoteGateways; RemoteVirtualNetwork = remoteVirtualNetwork; RemoteAddressSpace = remoteAddressSpace; RemoteVirtualNetworkAddressSpace = remoteVirtualNetworkAddressSpace; RemoteBgpCommunities = remoteBgpCommunities; PeeringState = peeringState; PeeringSyncLevel = peeringSyncLevel; ProvisioningState = provisioningState; DoNotVerifyRemoteGateways = doNotVerifyRemoteGateways; ResourceGuid = resourceGuid; }
internal bool GetScopedConnector() { if (this[MailGatewaySchema.IsScopedConnector] == null) { MultiValuedProperty <AddressSpace> addressSpaces = this.AddressSpaces; using (MultiValuedProperty <AddressSpace> .Enumerator enumerator = addressSpaces.GetEnumerator()) { if (enumerator.MoveNext()) { AddressSpace addressSpace = enumerator.Current; return(addressSpace.IsLocal); } } return(false); } return((bool)this[MailGatewaySchema.IsScopedConnector]); }
internal VirtualNetworkData(string id, string name, string type, string location, IDictionary <string, string> tags, ExtendedLocation extendedLocation, string etag, AddressSpace addressSpace, DhcpOptions dhcpOptions, int?flowTimeoutInMinutes, IList <SubnetData> subnets, IList <VirtualNetworkPeeringData> virtualNetworkPeerings, string resourceGuid, ProvisioningState?provisioningState, bool?enableDdosProtection, bool?enableVmProtection, SubResource ddosProtectionPlan, VirtualNetworkBgpCommunities bgpCommunities, IList <SubResource> ipAllocations) : base(id, name, type, location, tags) { ExtendedLocation = extendedLocation; Etag = etag; AddressSpace = addressSpace; DhcpOptions = dhcpOptions; FlowTimeoutInMinutes = flowTimeoutInMinutes; Subnets = subnets; VirtualNetworkPeerings = virtualNetworkPeerings; ResourceGuid = resourceGuid; ProvisioningState = provisioningState; EnableDdosProtection = enableDdosProtection; EnableVmProtection = enableVmProtection; DdosProtectionPlan = ddosProtectionPlan; BgpCommunities = bgpCommunities; IpAllocations = ipAllocations; }
internal VirtualNetworkData(ResourceIdentifier id, string name, ResourceType?resourceType, AzureLocation?location, IDictionary <string, string> tags, Models.ExtendedLocation extendedLocation, ETag?etag, AddressSpace addressSpace, DhcpOptions dhcpOptions, int?flowTimeoutInMinutes, IList <SubnetData> subnets, IList <VirtualNetworkPeeringData> virtualNetworkPeerings, Guid?resourceGuid, NetworkProvisioningState?provisioningState, bool?enableDdosProtection, bool?enableVmProtection, WritableSubResource ddosProtectionPlan, VirtualNetworkBgpCommunities bgpCommunities, IList <WritableSubResource> ipAllocations) : base(id, name, resourceType, location, tags) { ExtendedLocation = extendedLocation; Etag = etag; AddressSpace = addressSpace; DhcpOptions = dhcpOptions; FlowTimeoutInMinutes = flowTimeoutInMinutes; Subnets = subnets; VirtualNetworkPeerings = virtualNetworkPeerings; ResourceGuid = resourceGuid; ProvisioningState = provisioningState; EnableDdosProtection = enableDdosProtection; EnableVmProtection = enableVmProtection; DdosProtectionPlan = ddosProtectionPlan; BgpCommunities = bgpCommunities; IPAllocations = ipAllocations; }
internal VirtualNetworkPeeringData(string id, string name, string etag, string type, bool?allowVirtualNetworkAccess, bool?allowForwardedTraffic, bool?allowGatewayTransit, bool?useRemoteGateways, WritableSubResource remoteVirtualNetwork, AddressSpace remoteAddressSpace, AddressSpace remoteVirtualNetworkAddressSpace, VirtualNetworkBgpCommunities remoteBgpCommunities, VirtualNetworkPeeringState?peeringState, VirtualNetworkPeeringLevel?peeringSyncLevel, ProvisioningState?provisioningState, bool?doNotVerifyRemoteGateways, string resourceGuid) : base(id) { Name = name; Etag = etag; Type = type; AllowVirtualNetworkAccess = allowVirtualNetworkAccess; AllowForwardedTraffic = allowForwardedTraffic; AllowGatewayTransit = allowGatewayTransit; UseRemoteGateways = useRemoteGateways; RemoteVirtualNetwork = remoteVirtualNetwork; RemoteAddressSpace = remoteAddressSpace; RemoteVirtualNetworkAddressSpace = remoteVirtualNetworkAddressSpace; RemoteBgpCommunities = remoteBgpCommunities; PeeringState = peeringState; PeeringSyncLevel = peeringSyncLevel; ProvisioningState = provisioningState; DoNotVerifyRemoteGateways = doNotVerifyRemoteGateways; ResourceGuid = resourceGuid; }
public Machine7800(Cart cart, Bios7800 bios, HSC7800 hsc, ILogger logger, int scanlines, int startl, int fHZ, int sRate, int[] p) : base(logger, scanlines, startl, fHZ, sRate, p, 320) { Mem = new AddressSpace(this, 16, 6); // 7800: 16bit, 64byte pages CPU = new M6502(this, 4); Maria = new Maria(this, scanlines); Mem.Map(0x0000, 0x0040, Maria); Mem.Map(0x0100, 0x0040, Maria); Mem.Map(0x0200, 0x0040, Maria); Mem.Map(0x0300, 0x0040, Maria); PIA = new PIA(this); Mem.Map(0x0280, 0x0080, PIA); Mem.Map(0x0480, 0x0080, PIA); Mem.Map(0x0580, 0x0080, PIA); RAM1 = new RAM6116(); RAM2 = new RAM6116(); Mem.Map(0x1800, 0x0800, RAM1); Mem.Map(0x2000, 0x0800, RAM2); Mem.Map(0x0040, 0x00c0, RAM2); // page 0 shadow Mem.Map(0x0140, 0x00c0, RAM2); // page 1 shadow Mem.Map(0x2800, 0x0800, RAM2); // shadow1 Mem.Map(0x3000, 0x0800, RAM2); // shadow2 Mem.Map(0x3800, 0x0800, RAM2); // shadow3 BIOS = bios; HSC = hsc; if (HSC != null) { Mem.Map(0x1000, 0x800, HSC.SRAM); Mem.Map(0x3000, 0x1000, HSC); Logger.WriteLine("7800 Highscore Cartridge Installed"); } Cart = cart; Mem.Map(0x4000, 0xc000, Cart); }
public Machine2600(Cart cart, ILogger logger, int slines, int startl, int fHZ, int sRate, int[] p) : base(logger, slines, startl, fHZ, sRate, p, 160) { Mem = new AddressSpace(this, 13, 6); // 2600: 13bit, 64byte pages CPU = new M6502(this, 1); TIA = new TIA(this); for (ushort i = 0; i < 0x1000; i += 0x100) { Mem.Map(i, 0x0080, TIA); } PIA = new PIA(this); for (ushort i = 0x0080; i < 0x1000; i += 0x100) { Mem.Map(i, 0x0080, PIA); } Cart = cart; Mem.Map(0x1000, 0x1000, Cart); }
public Machine2600(Cart cart, ILogger logger, int slines, int startl, int fHZ, int sRate, int[] p) : base(logger, slines, startl, fHZ, sRate, p, 160) { Mem = new AddressSpace(this, 13, 6); // 2600: 13bit, 64byte pages CPU = new M6502(this, 1); TIA = new TIA(this); for (ushort i = 0; i < 0x1000; i += 0x100) { Mem.Map(i, 0x0080, TIA); } PIA = new PIA(this); for (ushort i = 0x0080; i < 0x1000; i += 0x100) { Mem.Map(i, 0x0080, PIA); } Cart = cart; Mem.Map(0x1000, 0x1000, Cart); }
// Memory viewer init public MemViewer(AddressSpace Mem) { InitializeComponent(); mem = Mem; // Setup drawing objects NormalFontBrush = new SolidBrush(Color.Black); NormalFont = new Font("Courier New", 10); // Setup bitmap gr = new System.Drawing.Bitmap(100, 100); g = Graphics.FromImage(gr); // Determine the size of the text SizeF size; size = g.MeasureString("00 ", NormalFont); LineHeight = (int)Math.Ceiling(size.Height); DataWidth = (int)Math.Ceiling(size.Width); size = g.MeasureString("0000:", NormalFont); AddrWidth = (int)Math.Ceiling(size.Width); }
public void Remove(AddressSpace parent, UserPtr startPage, UserPtr endPage) { Utils.Assert(Arch.ArchDefinition.PageOffset(startPage.Value.ToUInt32()) == 0); Utils.Assert(Arch.ArchDefinition.PageOffset(endPage.Value.ToUInt32()) == 0); for (var page = startPage; page < endPage; page += Arch.ArchDefinition.PageSize) { var directory_index = DirectoryIndex(page); var table_index = TableIndex(page); var table = Directory[directory_index]; if (table == null) continue; if (table[table_index] == Pointer.Zero) continue; FreePhysicalPage(table[table_index]); table[table_index] = Pointer.Zero; } Arch.NativeMethods.l4api_flush_regions(parent.impl._value, startPage.Value, endPage.Value, (int)MemoryRegion.FAULT_MASK); }
internal static List <AddressSpace> GetSenderDomainsFromString(string senderDomainString) { List <AddressSpace> list = new List <AddressSpace>(); if (!string.IsNullOrEmpty(senderDomainString)) { string[] array = senderDomainString.Split(new char[] { TenantInboundConnector.senderDomainsDelimiter }); foreach (string address in array) { AddressSpace item = null; if (!AddressSpace.TryParse(address, out item)) { return(new List <AddressSpace>()); } list.Add(item); } } return(list); }
///GENMHASH:2FE8C4C2D5EAD7E37787838DE0B47D92:8923589BAA698713A3D55DA89CCA0561 override protected NetworkImpl WrapModel(string name) { VirtualNetworkInner inner = new VirtualNetworkInner(); // Initialize address space AddressSpace addressSpace = inner.AddressSpace; if (addressSpace == null) { addressSpace = new AddressSpace(); inner.AddressSpace = addressSpace; } if (addressSpace.AddressPrefixes == null) { addressSpace.AddressPrefixes = new List <string>(); } // Initialize subnets if (inner.Subnets == null) { inner.Subnets = new List <SubnetInner>(); } // Initialize DHCP options (DNS servers) DhcpOptions dhcp = inner.DhcpOptions; if (dhcp == null) { dhcp = new DhcpOptions(); inner.DhcpOptions = dhcp; } if (dhcp.DnsServers == null) { dhcp.DnsServers = new List <string>(); } return(new NetworkImpl(name, inner, Manager)); }
internal VirtualNetworkGatewayData(ResourceIdentifier id, string name, ResourceType?resourceType, AzureLocation?location, IDictionary <string, string> tags, Models.ExtendedLocation extendedLocation, ETag?etag, IList <VirtualNetworkGatewayIPConfiguration> ipConfigurations, VirtualNetworkGatewayType?gatewayType, VpnType?vpnType, VpnGatewayGeneration?vpnGatewayGeneration, bool?enableBgp, bool?enablePrivateIPAddress, bool?active, WritableSubResource gatewayDefaultSite, VirtualNetworkGatewaySku sku, VpnClientConfiguration vpnClientConfiguration, BgpSettings bgpSettings, AddressSpace customRoutes, Guid?resourceGuid, NetworkProvisioningState?provisioningState, bool?enableDnsForwarding, string inboundDnsForwardingEndpoint, ResourceIdentifier vNetExtendedLocationResourceId, IList <VirtualNetworkGatewayNatRuleData> natRules, bool?enableBgpRouteTranslationForNat) : base(id, name, resourceType, location, tags) { ExtendedLocation = extendedLocation; Etag = etag; IPConfigurations = ipConfigurations; GatewayType = gatewayType; VpnType = vpnType; VpnGatewayGeneration = vpnGatewayGeneration; EnableBgp = enableBgp; EnablePrivateIPAddress = enablePrivateIPAddress; Active = active; GatewayDefaultSite = gatewayDefaultSite; Sku = sku; VpnClientConfiguration = vpnClientConfiguration; BgpSettings = bgpSettings; CustomRoutes = customRoutes; ResourceGuid = resourceGuid; ProvisioningState = provisioningState; EnableDnsForwarding = enableDnsForwarding; InboundDnsForwardingEndpoint = inboundDnsForwardingEndpoint; VNetExtendedLocationResourceId = vNetExtendedLocationResourceId; NatRules = natRules; EnableBgpRouteTranslationForNat = enableBgpRouteTranslationForNat; }
internal static void AdjustAddressSpaces(MailGateway connector) { if (MultiValuedPropertyBase.IsNullOrEmpty(connector.AddressSpaces)) { return; } MultiValuedProperty<AddressSpace> multiValuedProperty = new MultiValuedProperty<AddressSpace>(); foreach (AddressSpace addressSpace in connector.AddressSpaces) { if (addressSpace.IsLocal != connector.IsScopedConnector) { multiValuedProperty.Add(addressSpace); } } if (multiValuedProperty.Count > 0) { foreach (AddressSpace addressSpace2 in multiValuedProperty) { AddressSpace item = addressSpace2.ToggleScope(); connector.AddressSpaces.Remove(addressSpace2); connector.AddressSpaces.Add(item); } } }
internal static VpnSiteData DeserializeVpnSiteData(JsonElement element) { Optional <string> etag = default; Optional <string> id = default; Optional <string> name = default; Optional <string> type = default; Optional <string> location = default; Optional <IDictionary <string, string> > tags = default; Optional <WritableSubResource> virtualWan = default; Optional <DeviceProperties> deviceProperties = default; Optional <string> ipAddress = default; Optional <string> siteKey = default; Optional <AddressSpace> addressSpace = default; Optional <BgpSettings> bgpProperties = default; Optional <ProvisioningState> provisioningState = default; Optional <bool> isSecuritySite = default; Optional <IList <VpnSiteLinkData> > vpnSiteLinks = default; Optional <O365PolicyProperties> o365Policy = default; foreach (var property in element.EnumerateObject()) { if (property.NameEquals("etag")) { etag = property.Value.GetString(); continue; } if (property.NameEquals("id")) { id = property.Value.GetString(); continue; } if (property.NameEquals("name")) { name = property.Value.GetString(); continue; } if (property.NameEquals("type")) { type = property.Value.GetString(); continue; } if (property.NameEquals("location")) { location = property.Value.GetString(); continue; } if (property.NameEquals("tags")) { if (property.Value.ValueKind == JsonValueKind.Null) { property.ThrowNonNullablePropertyIsNull(); continue; } Dictionary <string, string> dictionary = new Dictionary <string, string>(); foreach (var property0 in property.Value.EnumerateObject()) { dictionary.Add(property0.Name, property0.Value.GetString()); } tags = dictionary; continue; } if (property.NameEquals("properties")) { if (property.Value.ValueKind == JsonValueKind.Null) { property.ThrowNonNullablePropertyIsNull(); continue; } foreach (var property0 in property.Value.EnumerateObject()) { if (property0.NameEquals("virtualWan")) { if (property0.Value.ValueKind == JsonValueKind.Null) { property0.ThrowNonNullablePropertyIsNull(); continue; } virtualWan = JsonSerializer.Deserialize <WritableSubResource>(property0.Value.ToString()); continue; } if (property0.NameEquals("deviceProperties")) { if (property0.Value.ValueKind == JsonValueKind.Null) { property0.ThrowNonNullablePropertyIsNull(); continue; } deviceProperties = DeviceProperties.DeserializeDeviceProperties(property0.Value); continue; } if (property0.NameEquals("ipAddress")) { ipAddress = property0.Value.GetString(); continue; } if (property0.NameEquals("siteKey")) { siteKey = property0.Value.GetString(); continue; } if (property0.NameEquals("addressSpace")) { if (property0.Value.ValueKind == JsonValueKind.Null) { property0.ThrowNonNullablePropertyIsNull(); continue; } addressSpace = AddressSpace.DeserializeAddressSpace(property0.Value); continue; } if (property0.NameEquals("bgpProperties")) { if (property0.Value.ValueKind == JsonValueKind.Null) { property0.ThrowNonNullablePropertyIsNull(); continue; } bgpProperties = BgpSettings.DeserializeBgpSettings(property0.Value); continue; } if (property0.NameEquals("provisioningState")) { if (property0.Value.ValueKind == JsonValueKind.Null) { property0.ThrowNonNullablePropertyIsNull(); continue; } provisioningState = new ProvisioningState(property0.Value.GetString()); continue; } if (property0.NameEquals("isSecuritySite")) { if (property0.Value.ValueKind == JsonValueKind.Null) { property0.ThrowNonNullablePropertyIsNull(); continue; } isSecuritySite = property0.Value.GetBoolean(); continue; } if (property0.NameEquals("vpnSiteLinks")) { if (property0.Value.ValueKind == JsonValueKind.Null) { property0.ThrowNonNullablePropertyIsNull(); continue; } List <VpnSiteLinkData> array = new List <VpnSiteLinkData>(); foreach (var item in property0.Value.EnumerateArray()) { array.Add(VpnSiteLinkData.DeserializeVpnSiteLinkData(item)); } vpnSiteLinks = array; continue; } if (property0.NameEquals("o365Policy")) { if (property0.Value.ValueKind == JsonValueKind.Null) { property0.ThrowNonNullablePropertyIsNull(); continue; } o365Policy = O365PolicyProperties.DeserializeO365PolicyProperties(property0.Value); continue; } } continue; } } return(new VpnSiteData(id.Value, name.Value, type.Value, location.Value, Optional.ToDictionary(tags), etag.Value, virtualWan, deviceProperties.Value, ipAddress.Value, siteKey.Value, addressSpace.Value, bgpProperties.Value, Optional.ToNullable(provisioningState), Optional.ToNullable(isSecuritySite), Optional.ToList(vpnSiteLinks), o365Policy.Value)); }
public void ReadFifo(AddressSpace bar, int barOffset, int length, byte[] data) { throw new NotImplementedException(); }
public int[] ArrayRead32(AddressSpace bar, int barOffset, int num32BitWords) { return(ArrayRead32(barOffset, num32BitWords)); }
public byte[] ArrayRead8(AddressSpace bar, int barOffset, int numBytes) { throw new NotImplementedException(); }
public void ArrayRead(AddressSpace bar, int barOffset, ref byte[] data8, int startIndex, int numBytes) { throw new NotImplementedException(); }
public Machine7800(Cart cart, Bios7800 bios, HSC7800 hsc, ILogger logger, int scanlines, int startl, int fHZ, int sRate, int[] p) : base(logger, scanlines, startl, fHZ, sRate, p, 320) { Mem = new AddressSpace(this, 16, 6); // 7800: 16bit, 64byte pages CPU = new M6502(this, 4); Maria = new Maria(this, scanlines); Mem.Map(0x0000, 0x0040, Maria); Mem.Map(0x0100, 0x0040, Maria); Mem.Map(0x0200, 0x0040, Maria); Mem.Map(0x0300, 0x0040, Maria); PIA = new PIA(this); Mem.Map(0x0280, 0x0080, PIA); Mem.Map(0x0480, 0x0080, PIA); Mem.Map(0x0580, 0x0080, PIA); RAM1 = new RAM6116(); RAM2 = new RAM6116(); Mem.Map(0x1800, 0x0800, RAM1); Mem.Map(0x2000, 0x0800, RAM2); Mem.Map(0x0040, 0x00c0, RAM2); // page 0 shadow Mem.Map(0x0140, 0x00c0, RAM2); // page 1 shadow Mem.Map(0x2800, 0x0800, RAM2); // shadow1 Mem.Map(0x3000, 0x0800, RAM2); // shadow2 Mem.Map(0x3800, 0x0800, RAM2); // shadow3 BIOS = bios; HSC = hsc; if (HSC != null) { Mem.Map(0x1000, 0x800, HSC.SRAM); Mem.Map(0x3000, 0x1000, HSC); Logger.WriteLine("7800 Highscore Cartridge Installed"); } Cart = cart; Mem.Map(0x4000, 0xc000, Cart); }