Giter Site home page Giter Site logo

esp32-z80emu's People

Contributors

abelykh0 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

esp32-z80emu's Issues

Fix for bad AY-3-891x sound

Hello,

I have tested your emulator and it has sound, but the melodies are reversed in pitch.

The AY-3-891x chip "pitch" parameter corresponds to the wave period, not its frequency. Your code passes directly pitch as frequency, which is not correct.

For an AY running at 4MHz, reference frequency is 125000 Hz. But on a Spectrum 128K, it runs at 3.5469MHz, so the frequency is 125000 * 3.5469 / 4 = 110840.

You should substitute line 141 in /lib/Sound/ay3-8912-state.cpp
from
_channel[channel].setFrequency(this->channelFrequency[channel]);
to
_channel[channel].setFrequency(fixPitch(this->channelFrequency[channel]));

and defining somewhere in your code a fixPitch function like this:

inline int fixPitch(int p)
{
#define FREQUENCY_REFERENCE 110840
	int fixed = (p > 0) ? (FREQUENCY_REFERENCE / p) : 0;
	return fixed;
}

Regards,
David

Compiling error

Compiling Error - PlatformIO VSCode win10
Using FABGl 0.9.0 (current)

Some directions ?

------------------CUT HERE-------------------
Compiling .pio\build\pico32\lib738\[email protected]\canvas.cpp.o
In file included from lib/Display/Screen.h:5:0,
from include/Emulator.h:4,
from src\emulator.cpp:1:
lib/Display/VideoController.h:13:1: error: expected class-name before '{' token
{
^
In file included from lib/Display/Screen.h:5:0,
from include/Emulator.h:4,
from src\FileSystem.cpp:7:
lib/Display/VideoController.h:13:1: error: expected class-name before '{' token
{
^
*** [.pio\build\pico32\src\FileSystem.cpp.o] Error 1
src\emulator.cpp: In function 'void startKeyboard()':
src\emulator.cpp:53:2: error: 'quickCheckHardware' is not a member of 'fabgl::Mouse'
Mouse::quickCheckHardware();
^
*** [.pio\build\pico32\src\emulator.cpp.o] Error 1
In file included from lib/Display/Screen.h:5:0,
from include/emulator.h:4,
from src\main.cpp:3:
lib/Display/VideoController.h:13:1: error: expected class-name before '{' token
{
^
*** [.pio\build\pico32\src\main.cpp.o] Error 1

Error when loading from SD card

Привет.
С последними версиями библиотек в PlatformIO проект собирается, но не работает с SD-картами.
в терминале такая ошибка:
[ 11940][E][sd_diskio.cpp:796] sdcard_mount(): esp_vfs_fat_register failed 0x(101)
Возможно ли перепроверить и исправить по возможности??

Error loading version 1 .z80 files

I Got some errors trying to load .z80 files

1 - If you dont have the .scr file in / directory, I got an exception after press F3 key

2 - With .scr files in / (with .z80 files also) I got another exceptions after press ENTER

TTGO VGA32_V1.4

-------------------------- CUT HERE -------------------------

Guru Meditation Error: Core 0 panic'ed (LoadProhibited). Exception was unhandled.
Core 0 register dump:
PC : 0x40102b7d PS : 0x00060430 A0 : 0x800d28a6 A1 : 0x3ffb9090
A2 : 0xdd3fe600 A3 : 0x00000000 A4 : 0x00000001 A5 : 0x00000001
A6 : 0x00060220 A7 : 0x00000000 A8 : 0x8008b668 A9 : 0x3ffb90a0
A10 : 0x00000003 A11 : 0x00060423 A12 : 0x00060420 A13 : 0x00000001
A14 : 0x00060223 A15 : 0x00000000 SAR : 0x00000013 EXCCAUSE: 0x0000001c
EXCVADDR: 0xdd3fe600 LBEG : 0x4000c2e0 LEND : 0x4000c2f6 LCOUNT : 0x00000000

Backtrace: 0x40102b7d:0x3ffb9090 0x400d28a3:0x3ffb90b0 0x400d5105:0x3ffb90e0 0x400d55c9:0x3ffb9110 0x400e4dd2:0x3ffb9150 0x400e30d0:0x3ffb9170 0x400e4653:0x3ffb91b0 0x400e61aa:0x3ffb91e0 0x4000bdbb:0x3ffb9200 0x40001125:0x3ffb9220 0x400594e9:0x3ffb9240 0x400e8671:0x3ffb9260 0x400e86e1:0x3ffb9290 0x400fc487:0x3ffb92b0 0x40102617:0x3ffb92d0 0x400d70f9:0x3ffb92f0 0x400d1fbd:0x3ffb9340 0x400d268f:0x3ffb9390 0x4008a799:0x3ffb93b0

Rebooting...
in setup()
]

----------------------------------- CUT HERE -----------------------------

PC: 0x40102b7d: std::__find_if > >(unsigned int *, unsigned int *, __gnu_cxx::__ops::_Iter_pred >, std::random_access_iterator_tag) at /home/runner/work/esp32-arduino-lib-builder/esp32-arduino-lib-builder/xtensa-esp32-elf/xtensa-esp32-elf/include/c++/5.2.0/bits/stl_algo.h line 133
EXCVADDR: 0xdd3fe600

Decoding stack results
0x40102b7d: std::__find_if > >(unsigned int , unsigned int , __gnu_cxx::__ops::_Iter_pred >, std::random_access_iterator_tag) at /home/runner/work/esp32-arduino-lib-builder/esp32-arduino-lib-builder/xtensa-esp32-elf/xtensa-esp32-elf/include/c++/5.2.0/bits/stl_algo.h line 133
0x400d28a3: SPIClass::transfer(unsigned char) at C:\users\fgarcia.platformio\packages\framework-arduinoespressif32\libraries\SPI\src\SPI.cpp line 158
0x400d5105: sdDeselectCard(unsigned char) at C:\users\fgarcia.platformio\packages\framework-arduinoespressif32\libraries\SD\src\sd_diskio.cpp line 85
0x400d55c9: sdWriteSector(unsigned char, char const
, unsigned long long) at C:\users\fgarcia.platformio\packages\framework-arduinoespressif32\libraries\SD\src\sd_diskio.cpp line 275
0x400e4dd2: get_fattime at /home/runner/work/esp32-arduino-lib-builder/esp32-arduino-lib-builder/esp-idf/components/fatfs/src/diskio.c line 92
0x400e30d0: f_write at /home/runner/work/esp32-arduino-lib-builder/esp32-arduino-lib-builder/esp-idf/components/fatfs/src/ff.c line 3848
0x400e4653: vfs_fat_link at /home/runner/work/esp32-arduino-lib-builder/esp32-arduino-lib-builder/esp-idf/components/fatfs/src/vfs_fat.c line 521
0x400e61aa: esp_vfs_close at /home/runner/work/esp32-arduino-lib-builder/esp32-arduino-lib-builder/esp-idf/components/vfs/vfs.c line 464
0x400e8671: fseek at ../../../.././newlib/libc/stdio/fseek.c line 126
0x400e86e1: _fseeko_r at ../../../.././newlib/libc/stdio/fseeko.c line 154
0x400fc487: VFSFileImpl::VFSFileImpl(VFSImpl
, char const*, char const*) at C:\users\fgarcia.platformio\packages\framework-arduinoespressif32\libraries\FS\src\vfs_api.cpp line 236
0x400d70f9: zx::LoadZ80Snapshot(fs::File, unsigned char*, unsigned char*) at lib\Emulator\z80snapshot.cpp line 343
0x400d1fbd: loadSnapshotLoop() at src\FileSystem.cpp line 492
0x400d268f: EmulatorTaskMain(void*) at src\emulator.cpp line 338
0x4008a799: vPortTaskWrapper at /home/runner/work/esp32-arduino-lib-builder/esp32-arduino-lib-builder/esp-idf/components/freertos/port.c line 143

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.