retro-esp32 / RetroESP32

Retro ESP32 is a turbo charged Odroid Go Launcher, Emulator and ROM Manager
Creative Commons Attribution Share Alike 4.0 International
600 stars 93 forks source link

How was RetroESP32-Game-And-Watch.bin created from the source? #101

Closed x130844 closed 2 years ago

x130844 commented 2 years ago

for the life of me, I can't find docs on how to create .bin files. only fw files. Any instructions on creating .bin files fro this source? The OTA fails. at the end flashing it, but it does create some files. I do see a lot of red text flashing by, looks like fatal errors. I'm missing something but unsure what, I think I followed all the steps on how to compile the src on my own, but it's not working. it just says "Bye" at the end of OTA and nothing is written to the esp32. Any documentation you could recommend to get unstuck? been 3 days now of research and tries, reinstall the toolchain, esp32 tools, trying different repos etc. Thank you!

x130844 commented 2 years ago

days later, and after decided to try a docker for esp32 env. fully configured. they all failed with the instructions shipped with retroEsp. (using ./OTA, or make, or rg_tool.py or other ). has anyone ever been able to compile into a .bin from src?

shar33f commented 2 years ago

Sorry if this is a dumb question but am I supposed to be able to flash RetroESP32-Game-And-Watch.bin to my odroid-go and then I'll have a game&watch emulator (that would be so bloody sweet!!). I thought I'm only able to flash .fw files..

x130844 commented 2 years ago

as far as I know .fw for retro is if you want to update your firmware from Odroid itself, you would copy the fw on sdcard and let Odroid update the firmware. For the bin file, I was able to flash bin with esptool from computer with USB cable connected to the esp32. and that worked perfectly. I think the game&watch bin will completely remove the original Odroid retro firmware but I could be wrong here, I'm only using an esp32 hardware. not Odroid GO.

shar33f commented 2 years ago

I see. I wish there was a .fw version I could flash directly on my odroid-go, maybe one will get released in the future or the game&watch emulator will get merged into a future .fw release 🤞🏻

x130844 commented 2 years ago

I think I was able to compile a .fw for game&watch from src, but with all my attempts and different IDEs, I'll see if I can recreate it for you. don't hold your breath though.

32teeth commented 2 years ago

There is already a prepared bin for the Game and Watch version.

python2 esptool.py --chip esp32 --baud 2000000 --port [your port] write_flash 0x00 RetroESP32-Game-And-Watch.bin

If you are building from scratch, i recommend you follow The DIY Instructions

x130844 commented 2 years ago

Thank you for the reply, yes and the .bin works fine, I wanted to start making some changes for custom hardware and others. Hence why I wanted to recompile. And I did follow this doc too. I will try one more time, but I can’t see what I’m missing.

On Jan 10, 2022, at 3:27 PM, Eugene Andruszczenko @.***> wrote:

There is already a prepared bin for the Game and Watch version.

python2 esptool.py --chip esp32 --baud 2000000 --port [your port] write_flash 0x00 RetroESP32-Game-And-Watch.bin If you are building from scratch, i recommend you follow The DIY Instructions https://github.com/retro-esp32/RetroESP32/blob/master/DIY.md — Reply to this email directly, view it on GitHub https://github.com/retro-esp32/RetroESP32/issues/101#issuecomment-1009359830, or unsubscribe https://github.com/notifications/unsubscribe-auth/ARNUPKSYHQ5CUCST5S4FPELUVNFLFANCNFSM5LB52CKQ. Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub. You are receiving this because you authored the thread.

x130844 commented 2 years ago

Hi again,oOk, the steps provided are definitely broken,

It fails right at the 3rd git command for the submodules.

git submodule foreach git pull origin master

Entering 'Emulators/frodo-go' From github.com:OtherCrashOverride/frodo-go

I tried adding "--allow-unrelated-histories” But failed again:

git submodule foreach git pull origin master --allow-unrelated-histories

Entering 'Emulators/frodo-go' From github.com:OtherCrashOverride/frodo-go

On Jan 10, 2022, at 3:27 PM, Eugene Andruszczenko @.***> wrote:

There is already a prepared bin for the Game and Watch version.

python2 esptool.py --chip esp32 --baud 2000000 --port [your port] write_flash 0x00 RetroESP32-Game-And-Watch.bin If you are building from scratch, i recommend you follow The DIY Instructions https://github.com/retro-esp32/RetroESP32/blob/master/DIY.md — Reply to this email directly, view it on GitHub https://github.com/retro-esp32/RetroESP32/issues/101#issuecomment-1009359830, or unsubscribe https://github.com/notifications/unsubscribe-auth/ARNUPKSYHQ5CUCST5S4FPELUVNFLFANCNFSM5LB52CKQ. Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub. You are receiving this because you authored the thread.

h1aji commented 2 years ago

Get your mac and remove all your previous esp-idf and xtensa installations. Create ~/esp folder and simply run:

cd ~/esp
git clone -b master --single-branch git@github.com:retro-esp32/RetroESP32.git --recursive
cd RetroESP32
git submodule update --init --recursive
git submodule foreach git pull origin master
chmod -R 777 Scripts
cd Scripts
./installer

Works fine

x130844 commented 2 years ago

