@{ /****************************************************************************** // Canary Islands Computer Museum Website // ---------------------------------------------------------------------------- // // Filename : Index.cshtml // Author(s) : Natalia Portillo // // --[ Description ] ---------------------------------------------------------- // // Index page (and news) // // --[ License ] -------------------------------------------------------------- // // This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as // published by the Free Software Foundation, either version 3 of the // License, or (at your option) any later version. // // This program is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. // // You should have received a copy of the GNU General Public License // along with this program. If not, see . // // ---------------------------------------------------------------------------- // Copyright © 2003-2018 Natalia Portillo *******************************************************************************/ // TODO: Resolutions ViewData["Title"] = "Computer"; } @using System.IO @using Cicm.Database @model Machine

@if(Model.Company.LastLogo != null && File.Exists(System.IO.Path.Combine(ViewBag.WebRootPath, "assets/logos", Model.Company.LastLogo.Guid + ".svg"))) { }

@if(Model.Introduced.Year == 1000) {
PROTOTYPE
} @Model.Company.Name @Model.Name @if(Model.Introduced.Year != 1000) { } @if(Model.Family != null) { } @if(Model.Model != null) { } @if(Model.Processors != null && Model.Processors.Length > 0) { } @if(Model.Memories != null && Model.Memories.Length > 0) { } @if(Model.Gpus != null && Model.Gpus.Length > 0) { } @if(Model.SoundSynths != null && Model.SoundSynths.Length > 0) { } @if(Model.Storage != null && Model.Storage.Length > 0) { }
Introduction date
@Model.Introduced.ToLongDateString()
Family
@Model.Family.Name
Model
@Model.Model
Processors
@for(int i = 0; i < Model.Processors.Length; i++) { if(Model.Processors[i] != null) { } }
@if(Model.Processors[i].Speed > 0) { @(Model.Processors[i].Processor.GprSize > 0 ? $"{Model.Processors[i].Processor.Name} @ {Model.Processors[i].Speed}Mhz ({Model.Processors[i].Processor.GprSize} bits)" : $"{Model.Processors[i].Processor.Name} @ {Model.Processors[i].Speed}Mhz") } else { @($"{Model.Processors[i].Processor.Name}") }
@if(Model.Processors[i].Processor.ModelCode != null && Model.Processors[i].Processor.ModelCode != Model.Processors[i].Processor.Name) { } @if(Model.Processors[i].Processor.Introduced != DateTime.MinValue) { } @if(Model.Processors[i].Processor.InstructionSet != null) { } @if(Model.Processors[i].Processor.Speed > 0) { } @if(Model.Processors[i].Processor.Gpr > 0 || Model.Processors[i].Processor.Fpr > 0 || Model.Processors[i].Processor.Simd > 0) { } @if(Model.Processors[i].Processor.Cores > 1) { } @if(Model.Processors[i].Processor.Cores > 1) { } @if(Model.Processors[i].Processor.DataBus > 0 || Model.Processors[i].Processor.AddressBus > 0) { } @if(Model.Processors[i].Processor.L1Instruction > 0 || Model.Processors[i].Processor.L1Data > 0 || Model.Processors[i].Processor.L2 > 0 || Model.Processors[i].Processor.L2 > 0) { } @if(Model.Processors[i].Processor.Package != null) { } @if(Model.Processors[i].Processor.Process != null || Model.Processors[i].Processor.ProcessNm > 0) { } @if(Model.Processors[i].Processor.DieSize > 0) { } @if(Model.Processors[i].Processor.Transistors > 0) { }
Model @Model.Processors[i].Processor.ModelCode
Manufacturer @Model.Processors[i].Processor.Company.Name
Introduction date @($"{Model.Processors[i].Processor.Introduced:yyyy}")
Instruction set @Model.Processors[i].Processor.InstructionSet.Name
Nominal speed @Model.Processors[i].Processor.Speed MHz
Registers @if(Model.Processors[i].Processor.Gpr > 0) { } @if(Model.Processors[i].Processor.Fpr > 0) { } @if(Model.Processors[i].Processor.Simd > 0) { }
@Model.Processors[i].Processor.Gpr general purpose registers of @Model.Processors[i].Processor.GprSize bits @if(Model.Processors[i].Processor.FprSize > 0 && Model.Processors[i].Processor.Fpr == 0) { @($", that can be used as floating point registers of {Model.Processors[i].Processor.FprSize}") } @if(Model.Processors[i].Processor.SimdSize > 0 && Model.Processors[i].Processor.Simd == 0) { @($", that can be used as SIMD registers of {Model.Processors[i].Processor.FprSize}") }
@Model.Processors[i].Processor.Fpr floating-point registers of @Model.Processors[i].Processor.FprSize bits @if(Model.Processors[i].Processor.SimdSize > 0 && Model.Processors[i].Processor.Simd == 0) { @($", that can be used as SIMD registers of {Model.Processors[i].Processor.FprSize}") }
@Model.Processors[i].Processor.Simd SIMDregisters of @Model.Processors[i].Processor.SimdSize bits
Multi-core @Model.Processors[i].Processor.Cores cores
SMT @Model.Processors[i].Processor.ThreadsPerCore threads @if(Model.Processors[i].Processor.Cores > 1) { @(" per core") }
Bus @if(Model.Processors[i].Processor.DataBus > 0) { } @if(Model.Processors[i].Processor.AddressBus > 0) { }
@Model.Processors[i].Processor.DataBus-bit data
@Model.Processors[i].Processor.AddressBus-bit address
Cache @if(Model.Processors[i].Processor.L1Instruction > 0) { } @if(Model.Processors[i].Processor.L1Data > 0) { } @if(Model.Processors[i].Processor.L2 > 0) { } @if(Model.Processors[i].Processor.L3 > 0) { }
@(Model.Processors[i].Processor.L1Data < 0 ? $"{Model.Processors[i].Processor.L1Instruction}KiB combined instruction-data L1" : $"{Model.Processors[i].Processor.L1Instruction}KiB instruction L1")
@($"{Model.Processors[i].Processor.L1Data}KiB data L1")
@($"{Model.Processors[i].Processor.L2}KiB L2")
@($"{Model.Processors[i].Processor.L3}KiB L3")
Package @Model.Processors[i].Processor.Package
Manufacturing process @if(Model.Processors[i].Processor.Process != null && Model.Processors[i].Processor.ProcessNm > 0) { @Model.Processors[i].Processor.Process @("@") @(Model.Processors[i].Processor.ProcessNm > 100 ? $"{Model.Processors[i].Processor.ProcessNm / 100}µm" : $"{Model.Processors[i].Processor.ProcessNm}nm") } else if(Model.Processors[i].Processor.ProcessNm > 0) { @(Model.Processors[i].Processor.ProcessNm > 100 ? $"{Model.Processors[i].Processor.ProcessNm / 100}µm" : $"{Model.Processors[i].Processor.ProcessNm}nm") } else { @Model.Processors[i].Processor.Process }
Die size @Model.Processors[i].Processor.DieSize mm²
Transistors @Model.Processors[i].Processor.Transistors
Memory
@foreach(MemoryByMachine memory in Model.Memories) { string memValue; if(memory.Size > 1073741824) { memValue = $"{memory.Size / 1073741824} GiB"; } else if(memory.Size > 1048576) { memValue = $"{memory.Size / 1048576} MiB"; } else if(memory.Size > 1024) { memValue = $"{memory.Size / 1024} KiB"; } else if(memory.Size > 0) { memValue = $"{memory.Size} bytes"; } else { memValue = "Unknown size"; } string speedValue; if(memory.Speed > 1000000000) { speedValue = $"{memory.Speed / 1000000000} GHz"; } else if(memory.Speed > 1000000) { speedValue = $"{memory.Speed / 1000000} MHz"; } else if(memory.Speed > 1000) { speedValue = $"{memory.Speed / 1000} KHz"; } else if(memory.Speed > 0) { speedValue = $"{memory.Speed} Hz"; } else { speedValue = "unknown speed"; } }
@memValue of @memory.Usage memory (@memory.Type at @speedValue)
Graphics processing units
@for(int i = 0; i < Model.Gpus.Length; i++) { if(Model.Gpus[i] != null) { if(Model.Gpus[i].Gpu.Id == -2) { } else { } } else { } }
Framebuffer
This computer directly draws pixels from software to a memory region that's converted to video output by a DAC or similar without using any specific graphics processing unit.
@($"{Model.Gpus[i].Gpu.Name}")
@if(Model.Gpus[i].Gpu.ModelCode != null && Model.Gpus[i].Gpu.ModelCode != Model.Gpus[i].Gpu.Name) { } @if(Model.Gpus[i].Gpu.Introduced != DateTime.MinValue) { } @if(Model.Gpus[i].Gpu.Package != null) { } @if(Model.Gpus[i].Gpu.Process != null || Model.Gpus[i].Gpu.ProcessNm > 0) { } @if(Model.Gpus[i].Gpu.DieSize > 0) { } @if(Model.Gpus[i].Gpu.Transistors > 0) { }
Model @Model.Gpus[i].Gpu.ModelCode
Manufacturer @Model.Gpus[i].Gpu.Company.Name
Introduction date @($"{Model.Gpus[i].Gpu.Introduced:yyyy}")
Package @Model.Gpus[i].Gpu.Package
Manufacturing process @if(Model.Gpus[i].Gpu.Process != null && Model.Gpus[i].Gpu.ProcessNm > 0) { @Model.Gpus[i].Gpu.Process @("@") @(Model.Gpus[i].Gpu.ProcessNm > 100 ? $"{Model.Gpus[i].Gpu.ProcessNm / 100}µm" : $"{Model.Gpus[i].Gpu.ProcessNm}nm") } else if(Model.Gpus[i].Gpu.ProcessNm > 0) { @(Model.Gpus[i].Gpu.ProcessNm > 100 ? $"{Model.Gpus[i].Gpu.ProcessNm / 100}µm" : $"{Model.Gpus[i].Gpu.ProcessNm}nm") } else { @Model.Gpus[i].Gpu.Process }
Die size @Model.Gpus[i].Gpu.DieSize mm²
Transistors @Model.Gpus[i].Gpu.Transistors
Unknown data
Sound synthetizers
@for(int i = 0; i < Model.SoundSynths.Length; i++) { @if(Model.SoundSynths[i] != null) { if(Model.SoundSynths[i].SoundSynth.Id == -2) { } else { } } else { } }
Software
This computer directly sends data to a DAC or similar connected to the audio output.
@($"{Model.SoundSynths[i].SoundSynth.Name}")
@if(Model.SoundSynths[i].SoundSynth.ModelCode != null && Model.SoundSynths[i].SoundSynth.ModelCode != Model.SoundSynths[i].SoundSynth.Name) { } @if(Model.SoundSynths[i].SoundSynth.Company != null) { } @if(Model.SoundSynths[i].SoundSynth.Introduced != DateTime.MinValue) { } @if(Model.SoundSynths[i].SoundSynth.Voices != 0 || Model.SoundSynths[i].SoundSynth.SquareWave != 0 || Model.SoundSynths[i].SoundSynth.WhiteNoise != 0) { } @if(Model.SoundSynths[i].SoundSynth.Depth != 0 || Model.SoundSynths[i].SoundSynth.Frequency > 0) { } @if(Model.SoundSynths[i].SoundSynth.Type != 0) { }
Model @Model.SoundSynths[i].SoundSynth.ModelCode
Manufacturer @Model.SoundSynths[i].SoundSynth.Company.Name
Introduction date @($"{Model.Gpus[i].Gpu.Introduced:yyyy}")
Generators @if(Model.SoundSynths[i].SoundSynth.Voices != 0) { } @if(Model.SoundSynths[i].SoundSynth.SquareWave != 0) { } @if(Model.SoundSynths[i].SoundSynth.WhiteNoise != 0) { }
@Model.SoundSynths[i].SoundSynth.Voices voices
@Model.SoundSynths[i].SoundSynth.SquareWave square wave
@Model.SoundSynths[i].SoundSynth.WhiteNoise white noise
Sample rate @if(Model.SoundSynths[i].SoundSynth.Depth != 0 && Model.SoundSynths[i].SoundSynth.Frequency > 0) { } else if(Model.SoundSynths[i].SoundSynth.Depth != 0) { } else { }
@Model.SoundSynths[i].SoundSynth.Depth bits at @(Model.SoundSynths[i].SoundSynth.Frequency > 1000 ? $"{Model.SoundSynths[i].SoundSynth.Frequency / 1000}KHz" : $"{Model.SoundSynths[i].SoundSynth.Frequency}Hz")
@Model.SoundSynths[i].SoundSynth.Depth bits
@(Model.SoundSynths[i].SoundSynth.Frequency > 1000 ? $"{Model.SoundSynths[i].SoundSynth.Frequency / 1000}KHz" : $"{Model.SoundSynths[i].SoundSynth.Frequency}Hz")
Synthetizer type @Model.SoundSynths[i].SoundSynth.Type
Unknown data
Storage
@foreach(StorageByMachine storage in Model.Storage) { string capString = null; if(storage.Capacity != 0) { if(storage.Type == StorageType.CompactCassette) { capString = $"{storage.Capacity} bps"; } else { if(storage.Capacity > 1073741824) { capString = $"{storage.Capacity / 1073741824} GiB"; } else if(storage.Capacity > 1048576) { capString = $"{storage.Capacity / 1048576} MiB"; } else if(storage.Capacity > 1024) { capString = $"{storage.Capacity / 1024} KiB"; } else if(storage.Capacity > 0) { capString = $"{storage.Capacity} bytes"; } else { capString = null; } } } @if(storage.Interface != StorageInterface.Unknown) { if(storage.Type == StorageType.Empty) { } else { if(capString != null) { } else { } } } else { if(capString != null) { } else { } } }
Available @storage.Interface interface.@storage.Type connected thru a @storage.Interface interface with a nominal capacity of @capString@storage.Type connected thru a @storage.Interface interface@storage.Type with a nominal capacity of @capString@storage.Type
@if(File.Exists(System.IO.Path.Combine(ViewBag.WebRootPath, "assets/photos/computers", Model.Id + ".jpg"))) { }