Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

ゼロから始めるファミコンエミュレータ生活 PHPerKaigi2019

4,570 views

Published on

PHPerKaigi2019の発表資料。ファミコンエミュレータの実装を通して好きな言語でコンピュータアーキテクチャが学べる話

Published in: Technology
  • Be the first to comment

ゼロから始めるファミコンエミュレータ生活 PHPerKaigi2019

  1. 1. ▸ @cakephper ▸ ▸ ▸ VAddy: ▸ Scutum: Web Application Firewall
  2. 2. (NES) ▸ CPU: RP2A03, 1.79MHz, 8bit ▸ PPU: RP2C02, 5.37MHz ▸ RAM: 2KB ▸ VRAM: 2KB ▸ Program ROM: 32KB ▸ Character ROM: 8KB
  3. 3. GOAAAAAL ▸ ▸
  4. 4. ▸ (CPU, Memory, etc) ▸ ▸ OS
  5. 5. PHP NES EMULATOR ▸ PHP ▸ Go ▸ 30
  6. 6. (PHP) PHP
  7. 7. PROS/CONS PHP, JS, RUST, GOLANG … ▸ ▸
  8. 8. PROS/CONS PHP, JS, RUST, GOLANG … ▸ ▸
  9. 9. PROS/CONS ▸ Hello World 3 ▸
  10. 10. HELLO WORLD
  11. 11. HELLO WORLD ▸ (ROM) ▸ CPU ▸ : 56 13 ▸ CPU BUS (Memory-mapped I/O) ▸ PPU ( )
  12. 12. ROM ROM 16KB or 32KB
  13. 13. https://github.com/ichikaway/goNES/blob/master/cpu/opcode.go
  14. 14. 78 A2 FF 9A A9 00 8D 00 20 … 0x8000 0x8001 0x8002 0x8003 0x8004 0x8005 0x8006 0x8007 0x8008
  15. 15. 78 A2 FF 9A A9 00 8D 00 20 … 0x8000 0x8001 0x8002 0x8003 0x8004 0x8005 0x8006 0x8007 0x8008 0x8000 SEI
  16. 16. 78 A2 FF 9A A9 00 8D 00 20 … 0x8000 0x8001 0x8002 0x8003 0x8004 0x8005 0x8006 0x8007 0x8008 0x8001 LDX
  17. 17. 78 A2 FF 9A A9 00 8D 00 20 … 0x8000 0x8001 0x8002 0x8003 0x8004 0x8005 0x8006 0x8007 0x8008 0x8003 TXS
  18. 18. (PHP) https://github.com/hasegawa-tomoki/php-terminal-nes-emulator/blob/master/src/Cpu/Cpu.php
  19. 19. (RUST) https://github.com/bokuweb/rustynes/blob/master/src/nes/cpu/mod.rs
  20. 20. (RUST) https://github.com/bokuweb/rustynes/blob/master/src/nes/cpu/instructions.rs
  21. 21. ▸ PHP RUST Go ▸ ▸ uint8 uint16 ▸ PHP int int & FF
  22. 22. ▸ ▸ ▸
  23. 23. STEP0 ▸ ▸ ▸ ▸ 2 PPU
  24. 24. STEP1 ▸ Hello, World! ▸ @bokuweb ▸ https://qiita.com/bokuweb/items/1575337bef44ae82f4d3 ▸ 3 PPU 30%
  25. 25. STEP2 ▸ ▸ ROM CPU ▸ ▸ : NES Emulator JavaScript ▸ PHP Terminal NES Emulator ▸ https://github.com/hasegawa-tomoki/php-terminal-nes- emulator/
  26. 26. STEP3 ▸ ▸ PPU ▸
  27. 27. THANK YOU ▸ @cakephper ▸ goNES ▸ https://github.com/ichikaway/goNES
  28. 28. ( ) ▸ (@tomzoh) ▸ https://speakerdeck.com/tomzoh/yeeh-php-nes-emulators- here ▸ PHP (@tomzoh) ▸ https://speakerdeck.com/tomzoh/create-a-nes-emulator- with-php
  29. 29. ( ) ▸ (@bokuweb) ▸ https://speakerdeck.com/bokuweb/ huamikonemiyuretafalsechuang-rifang
  30. 30. https://gist.github.com/ichikaway/151d0366f380e83afee0023e3b6e0c1a
  31. 31. ▸ ▸ ▸

×