Update to v106r11 release.

byuu says:

Changelog:

  - genius: improve sorting when game name is identical (eg revisions)
  - icarus, genius: update to finalized manifest syntax
This commit is contained in:
Tim Allen 2018-03-14 14:51:35 +11:00
parent 2dd35f984d
commit 72b824cf1a
18 changed files with 9129 additions and 8624 deletions

View File

@ -127,17 +127,16 @@ auto ListWindow::loadDatabase(string location) -> void {
if(object.name() == "memory") {
component.type = Component::Type::Memory;
component.memory.type = object["type"].text();
component.memory.battery = (bool)object["type/battery"];
component.memory.size = object["size"].text();
component.memory.category = object["category"].text();
component.memory.manufacturer = object["manufacturer"].text();
component.memory.part = object["part"].text();
component.memory.note = object["note"].text();
component.memory.battery = (bool)object["type/battery"];
component.memory.model = object["model"].text();
component.memory.identity = object["identity"].text();
}
if(object.name() == "oscillator") {
component.type = Component::Type::Oscillator;
component.oscillator.frequency = object["frequency"].text();
component.oscillator.note = object["note"].text();
}
game.components.append(component);
}
@ -161,8 +160,8 @@ auto ListWindow::saveDatabase(string location) -> void {
auto copy = games;
copy.sort([](auto x, auto y) {
return string::icompare(
{x.name, " ", x.region, " ", x.revision},
{y.name, " ", y.region, " ", y.revision}
{x.name, "\n", x.region, "\n", x.revision},
{y.name, "\n", y.region, "\n", y.revision}
) < 0;
});
@ -171,14 +170,14 @@ auto ListWindow::saveDatabase(string location) -> void {
for(auto& game : copy) {
fp.print("game\n");
fp.print(" sha256: ", game.sha256, "\n");
fp.print(" sha256: ", game.sha256, "\n");
if(game.label)
fp.print(" label: ", game.label, "\n");
fp.print(" name: ", game.name, "\n");
fp.print(" region: ", game.region, "\n");
fp.print(" label: ", game.label, "\n");
fp.print(" name: ", game.name, "\n");
fp.print(" region: ", game.region, "\n");
fp.print(" revision: ", game.revision, "\n");
if(game.board)
fp.print(" board: ", game.board, "\n");
fp.print(" board: ", game.board, "\n");
else if(game.components)
fp.print(" board\n");
for(auto& component : game.components) {
@ -191,17 +190,15 @@ auto ListWindow::saveDatabase(string location) -> void {
fp.print(" category: ", component.memory.category, "\n");
if(component.memory.manufacturer)
fp.print(" manufacturer: ", component.memory.manufacturer, "\n");
if(component.memory.part)
fp.print(" part: ", component.memory.part, "\n");
if(component.memory.note)
fp.print(" note: ", component.memory.note, "\n");
if(component.memory.model)
fp.print(" model: ", component.memory.model, "\n");
if(component.memory.identity)
fp.print(" identity: ", component.memory.identity, "\n");
}
if(component.type == Component::Type::Oscillator) {
fp.print(" oscillator\n");
fp.print(" frequency: ", component.oscillator.frequency, "\n");
if(component.oscillator.note)
fp.print(" note: ", component.oscillator.note, "\n");
}
}
if(game.note)
@ -375,17 +372,15 @@ auto GameWindow::reloadList() -> void {
item.append(TreeViewItem().setText({"Category: ", component.memory.category}));
if(component.memory.manufacturer)
item.append(TreeViewItem().setText({"Manufacturer: ", component.memory.manufacturer}));
if(component.memory.part)
item.append(TreeViewItem().setText({"Part: ", component.memory.part}));
if(component.memory.note)
item.append(TreeViewItem().setText({"Note: ", component.memory.note}));
if(component.memory.model)
item.append(TreeViewItem().setText({"Model: ", component.memory.model}));
if(component.memory.identity)
item.append(TreeViewItem().setText({"Identity: ", component.memory.identity}));
}
if(component.type == Component::Type::Oscillator) {
item.setText({index, "Oscillator"});
item.append(TreeViewItem().setText({"Frequency: ", component.oscillator.frequency}));
if(component.oscillator.note)
item.append(TreeViewItem().setText({"Note: ", component.oscillator.note}));
}
componentTree.append(item);
@ -474,10 +469,10 @@ MemoryWindow::MemoryWindow() {
categoryEdit.onChange([&] { modified = true, updateWindow(); });
manufacturerLabel.setText("Manufacturer:").setAlignment(1.0);
manufacturerEdit.onChange([&] { modified = true, updateWindow(); });
partLabel.setText("Part:").setAlignment(1.0);
partEdit.onChange([&] { modified = true, updateWindow(); });
noteLabel.setText("Note:").setAlignment(1.0);
noteEdit.onChange([&] { modified = true, updateWindow(); });
modelLabel.setText("Model:").setAlignment(1.0);
modelEdit.onChange([&] { modified = true, updateWindow(); });
identityLabel.setText("Identity:").setAlignment(1.0);
identityEdit.onChange([&] { modified = true, updateWindow(); });
batteryOption.setText("Battery").onToggle([&] { modified = true, updateWindow(); });
acceptButton.setText("Accept").onActivate([&] { accept(); });
cancelButton.setText("Cancel").onActivate([&] { cancel(); });
@ -497,8 +492,8 @@ auto MemoryWindow::show(Memory memory) -> void {
sizeEdit.setText(memory.size);
categoryEdit.setText(memory.category);
manufacturerEdit.setText(memory.manufacturer);
partEdit.setText(memory.part);
noteEdit.setText(memory.note);
modelEdit.setText(memory.model);
identityEdit.setText(memory.identity);
batteryOption.setChecked(memory.battery);
updateWindow();
@ -513,8 +508,8 @@ auto MemoryWindow::accept() -> void {
memory.size = sizeEdit.text().strip();
memory.category = categoryEdit.text().strip();
memory.manufacturer = manufacturerEdit.text().strip();
memory.part = partEdit.text().strip();
memory.note = noteEdit.text().strip();
memory.model = modelEdit.text().strip();
memory.identity = identityEdit.text().strip();
memory.battery = batteryOption.checked() && (memory.type == "RAM" || memory.type == "RTC");
Component component{Component::Type::Memory};
@ -546,8 +541,8 @@ auto MemoryWindow::updateWindow() -> void {
sizeEdit.setBackgroundColor(sizeEdit.text().strip() ? Color{} : (valid = false, Color{255, 224, 224}));
categoryEdit.setBackgroundColor(categoryEdit.text().strip() ? Color{} : (valid = false, Color{255, 224, 224}));
manufacturerEdit.setBackgroundColor(manufacturerEdit.text().strip() ? Color{} : (Color{255, 255, 240}));
partEdit.setBackgroundColor(partEdit.text().strip() ? Color{} : (Color{255, 255, 240}));
noteEdit.setBackgroundColor(noteEdit.text().strip() ? Color{} : (Color{255, 255, 240}));
modelEdit.setBackgroundColor(modelEdit.text().strip() ? Color{} : (Color{255, 255, 240}));
identityEdit.setBackgroundColor(identityEdit.text().strip() ? Color{} : (Color{255, 255, 240}));
batteryOption.setEnabled(typeEdit.text().strip() == "RAM" || typeEdit.text().strip() == "RTC");
acceptButton.setEnabled(valid);
setTitle({modified ? "*" : "", create ? "Add New Memory" : "Modify Memory Details"});
@ -561,8 +556,6 @@ OscillatorWindow::OscillatorWindow() {
layout.setMargin(5);
frequencyLabel.setText("Frequency:").setAlignment(1.0);
frequencyEdit.onChange([&] { modified = true, updateWindow(); });
noteLabel.setText("Note:").setAlignment(1.0);
noteEdit.onChange([&] { modified = true, updateWindow(); });
acceptButton.setText("Accept").onActivate([&] { accept(); });
cancelButton.setText("Cancel").onActivate([&] { cancel(); });
@ -578,7 +571,6 @@ auto OscillatorWindow::show(Oscillator oscillator) -> void {
create = !oscillator.frequency;
frequencyEdit.setText(oscillator.frequency);
noteEdit.setText(oscillator.note);
updateWindow();
setCentered(*gameWindow);
@ -589,7 +581,6 @@ auto OscillatorWindow::show(Oscillator oscillator) -> void {
auto OscillatorWindow::accept() -> void {
oscillator.frequency = frequencyEdit.text().strip();
oscillator.note = noteEdit.text().strip();
Component component{Component::Type::Oscillator};
component.oscillator = oscillator;
@ -617,7 +608,6 @@ auto OscillatorWindow::cancel() -> void {
auto OscillatorWindow::updateWindow() -> void {
bool valid = true;
frequencyEdit.setBackgroundColor(frequencyEdit.text().strip() ? Color{} : (valid = false, Color{255, 224, 224}));
noteEdit.setBackgroundColor(noteEdit.text().strip() ? Color{} : (Color{255, 255, 240}));
acceptButton.setEnabled(valid);
setTitle({modified ? "*" : "", create ? "Add New Property" : "Modify Property Details"});
}

View File

@ -1,16 +1,15 @@
struct Memory {
string type;
boolean battery;
string size;
string category;
string manufacturer;
string part;
string note;
boolean battery;
string model;
string identity;
};
struct Oscillator {
string frequency;
string note;
};
//variant meta-class
@ -143,12 +142,12 @@ private:
HorizontalLayout manufacturerLayout{&layout, Size{~0, 0}};
Label manufacturerLabel{&manufacturerLayout, Size{80, 0}};
LineEdit manufacturerEdit{&manufacturerLayout, Size{~0, 0}};
HorizontalLayout partLayout{&layout, Size{~0, 0}};
Label partLabel{&partLayout, Size{80, 0}};
LineEdit partEdit{&partLayout, Size{~0, 0}};
HorizontalLayout noteLayout{&layout, Size{~0, 0}};
Label noteLabel{&noteLayout, Size{80, 0}};
LineEdit noteEdit{&noteLayout, Size{~0, 0}};
HorizontalLayout modelLayout{&layout, Size{~0, 0}};
Label modelLabel{&modelLayout, Size{80, 0}};
LineEdit modelEdit{&modelLayout, Size{~0, 0}};
HorizontalLayout identityLayout{&layout, Size{~0, 0}};
Label identityLabel{&identityLayout, Size{80, 0}};
LineEdit identityEdit{&identityLayout, Size{~0, 0}};
HorizontalLayout controlLayout{&layout, Size{~0, 0}};
Widget controlSpacer{&controlLayout, Size{~0, 0}};
CheckLabel batteryOption{&controlLayout, Size{0, 0}};
@ -172,9 +171,6 @@ private:
HorizontalLayout frequencyLayout{&layout, Size{~0, 0}};
Label frequencyLabel{&frequencyLayout, Size{60, 0}};
LineEdit frequencyEdit{&frequencyLayout, Size{~0, 0}};
HorizontalLayout noteLayout{&layout, Size{~0, 0}};
Label noteLabel{&noteLayout, Size{60, 0}};
LineEdit noteEdit{&noteLayout, Size{~0, 0}};
HorizontalLayout controlLayout{&layout, Size{~0, 0}};
Widget controlSpacer{&controlLayout, Size{~0, 0}};
Button acceptButton{&controlLayout, Size{80, 0}};

View File

@ -12,7 +12,7 @@ using namespace nall;
namespace Emulator {
static const string Name = "higan";
static const string Version = "106.10";
static const string Version = "106.11";
static const string Author = "byuu";
static const string License = "GPLv3";
static const string Website = "https://byuu.org/";

View File

@ -1,5 +1,5 @@
database
revision: 2018-03-04
revision: 2018-03-13
//Boards (Production)

View File

@ -1,5 +1,5 @@
database
revision: 2018-03-01
revision: 2018-03-13
//BS Memory (JPN)
@ -8,37 +8,37 @@ database
game
sha256: 80c34b50817d58820bc8c88d2d9fa462550b4a76372e19c6467cbfbc8cf5d9ef
label: 鮫亀 キャラカセット
name: Same Game - Chara Cassette
region: BSMC-ZS5J-JPN
revision: BSMC-ZS5J-0
board: BSMC-CR-01
name: Same Game - Chara Cassette
label: 鮫亀 キャラカセット
memory
type: ROM
size: 0x80000
name: program.rom
memory
type: ROM
size: 0x80000
category: Program
game
sha256: 859c7f7b4771d920a5bdb11f1d247ab6b43fb026594d1062f6f72d32cd340a0a
label: 鮫亀 キャラデータ集
name: Same Game - Chara Data Shuu
region: BSMC-YS5J-JPN
revision: BSMC-YS5J-0
board: BSMC-CR-01
name: Same Game - Chara Data Shuu
label: 鮫亀 キャラデータ集
memory
type: ROM
size: 0x80000
name: program.rom
memory
type: ROM
size: 0x80000
category: Program
game
sha256: c92a15fdd9b0133f9ea69105d0230a3acd1cdeef98567462eca86ea02a959e4e
label: SDガンダム ジーネクスト ユニット&マップコレクション
name: SD Gundam G Next - Unit & Map Collection
region: BSMC-ZX3J-JPN
revision: BSMC-ZX3J-0
board: BSMC-BR-01
name: SD Gundam G Next - Unit & Map Collection
label: SDガンダム ジーネクスト ユニット&マップコレクション
memory
type: ROM
size: 0x80000
name: program.rom
memory
type: ROM
size: 0x80000
category: Program

View File

@ -1,5 +1,5 @@
database
revision: 2018-03-01
revision: 2018-03-13
//Sufami Turbo (JPN)
@ -8,206 +8,215 @@ database
game
sha256: f73bda08743565e0bd101632ebbac2d363d703a3ab39d23f49d95217cab29269
label: 美少女戦士セーラームーン セーラースターズ ふわふわパニック2
name: Bishoujo Senshi Sailor Moon Sailor Stars - Fuwafuwa Panic 2
region: SFT-0112-JPN
revision: SAILOR MOON
board: PT-911
name: Bishoujo Senshi Sailor Moon Sailor Stars - Fuwafuwa Panic 2
label: 美少女戦士セーラームーン セーラースターズ ふわふわパニック2
note: Unlinkable
memory
type: ROM
size: 0x100000
name: program.rom
memory
type: ROM
size: 0x100000
category: Program
note: Unlinkable
game
sha256: afb3f2a83b5bfcb1b8829b6995f108cc4d64ca322d1ba4a50b83af6e1f2e89bd
label: クレヨンしんちゃん 長ぐつドボン!!
name: Crayon Shin-chan - Nagagutsu Dobon!!
region: SFT-0113-JPN
revision: SHINCYAN
board: PT-911
name: Crayon Shin-chan - Nagagutsu Dobon!!
label: クレヨンしんちゃん 長ぐつドボン!!
note: Unlinkable
memory
type: ROM
size: 0x80000
name: program.rom
memory
type: ROM
size: 0x80000
category: Program
note: Unlinkable
game
sha256: d93b3a570e7cf343f680ab0768a50b77e3577f9c555007e2de3decd6bc4765c8
label: ゲゲゲの鬼太郎 妖怪ドンジャラ
name: Gegege no Kitarou - Youkai Donjara
region: SFT-0106-JPN
revision: KITARO DONJYAR
board: PT-911
name: Gegege no Kitarou - Youkai Donjara
label: ゲゲゲの鬼太郎 妖怪ドンジャラ
note: Unlinkable
memory
type: ROM
size: 0x80000
name: program.rom
memory
type: ROM
size: 0x80000
category: Program
note: Unlinkable
game
sha256: 89aecd4e23d8219c8de3e71bb75db3dfe667d51c1eba4ea7239d2f772743d0cc
label: 激走戦隊カーレンジャ 全開!レーサー戦士
name: Gekisou Sentai Carranger - Zenkai! Racer Senshi
region: SFT-0109-JPN
revision: CAR RANGER
board: PT-911
name: Gekisou Sentai Carranger - Zenkai! Racer Senshi
label: 激走戦隊カーレンジャ 全開!レーサー戦士
note: Unlinkable
memory
type: ROM
size: 0x80000
name: program.rom
memory
type: ROM
size: 0x80000
category: Program
note: Unlinkable
game
sha256: 602b20b788640f5743487108a10f3f77bca5ce2d24208b25b1ca498a96eb0d69
label: ぽいぽい忍者ワールド
name: Poi Poi Ninja World
region: SFT-0103-JPN
revision: POI POI NINJYA
board: PT-911
name: Poi Poi Ninja World
label: ぽいぽい忍者ワールド
note: Linkable: SFT-0103-JPN
memory
type: ROM
size: 0x80000
name: program.rom
memory
type: NVRAM
size: 0x800
name: save.ram
memory
type: ROM
size: 0x80000
category: Program
memory
type: RAM
battery
size: 0x800
category: Save
note: Linkable: SFT-0103-JPN
game
sha256: 2a9d7c9a61318861028a73ca03e32a48cff162d76cba36fbaab8690b212efe9b
label: SDガンダムジェネレーション アクシズ戦記
name: SD Gundam Generation - Axis Senki
region: SFT-0107-JPN
revision: GUNDAM C
board: PT-912
name: SD Gundam Generation - Axis Senki
label: SDガンダムジェネレーション アクシズ戦記
note: Linkable: SFT-0104-JPN, SFT-0105-JPN, SFT-0107-JPN, SFT-0108-JPN, SFT-0110-JPN, SFT-0111-JPN
memory
type: ROM
size: 0x80000
name: program.rom
memory
type: NVRAM
size: 0x2000
name: save.ram
memory
type: ROM
size: 0x80000
category: Program
memory
type: RAM
battery
size: 0x2000
category: Save
note: Linkable: SFT-0104-JPN, SFT-0105-JPN, SFT-0107-JPN, SFT-0108-JPN, SFT-0110-JPN, SFT-0111-JPN
game
sha256: 60ac017c18f534e8cf24ca7f38e22ce92db95ea6c30b2d59d76f13c4f1c8a6e4
label: SDガンダムジェネレーション バビロニア建国戦記
name: SD Gundam Generation - Babylonia Kenkoku Senki
region: SFT-0108-JPN
revision: GUNDAM D
board: PT-912
name: SD Gundam Generation - Babylonia Kenkoku Senki
label: SDガンダムジェネレーション バビロニア建国戦記
note: Linkable: SFT-0104-JPN, SFT-0105-JPN, SFT-0107-JPN, SFT-0108-JPN, SFT-0110-JPN, SFT-0111-JPN
memory
type: ROM
size: 0x80000
name: program.rom
memory
type: NVRAM
size: 0x2000
name: save.ram
memory
type: ROM
size: 0x80000
category: Program
memory
type: RAM
battery
size: 0x2000
category: Save
note: Linkable: SFT-0104-JPN, SFT-0105-JPN, SFT-0107-JPN, SFT-0108-JPN, SFT-0110-JPN, SFT-0111-JPN
game
sha256: e639b5d5d722432b6809ccc6801dc584e1a3016379f34b335ed2dfa73b1ebf69
label: SDガンダムジェネレーション コロニー格闘記
name: SD Gundam Generation - Colony Kakutouki
region: SFT-0111-JPN
revision: GUNDAM F
board: PT-912
name: SD Gundam Generation - Colony Kakutouki
label: SDガンダムジェネレーション コロニー格闘記
note: Linkable: SFT-0104-JPN, SFT-0105-JPN, SFT-0107-JPN, SFT-0108-JPN, SFT-0110-JPN, SFT-0111-JPN
memory
type: ROM
size: 0x80000
name: program.rom
memory
type: NVRAM
size: 0x2000
name: save.ram
memory
type: ROM
size: 0x80000
category: Program
memory
type: RAM
battery
size: 0x2000
category: Save
note: Linkable: SFT-0104-JPN, SFT-0105-JPN, SFT-0107-JPN, SFT-0108-JPN, SFT-0110-JPN, SFT-0111-JPN
game
sha256: 8547a08ed11fe408eac282a90ac46654bd2e5f49bda3aec8e5edf166a0a4b9af
label: SDガンダムジェネレーション グリプス戦記
name: SD Gundam Generation - Gryps Senki
region: SFT-0105-JPN
revision: GUNDAM B
board: PT-912
name: SD Gundam Generation - Gryps Senki
label: SDガンダムジェネレーション グリプス戦記
note: Linkable: SFT-0104-JPN, SFT-0105-JPN, SFT-0107-JPN, SFT-0108-JPN, SFT-0110-JPN, SFT-0111-JPN
memory
type: ROM
size: 0x80000
name: program.rom
memory
type: NVRAM
size: 0x2000
name: save.ram
memory
type: ROM
size: 0x80000
category: Program
memory
type: RAM
battery
size: 0x2000
category: Save
note: Linkable: SFT-0104-JPN, SFT-0105-JPN, SFT-0107-JPN, SFT-0108-JPN, SFT-0110-JPN, SFT-0111-JPN
game
sha256: 3e82215bed08274874b30d461fc4a965c6bca932229da5d46d56e36f484d65eb
label: SDガンダムジェネレーション 一年戦争記
name: SD Gundam Generation - Ichinen Sensouki
region: SFT-0104-JPN
revision: GUNDAM A
board: PT-912
name: SD Gundam Generation - Ichinen Sensouki
label: SDガンダムジェネレーション 一年戦争記
note: Linkable: SFT-0104-JPN, SFT-0105-JPN, SFT-0107-JPN, SFT-0108-JPN, SFT-0110-JPN, SFT-0111-JPN
memory
type: ROM
size: 0x80000
name: program.rom
memory
type: NVRAM
size: 0x2000
name: save.ram
memory
type: ROM
size: 0x80000
category: Program
memory
type: RAM
battery
size: 0x2000
category: Save
note: Linkable: SFT-0104-JPN, SFT-0105-JPN, SFT-0107-JPN, SFT-0108-JPN, SFT-0110-JPN, SFT-0111-JPN
game
sha256: 5951a58a91d8e397d0a237ccc2b1248e17c7312cb9cc11cbc350200a97b4e021
label: SDガンダムジェネレーション ザンスカール戦記
name: SD Gundam Generation - Zanscare Senki
region: SFT-0110-JPN
revision: GUNDAM E
board: PT-912
name: SD Gundam Generation - Zanscare Senki
label: SDガンダムジェネレーション ザンスカール戦記
note: Linkable: SFT-0104-JPN, SFT-0105-JPN, SFT-0107-JPN, SFT-0108-JPN, SFT-0110-JPN, SFT-0111-JPN
memory
type: ROM
size: 0x80000
name: program.rom
memory
type: NVRAM
size: 0x2000
name: save.ram
memory
type: ROM
size: 0x80000
category: Program
memory
type: RAM
battery
size: 0x2000
category: Save
note: Linkable: SFT-0104-JPN, SFT-0105-JPN, SFT-0107-JPN, SFT-0108-JPN, SFT-0110-JPN, SFT-0111-JPN
game
sha256: 2fec5f2bc7dee010af10569a3d2bc18715a79a126940800c3eade5abbd625e3f
label: SDウルトラバトル セブン伝説
name: SD Ultra Battle - Seven Densetsu
region: SFT-0102-JPN
revision: ULTRA SEVEN 1
board: PT-911
name: SD Ultra Battle - Seven Densetsu
label: SDウルトラバトル セブン伝説
note: Linkable: SFT-0101-JPN, SFT-0102-JPN
memory
type: ROM
size: 0x80000
name: program.rom
memory
type: NVRAM
size: 0x800
name: save.ram
memory
type: ROM
size: 0x80000
category: Program
memory
type: RAM
battery
size: 0x800
category: Save
note: Linkable: SFT-0101-JPN, SFT-0102-JPN
game
sha256: 2bb55214fb668ca603d7b944b14f105dfb10b987a8902d420fe4ae1cb69c1d4a
label: SDウルトラバトル ウルトラマン伝説
name: SD Ultra Battle - Ultraman Densetsu
region: SFT-0101-JPN
revision: ULTRA MAN 1
board: PT-911
name: SD Ultra Battle - Ultraman Densetsu
label: SDウルトラバトル ウルトラマン伝説
note: Linkable: SFT-0101-JPN, SFT-0102-JPN
memory
type: ROM
size: 0x80000
name: program.rom
memory
type: NVRAM
size: 0x800
name: save.ram
memory
type: ROM
size: 0x80000
category: Program
memory
type: RAM
battery
size: 0x800
category: Save
note: Linkable: SFT-0101-JPN, SFT-0102-JPN

File diff suppressed because it is too large Load Diff

View File

@ -23,8 +23,8 @@ auto BSMemory::manifest() const -> string {
string output;
output.append("game\n");
output.append(" sha256: ", Hash::SHA256(data).digest(), "\n");
output.append(" label: ", Location::prefix(location), "\n");
output.append(" name: ", Location::prefix(location), "\n");
output.append(" label: ", Location::prefix(location), "\n");
output.append(" name: ", Location::prefix(location), "\n");
output.append(" board\n");
output.append(Memory{}.type("Flash").size(data.size()).category("Program").text());
return output;

View File

@ -35,66 +35,66 @@ auto Famicom::manifest() const -> string {
string output;
output.append("game\n");
output.append(" sha256: ", Hash::SHA256(&data[16], data.size() - 16).digest(), "\n");
output.append(" label: ", Location::prefix(location), "\n");
output.append(" name: ", Location::prefix(location), "\n");
output.append(" label: ", Location::prefix(location), "\n");
output.append(" name: ", Location::prefix(location), "\n");
switch(mapper) {
default:
output.append(" board: NES-NROM-256\n");
output.append(" board: NES-NROM-256\n");
output.append(" mirror mode=", mirror == 0 ? "horizontal" : "vertical", "\n");
break;
case 1:
output.append(" board: NES-SXROM\n");
output.append(" board: NES-SXROM\n");
output.append(" chip type=MMC1B2\n");
prgram = 8192;
break;
case 2:
output.append(" board: NES-UOROM\n");
output.append(" board: NES-UOROM\n");
output.append(" mirror mode=", mirror == 0 ? "horizontal" : "vertical", "\n");
break;
case 3:
output.append(" board: NES-CNROM\n");
output.append(" board: NES-CNROM\n");
output.append(" mirror mode=", mirror == 0 ? "horizontal" : "vertical", "\n");
break;
case 4:
//MMC3
output.append(" board: NES-TLROM\n");
output.append(" board: NES-TLROM\n");
output.append(" chip type=MMC3B\n");
prgram = 8192;
//MMC6
//output.append(" board: NES-HKROM\n");
//output.append(" board: NES-HKROM\n");
//output.append(" chip type=MMC6\n");
//prgram = 1024;
break;
case 5:
output.append(" board: NES-ELROM\n");
output.append(" board: NES-ELROM\n");
output.append(" chip type=MMC5\n");
prgram = 65536;
break;
case 7:
output.append(" board: NES-AOROM\n");
output.append(" board: NES-AOROM\n");
break;
case 9:
output.append(" board: NES-PNROM\n");
output.append(" board: NES-PNROM\n");
output.append(" chip type=MMC2\n");
prgram = 8192;
break;
case 10:
output.append(" board: NES-FKROM\n");
output.append(" board: NES-FKROM\n");
output.append(" chip type=MMC4\n");
prgram = 8192;
break;
case 16:
output.append(" board: BANDAI-FCG\n");
output.append(" board: BANDAI-FCG\n");
output.append(" chip type=LZ93D50\n");
break;
@ -102,7 +102,7 @@ auto Famicom::manifest() const -> string {
case 23:
case 25:
//VRC4
output.append(" board: KONAMI-VRC-4\n");
output.append(" board: KONAMI-VRC-4\n");
output.append(" chip type=VRC4\n");
output.append(" pinout a0=1 a1=0\n");
prgram = 8192;
@ -110,52 +110,52 @@ auto Famicom::manifest() const -> string {
case 22:
//VRC2
output.append(" board: KONAMI-VRC-2\n");
output.append(" board: KONAMI-VRC-2\n");
output.append(" chip type=VRC2\n");
output.append(" pinout a0=0 a1=1\n");
break;
case 24:
output.append(" board: KONAMI-VRC-6\n");
output.append(" board: KONAMI-VRC-6\n");
output.append(" chip type=VRC6\n");
break;
case 26:
output.append(" board: KONAMI-VRC-6\n");
output.append(" board: KONAMI-VRC-6\n");
output.append(" chip type=VRC6\n");
prgram = 8192;
break;
case 34:
output.append(" board: NES-BNROM\n");
output.append(" board: NES-BNROM\n");
output.append(" mirror mode=", mirror == 0 ? "horizontal" : "vertical", "\n");
break;
case 66:
output.append(" board: NES-GNROM\n");
output.append(" board: NES-GNROM\n");
output.append(" mirror mode=", mirror == 0 ? "horizontal" : "vertical", "\n");
break;
case 69:
output.append(" board: SUNSOFT-5B\n");
output.append(" board: SUNSOFT-5B\n");
output.append(" chip type=5B\n");
prgram = 8192;
break;
case 73:
output.append(" board: KONAMI-VRC-3\n");
output.append(" board: KONAMI-VRC-3\n");
output.append(" chip type=VRC3\n");
output.append(" mirror mode=", mirror == 0 ? "horizontal" : "vertical", "\n");
prgram = 8192;
break;
case 75:
output.append(" board: KONAMI-VRC-1\n");
output.append(" board: KONAMI-VRC-1\n");
output.append(" chip type=VRC1\n");
break;
case 85:
output.append(" board: KONAMI-VRC-7\n");
output.append(" board: KONAMI-VRC-7\n");
output.append(" chip type=VRC7\n");
prgram = 8192;
break;

View File

@ -238,9 +238,9 @@ auto GameBoy::manifest() const -> string {
string output;
output.append("game\n");
output.append(" sha256: ", Hash::SHA256(data).digest(), "\n");
output.append(" label: ", Location::prefix(location), "\n");
output.append(" name: ", Location::prefix(location), "\n");
output.append(" board: ", mapper, "\n");
output.append(" label: ", Location::prefix(location), "\n");
output.append(" name: ", Location::prefix(location), "\n");
output.append(" board: ", mapper, "\n");
output.append(Memory{}.type("ROM").size(data.size()).category("Program").text());
if(ram && ramSize)
output.append(Memory{}.type("RAM").size(ramSize).category("Save").battery(battery).text());

View File

@ -21,8 +21,8 @@ auto GameGear::manifest() const -> string {
string output;
output.append("game\n");
output.append(" sha256: ", Hash::SHA256(data).digest(), "\n");
output.append(" label: ", Location::prefix(location), "\n");
output.append(" name: ", Location::prefix(location), "\n");
output.append(" label: ", Location::prefix(location), "\n");
output.append(" name: ", Location::prefix(location), "\n");
output.append(" board\n");
output.append(Memory{}.type("ROM").size(data.size()).category("Program").text());
output.append(Memory{}.type("RAM").size(0x8000).category("Save").battery().text());

View File

@ -10,10 +10,10 @@ if(_battery)
output.append(" category: ", _category, "\n");
if(_manufacturer)
output.append(" manufacturer: ", _manufacturer, "\n");
if(_part)
output.append(" part: ", _part, "\n");
if(_note)
output.append(" note: ", _note, "\n");
if(_model)
output.append(" model: ", _model, "\n");
if(_identity)
output.append(" identity: ", _identity, "\n");
return output;
}
@ -21,8 +21,6 @@ auto Oscillator::text() const -> string {
string output;
output.append(" oscillator\n");
output.append(" frequency: ", _frequency, "\n");
if(_note)
output.append(" note: ", _note, "\n");
return output;
}

View File

@ -6,8 +6,8 @@ struct Memory {
auto& size(natural size) { _size = size; return *this; }
auto& category(string category) { _category = category; return *this; }
auto& manufacturer(string manufacturer) { _manufacturer = manufacturer; return *this; }
auto& part(string part) { _part = part; return *this; }
auto& note(string note) { _note = note; return *this; }
auto& model(string model) { _model = model; return *this; }
auto& identity(string identity) { _identity = identity; return *this; }
auto text() const -> string;
string _type;
@ -15,17 +15,15 @@ struct Memory {
natural _size;
string _category;
string _manufacturer;
string _part;
string _note;
string _model;
string _identity;
};
struct Oscillator {
auto& frequency(natural frequency) { _frequency = frequency; return *this; }
auto& note(string note) { _note = note; return *this; }
auto text() const -> string;
natural _frequency;
string _note;
};
}

View File

@ -21,8 +21,8 @@ auto MasterSystem::manifest() const -> string {
string output;
output.append("game\n");
output.append(" sha256: ", Hash::SHA256(data).digest(), "\n");
output.append(" label: ", Location::prefix(location), "\n");
output.append(" name: ", Location::prefix(location), "\n");
output.append(" label: ", Location::prefix(location), "\n");
output.append(" name: ", Location::prefix(location), "\n");
output.append(" board\n");
output.append(Memory{}.type("ROM").size(data.size()).category("Program").text());
output.append(Memory{}.type("RAM").size(0x8000).category("Save").battery().text());

View File

@ -71,8 +71,8 @@ auto MegaDrive::manifest() const -> string {
string output;
output.append("game\n");
output.append(" sha256: ", Hash::SHA256(data).digest(), "\n");
output.append(" label: ", Location::prefix(location), "\n");
output.append(" name: ", Location::prefix(location), "\n");
output.append(" label: ", Location::prefix(location), "\n");
output.append(" name: ", Location::prefix(location), "\n");
output.append(" region: ", regions.left(), "\n");
output.append(" board\n");
output.append(Memory{}.type("ROM").size(data.size()).category("Program").text());

View File

@ -26,8 +26,8 @@ auto PCEngine::manifest() const -> string {
string output;
output.append("game\n");
output.append(" sha256: ", Hash::SHA256(data).digest(), "\n");
output.append(" label:", Location::prefix(location), "\n");
output.append(" name: ", Location::prefix(location), "\n");
output.append(" label: ", Location::prefix(location), "\n");
output.append(" name: ", Location::prefix(location), "\n");
output.append(" board\n");
output.append(Memory{}.type("ROM").size(data.size()).category("Program").text());
return output;

View File

@ -57,12 +57,12 @@ auto SuperFamicom::manifest() const -> string {
string output;
output.append("game\n");
output.append(" sha256: ", Hash::SHA256(data).digest(), "\n");
output.append(" label: ", label(), "\n");
output.append(" name: ", Location::prefix(location), "\n");
output.append(" region: ", region(), "\n");
output.append(" sha256: ", Hash::SHA256(data).digest(), "\n");
output.append(" label: ", label(), "\n");
output.append(" name: ", Location::prefix(location), "\n");
output.append(" region: ", region(), "\n");
output.append(" revision: ", revision(), "\n");
output.append(" board: ", board(), "\n");
output.append(" board: ", board(), "\n");
auto board = this->board().split("-");
@ -76,38 +76,38 @@ auto SuperFamicom::manifest() const -> string {
}
if(auto size = expansionRamSize()) {
output.append(Memory{}.type("RAM").size(size).category("Expansion").battery(battery()).text());
output.append(Memory{}.type("RAM").size(size).category("Save").battery(battery()).text());
}
if(0) {
} else if(board(0) == "ARM") {
output.append(Memory{}.type("ROM").size(0x20000).manufacturer("SETA").part("ARM").category("Program").text());
output.append(Memory{}.type("ROM").size( 0x8000).manufacturer("SETA").part("ARM").category("Data").text());
output.append(Memory{}.type("RAM").size( 0x4000).manufacturer("SETA").part("ARM").category("Data").text());
output.append(Memory{}.type("ROM").size(0x20000).category("Program").manufacturer("SETA").model("ARM6").identity(firmwareARM()).text());
output.append(Memory{}.type("ROM").size( 0x8000).category("Data" ).manufacturer("SETA").model("ARM6").identity(firmwareARM()).text());
output.append(Memory{}.type("RAM").size( 0x4000).category("Data" ).manufacturer("SETA").model("ARM6").identity(firmwareARM()).text());
output.append(Oscillator{}.frequency(21'440'000).text());
} else if(board(0) == "BS" && board(1) == "MCC") {
output.append(Memory{}.type("RAM").size(0x80000).category("Download").battery().text());
output.append(Memory{}.type("RTC").size(0x10).category("Time").text());
} else if(board(0) == "HITACHI") {
output.append(Memory{}.type("ROM").size(0xc00).manufacturer("Hitachi").part("HG51BS169").category("Data").note(firmwareHITACHI()).text());
output.append(Memory{}.type("RAM").size(0xc00).manufacturer("Hitachi").part("HG51BS169").category("Data").note(firmwareHITACHI()).text());
output.append(Memory{}.type("ROM").size(0xc00).category("Data").manufacturer("Hitachi").model("HG51BS169").identity(firmwareHITACHI()).text());
output.append(Memory{}.type("RAM").size(0xc00).category("Data").manufacturer("Hitachi").model("HG51BS169").identity(firmwareHITACHI()).text());
output.append(Oscillator{}.frequency(20'000'000).text());
} else if(board(0) == "NEC") {
output.append(Memory{}.type("ROM").size(0x1800).manufacturer("NEC").part("uPD7725").category("Program").note(firmwareNEC()).text());
output.append(Memory{}.type("ROM").size( 0x800).manufacturer("NEC").part("uPD7725").category("Data").note(firmwareNEC()).text());
output.append(Memory{}.type("RAM").size( 0x200).manufacturer("NEC").part("uPD7725").category("Data").note(firmwareNEC()).text());
output.append(Memory{}.type("ROM").size(0x1800).category("Program").manufacturer("NEC").model("uPD7725").identity(firmwareNEC()).text());
output.append(Memory{}.type("ROM").size( 0x800).category("Data" ).manufacturer("NEC").model("uPD7725").identity(firmwareNEC()).text());
output.append(Memory{}.type("RAM").size( 0x200).category("Data" ).manufacturer("NEC").model("uPD7725").identity(firmwareNEC()).text());
output.append(Oscillator{}.frequency(7'600'000).text());
} else if(board(0) == "NECEX") {
output.append(Memory{}.type("ROM").size(0xc000).manufacturer("NEC").part("uPD96050").category("Program").note(firmwareNECEX()).text());
output.append(Memory{}.type("ROM").size(0x1000).manufacturer("NEC").part("uPD96050").category("Data").note(firmwareNECEX()).text());
output.append(Memory{}.type("RAM").size(0x1000).manufacturer("NEC").part("uPD96050").category("Data").note(firmwareNECEX()).text());
output.append(Memory{}.type("ROM").size(0xc000).category("Program").manufacturer("NEC").model("uPD96050").identity(firmwareNECEX()).text());
output.append(Memory{}.type("ROM").size(0x1000).category("Data" ).manufacturer("NEC").model("uPD96050").identity(firmwareNECEX()).text());
output.append(Memory{}.type("RAM").size(0x1000).category("Data" ).manufacturer("NEC").model("uPD96050").identity(firmwareNECEX()).text());
output.append(Oscillator{}.frequency(firmwareNECEX() == "ST010" ? 11'000'000 : 15'000'000).text());
} else if(board(0) == "RTC") {
output.append(Memory{}.type("RTC").size(0x10).category("Time").battery().text());
} else if(board(0) == "SA1") {
output.append(Memory{}.type("RAM").size(0x800).category("Internal").text());
} else if(board(0) == "SGB") {
output.append(Memory{}.type("ROM").size(0x100).manufacturer("Nintendo").part("SGB").category("Boot").note(firmwareSGB()).text());
string model = firmwareSGB() == "SGB1" ? "DMG" : "MGB";
output.append(Memory{}.type("ROM").size(0x100).category("Boot").manufacturer("Nintendo").model(model).identity(firmwareSGB()).text());
if(firmwareSGB() == "SGB2")
output.append(Oscillator{}.frequency(20'971'520).text());
} else if(board(0) == "SPC7110") {

View File

@ -21,8 +21,8 @@ auto SuperGrafx::manifest() const -> string {
string output;
output.append("game\n");
output.append(" sha256: ", Hash::SHA256(data).digest(), "\n");
output.append(" label: ", Location::prefix(location), "\n");
output.append(" name: ", Location::prefix(location), "\n");
output.append(" label: ", Location::prefix(location), "\n");
output.append(" name: ", Location::prefix(location), "\n");
output.append(" board\n");
output.append(Memory{}.type("ROM").size(data.size()).category("Program").text());
return output;