ok, I will try again, the only difference is that I run these commands from my home (~). not ~/esp. I don't see why it would make a difference, but I'm about to try again. I assume you ran these steps above in the past few days? (just confirming that no changes done on GitHub is what's blocking me. and if the issue is only with me, that's fine, I'll eventually figure it out, I just need to know that indeed it is only me.) Thank you for your help.

x130844 commented 2 years ago

Same, I will try again from a brand new account, I will create. I really don't understand what's going on. why it would work for you but not me.

Unpacking objects: 100% (3/3), 1.37 KiB | 349.00 KiB/s, done. From github.com:OtherCrashOverride/odroid-go-firmware

x130844 commented 2 years ago

Exactly the same error with a brand new account on the laptop. I guess, next is I'll start a new linux VM.

x130844 commented 2 years ago

ok, linux VM, new github keys,

root@debian:~/esp/RetroESP32# uname -a Linux debian 4.19.0-18-arm64 #1 SMP Debian 4.19.208-1 (2021-09-29) aarch64 GNU/Linux

apt-get install git as this is a new environment, Then it fails the same way at the end

root@debian:~/esp/RetroESP32# git submodule update --init --recursive

root@debian:~/esp/RetroESP32# git submodule foreach git pull origin master Entering 'Emulators/frodo-go' From github.com:OtherCrashOverride/frodo-go

Are you guys sure it's me?

h1aji commented 2 years ago

Its you. It tells you exactly whats the problem. There is no "master" branch Emulators/odroid-go-handy and in Emulators/odroid-go-pcengine-huexpress. Delete these folders and do git clone

x130844 commented 2 years ago

I removed the comments from 102. As far as this, I did mention that I could go further by cleaning the folders, but then I get other errors, I fix them, then there are more errors that I have to fix, The point being, all my environments make me have to fix about 15 things, I then give up, clearly something is wrong on my side, especially if you guys keep telling me that the guide works 100%. If the guide worked as indicated, I shouldn't have to delete these folders and git clone. Something is amiss. If it's me, like you just said, that's perfectly fine. the guide is 100% correct, and I need to find why if I follow it to the letter it fails for me while it works for you. I'm ok with that, h1aji, Thank you for confirming that the guide works and I'm not following it correctly.

x130844 commented 2 years ago

and for sh*ts and giggles, after removing the folders and trying again, it went further, but then fails with:

fatal: No url found for submodule path 'Launchers/esplay-retro-emulation' in .gitmodules I can fix that too, but then it's another error. ad-nauseam. I already spent 6 days on this, and I will keep trying for a few more, I will find out what I'm doing wrong.

h1aji commented 2 years ago

This repo here https://github.com/pelle7/odroid-go-pcengine-huexpress doesnt have master branch, only develop.

You can ask developer why he deleted master branch.

I`d recommend reinstall everything and skip

git submodule foreach git pull origin master and continue with ./install

x130844 commented 2 years ago

Thank you for confirming that the documentation is indeed incorrect (not up to date) so they would fail. Skipping this step allowed to complete, but a lot of fatal errors in red. and no new .bin or .fw generated. I appreciate the help.
a bunch of: make[2]: *** [src/bootloader_common.o] Error 127 xtensa-esp32-elf-gcc: fatal error: no input files compilation terminated.

/bin/sh: Watch-dirty": command not found make[2]: *** [src/bootloader_flash.o] Error 127 xtensa-esp32-elf-gcc: fatal error: no input files

I really wonder how the other guy was able to compile this.

h1aji commented 2 years ago

I didnt say that documentation is incorrect. I said that mentioned repository doesnt have master branch

x130844 commented 2 years ago

:). ok, never mind, I can see this is a touchy subject, Thx again.

x130844 commented 2 years ago

Update: for anyone else who might be interested in compiling this, the docs are not mentioning that you also need to install ffmpeg as a pre-req. I'll faff around a bit more, but I think I'm done with this project.

32teeth commented 2 years ago

Update: for anyone else who might be interested in compiling this, the docs are not mentioning that you also need to install ffmpeg as a pre-req. I'll faff around a bit more, but I think I'm done with this project.

ffmpeg you can easily install view brew

brew install ffmpeg 

it's only ever used to create the distributable firmware .fw files from this repo this is done by executing the ./firmware script from the scripts folder

a bit X/Y problem space here Please follow the issue markdown as provided for future use it really does help with our intake

Screen Shot 2022-01-12 at 10 56 40 AM

e

x130844 commented 2 years ago

Hi, can you delete this whole GitHub issue #101, Thank you.

shar33f commented 2 years ago

@x130844 does that mean you were able to build a game&watch .fw file? If so, could you please send to me, I'd love to test it on my odroid-go!

x130844 commented 2 years ago

@shar33f I was not able to, the instructions are incorrect and after fixing each issue, new issues come up, and I discover that other components are missing. (ffmpeg for example). Spending over a week to just debug and correct the instructions just to be told that they actually work is not very frustrating. Sorry buddy. I would have given you any .bin or .fw as customized as you'd like. Oh well.

shar33f commented 2 years ago

Ok no problem and thanks for trying! Hopefully it gets merged into a future .fw release.

x130844 commented 2 years ago

@shar33f although, feel free to try also on your side. It'd be interesting if you're getting the same errors.