SHARPENTIERS / MZ-SD2CMT

SD card based CMT for MZ 80K series
GNU General Public License v3.0
12 stars 3 forks source link

Unable to compile with current Arduino IDE and library versions #2

Open ottj opened 3 years ago

ottj commented 3 years ago

Hi I just finished recapping my MZ80k and tried to load this awesome project onto an Arduino. I get all kinds of errors in the current Arduino IDE when I try to compile it. I then tried with downgrading the IDE and also the libraries, but the list of strange errors just changes. I am not able to update/fix the code myself. Can you provide some info which IDE and library versions to use, or even a fix in the code? Thanks a lot in advance

hlide commented 3 years ago

Hi. Can you describe the version of the IDE you used? That project is kinda old and I am now using Visual Studio plus an Arduino plugin. Arduino IDE and libraries are not as simple as they should be because they are constantly evolving. I'll try with the most recent IDE and libraries.

hlide commented 3 years ago

Also can you tell me what the devices you want to use with Arduino MEGA?

hlide commented 3 years ago

You can see the version 1.8.5 and in the end the list of libraries and their version. I didn't update all the versions, that would be my next task. When finished, I will push my last commit as I can see the GitHub version is not the last.
image

hlide commented 3 years ago

I just need to update the SdFat to the one I wanted: image

hlide commented 3 years ago

I committed last change. Try it with Arduino IDE 1.8.5 and the libraries as listed in pictures.

ottj commented 3 years ago

Hi. Thanks a lot for this fast reply! I was able to compile it with the versions you specified, although I had to remove the

include "mz-sd2cmt.std.h" line from .ino file, since this is missing from the files. So you either have to remove this line as well or commit the file.

Uploading it to the Arduino Mega 2560 worked as well.

I plan to use it with the the OLED screen, IR remote, and SD Card reader specified in the readme. At a later stage I I might also add a relay module to be able to trigger the reset of the MZ80k via remote.

hlide commented 3 years ago

Good to hear! I forgot to remove that file so it is okay to proceed this way. Regarding IR remote, pay attention to their keycodes, they may vary if you don't take the one I took or you will need to modify them in the code because they are not standard unhopefully.

I once tried that player on my MZ-80 K and had to play twice to make sure MZ-80 K loads unlike MZ-700. It may be an issue with terminating a header block to let it start the data block. A second play will skip the header block to start the data block. By playing I mean only launching from MEGA while MZ-80 K is still trying to load (no break). I didn't try to investigate further because I had more priority elsewhere and it was for testing faulty DRAM and replacing them.

hlide commented 2 months ago

As a fact MZ-80 K and MZ-80 A outputs MOTOR signal as 12V, not 5V which is not good for the Arduino MEGA. So we need a shift level for it, using a LM7805 for instance.

ottj commented 2 months ago

MOTOR is a pulsed signal, and LM7805 are more for power AFAIK. Maybe a voltage divider would be better suited? https://forum.arduino.cc/t/12v-signal-to-5v-with-lm7805/324733 I'd prefer having a small board with these components so I can add it to the wiring inside the 80K.

hlide commented 2 months ago

MOTOR is not just a pulse signal, it powers MZ 80 K and MZ 80 A dataset with 12V (yep, that's why it is called MOTOR and not REMOTE). As for MZ-700 and MZ-800, it also powers their dataset but with 5V. But in our case, a voltage divider can be used since we don't need to power our MEGA through MOTOR signal.