Super Retro-Cade

Discussion in 'Other Consoles & Oldies' started by kuwanger, Sep 29, 2018.

  1. WD_GASTER2

    WD_GASTER2 GBAtemp Regular

    Member
    3
    Jun 17, 2018
    France
    tbh android is just linux for the most part. i wonder how lakka is speedwise with controller inputs.
     
  2. kuwanger
    OP

    kuwanger GBAtemp Advanced Fan

    Member
    7
    Jul 26, 2006
    United States
    Yes, but Android was designed with touchscreen input in mind and doesn't seem well optimized for gamepad input--those results suggest around 5-11 frames depending on input. I imagine Lakka, being basically just a launcher for RetroArch, would be in the same ballpark as Retroarch on the Raspberry Pi--those results are in the 4.5-8 frames depending on PC vs Retropie and just how much effort has went into choosing more optimal choices. The other factor, of course, is that those different tests aren't equivalent (different games were tested) and my gut feeling is that the numbers are actually a few frames higher for Android if they were the same game.

    Of course the real test would be to actually do testing. Unfortunately, I don't have any cameras that can do the 120+ fps to actually do such a test myself. I'm also not entirely convinced that Lakka as is is a good comparison--I don't know if it's because the hardware is not being properly described in the dtb or it's something else. I do know the results I get are pretty nonsensical though: from an earlier post "The frame rate didn't make much sense though: the rate would be ~55-56 fps but turning off frame throttling and it'd easily say in the 70 fps range." Maybe if I fiddled around with the options a lot I could figure it out.

    If you do have a camera able to do such tests, I'd be interested in the results. I definitely think I notice a delay with games using the default launcher. I'd be interested to know if it's just a placebo effect.
     
  3. WD_GASTER2

    WD_GASTER2 GBAtemp Regular

    Member
    3
    Jun 17, 2018
    France
    btw i can now confirm that you can make a backup of your nand and boot it from an sd card. A LA emu-nand. also lakka is not needed to do this.
    going to bed but retroarch can be booted off the emu-nanded (if that is even a term. lol) sd card.
     
    Last edited by WD_GASTER2, Oct 5, 2018
  4. kuwanger
    OP

    kuwanger GBAtemp Advanced Fan

    Member
    7
    Jul 26, 2006
    United States
    I tried that out and was able to add a game with the gamelist.db. I also changed the boot logo (mostly to verify that'd work). As far as lakka not being needed, I presume you mean that you can just dump nand onto the sd card directly to boot Android without needing to go through Lakka? You still need some way to dump the nand first. Makes me wonder if it'd be viable to enlarge partition 7. In any case, one thing I discovered is the hardware really doesn't tolerate well having a slow SD card, but then I've seen similar behavior when you use a slow SD card/USB flash drive with Android in general.

    Anyways, thanks for testing this out. Makes me willing to be more daring when trying to fiddle with this. Have you tried replacing gamelaunch.apk with the latest version of retroarch.apk to see if that works?
     
  5. WD_GASTER2

    WD_GASTER2 GBAtemp Regular

    Member
    3
    Jun 17, 2018
    France
    so a few things:

    1)lakka is no longer needed. at all. With a uart to usb the default image boots to a linux console that you can access through Putty. you can backup your nand from there.
    2)you cant just change an apk and have it "boot" as launcher. you need to have an application that has the "launcher flag" active when the application is compiled.
    3)I ported the generations dash that i programmed to it which has a "launcher flag" so it lets you pick if you want to start the default gamelaunch or my port of the generations dash on boot.
    4) i installed retroarch on the emunand but its a PAIN IN THE ASS to configure (as retroarch has always been) i will go back to it later as my main focus is to polish up my port of the generations dash and which i am giving a new GUI for the retro-cade.
    5) yes extending the partition for bigger SD cards would be a GODSEND for the emu nand stuff, but the good part? the explusalpha emulators play pretty decently with the hardware. I have been playing pc engine-cd games from the usb drive last 24 hours (boot to my generations dash then launch them from there).
    6)booting the "emunand" from the SD card will work with no issue so long as you mentioned, you are using a fairly speedy micro sd card. I am using a 16gb microsd that was fairly cheap with a good speed rating and have no issue.

    TLDR; custom firmware that boots from an "emunand" has been achieved on this thing in the last week. pretty crazy if you ask me(its clunky as hell tho at this time). your discoveries have been playing a big roll in this.cheers.
     
    Last edited by WD_GASTER2, Oct 6, 2018
  6. kuwanger
    OP

    kuwanger GBAtemp Advanced Fan

    Member
    7
    Jul 26, 2006
    United States
    I see. Booting to a Linux console would be useful to also try to dump the kernel .config (if it has it (not sure if Android kernels even have the option)) for use in building an image from scratch or based on another image. I agree Retroarch is a pain to configure, but I was mostly curious to know if newer version of Retroarch are faster/slower; Lakka and Super Retro-Cade both seem to be based on 1.4.x. Preferable an image based on Retropie could be built since Emulation Station actually is pretty decent, although that's designed with the ability to connect to the internet in mind. I haven't even bothered looking into the ports support connecting a hub*, but I'd presume that'd work so a wifi dongle should work.

    Anyways, mostly rambling. The biggest reason I'd like a clean image really is so that something can be built and distributed avoiding even needing to dump the nand at all--the image would be able to load any binary blobs off the nand as needed. I do agree it's pretty crazy how easy it was--I literally LMAO when I saw Lakka booting.

    * Keyboard, gamepad, and wifi is what I'm thinking and why two ports wouldn't be enough.
     
  7. WD_GASTER2

    WD_GASTER2 GBAtemp Regular

    Member
    3
    Jun 17, 2018
    France
    short update. I bought a 1.1 and backed up the image. going through lakka i flashed my 1.0 retro-cades nand (via DD)
    it upgraded to 1.1 with no issue!
    so thats good new i would guess.
     
  8. kuwanger
    OP

    kuwanger GBAtemp Advanced Fan

    Member
    7
    Jul 26, 2006
    United States
    I always presumed they merely updated the image to change the gamelist.db and the appropriate files in media\GAME\ but it's nice to confirm. I also presume you could downgrade 1.1 to 1.0. It actually would be interesting to know if that's all the changes they made. I think there was some talk of further optimization? I don't care enough to get a second one to find out. :)
     
  9. WD_GASTER2

    WD_GASTER2 GBAtemp Regular

    Member
    3
    Jun 17, 2018
    France
    yep. neo geo emulation performs better. I am sure there are more changes but thats noticeable off the bat.there is frame drop galore on some neo geo titles in 1.0. the cores seem to have been updated on this thing. so good stuff.
     
  10. PSX_Specter

    PSX_Specter Member

    Newcomer
    1
    Oct 13, 2018
    United States
    Many thanks to kuwanger and WD GASTER2. You are sorcerers among men.I have had amazing success with Lakka for orange pi lite and tweaking the uEnv.txt variable to sun8i-h3-orangepi-pc.dtb. USB hub, wifi, USB ethernet adapter, many controllers are supported by Lakka's amazing driver base. I think the android video driver is better than what linux provides, but I had little to no issues running Playstation and Sega 32x. N64 is just too much for the little H3. Being able to tweak config files and add/remove roms via SMB and being able to use Putty is nice, too. For anyone interested, you will need a very fast sd card and its a good idea to remove the two red panels from the top half of the case so it can breathe. Manually adding the FBA 2012 core from github was necessary to get my fba games all working. YMMV. Can't wait to see the custom android based firmware. Keep up the good work !
     
  11. ArugulaZ

    ArugulaZ GBAtemp Advanced Fan

    Member
    4
    Sep 17, 2009
    United States
    This is pretty sweet. For the moment, I'd just like to update the firmware to 1.1... is there any way for a layman to do this? What flavor of Lakka does this use? Can I just set an SD card into the system and run it at boot?
     
  12. PSX_Specter

    PSX_Specter Member

    Newcomer
    1
    Oct 13, 2018
    United States
    I can't help just yet with the android/original firmware/update part, but if you want to try lakka...

    1.) Download this lakka build: le.builds.lakka.tv/Allwinner.orangepi_lite.arm/Lakka-Allwinner.orangepi_lite.arm-2.1.1.img.gz
    2.) Extract the contents and write them to your sd card with win32 disk imager.
    3.) Open the sd card on your pc and open uEnv.txt, then change the line that contains "sun8i-h3-orangepi-lite.dtb" and change it to read "sun8i-h3-orangepi-pc.dtb"
    4.) Insert sd card into your super retro cade and turn it on. Lakka will resize the filesystem, reboot, and should ask you to set up your controller.
    6.) Now you need to add some games. You can either add them directly to your sd card from a linux environment, or you can access the lakka samba share from a windows pc. You will need to enable smb from the lakka services options to do so. I was able to use several wifi dongles I had laying around. My usb to ethernet adapter also worked. If you use wifi, be sure to enter your wifi key with the gamepad and NOT the keyboard or it will not work.


    7.) If you have problems with saving settings changes, just shutdown the retro cade after you make the change via lakka's shutdown option, then turn it back on. Don't forget to put your bios files for pcengine cd, sega cd, playstation, etc. in the system directory. This can also be done from windows via the network share.

    If you experience sound stuttering or poor performance in SNES, Playstation, 32X, or anything else that "should" work normally, your sd card may be too slow. I had poor results with an average class 10 card with 35MB/s read and 10MB/s write. The card I am using now has 65MB/s read and 45MB/s write. Slower cards may work, though. This guide probably isn't very thorough, and I apologize in advance. Just trying to give everyone something to hold them over while the real magic is being worked on :)
     
    ArugulaZ likes this.
  13. kuwanger
    OP

    kuwanger GBAtemp Advanced Fan

    Member
    7
    Jul 26, 2006
    United States
    Thanks for that information. I was wondering why I was having such questionable performance in various instances in the past with Retroarch. I presume this means that Retroarch is doing "a lot" of reads, writes, or polls, so it might have more to do with I/O per second than actual throughput. Well, yet another reason to get newer, non-junk SD cards. :)
     
  14. WD_GASTER2

    WD_GASTER2 GBAtemp Regular

    Member
    3
    Jun 17, 2018
    France
    use a u1 or u3 class card and it performs pretty gangsta.
     
  15. PSX_Specter

    PSX_Specter Member

    Newcomer
    1
    Oct 13, 2018
    United States
    I discovered that need for speed by accident. The same card works fine in my pi3 retropie setup. I wonder if this all works by pure luck due to lakka's included drivers. Roms can be loaded via usb on much slower media, so I don't think throughput is an issue, either. Now if I could just figure out how to mount my network share on lakka....
     
  16. WD_GASTER2

    WD_GASTER2 GBAtemp Regular

    Member
    3
    Jun 17, 2018
    France
    it makes sense though, you want to try to get the closest to nand read and write speeds as possible.
    to Mr. ArugulaZ:

    read the first post. the rest becomes kind of self explanatory. you will need a usb keyboard a usb drive and the sd card that you are booting lakka from. nand dump your 1.1 to the usb and then flash to the nand of a 1.0 box by booting to lakka on the 1.0 box. google how to do DD commands in linux (as it requires the terminal)
     
    Last edited by WD_GASTER2, Oct 14, 2018
  17. PSX_Specter

    PSX_Specter Member

    Newcomer
    1
    Oct 13, 2018
    United States
    @WD_GASTER2, I was able to back up my nand to a usb stick via Putty with Lakka running, pretty slick. If I flashed Lakka to the nand, would I be able to restore it to the original image later on if I wanted to? Having Lakka on the nand could possibly eliminate the need for a fast sd card, because you could load roms from an external sd card or usb drive then.
    I changed the boot logo on the sd card I wrote my backup to so I can confirm it is booting and not the original firmware. In other words, I know my backup image is a good working copy.
     
  18. WD_GASTER2

    WD_GASTER2 GBAtemp Regular

    Member
    3
    Jun 17, 2018
    France
    the way i managed to do it was to boot from an sd card with lakka to do the flash. if you flash a lakka image to the boards nand, theoretically it should work but to flash back you would need to boot from the sd card to perform the write to the boards nand. you cant dd on the disk that is running dd itself afaik.

    either way i havent tried flashing lakka to the boards nand. so i cannot advise it or recommend it myself. if you proceed it be at your own risk.
     
    Last edited by WD_GASTER2, Oct 14, 2018
  19. kuwanger
    OP

    kuwanger GBAtemp Advanced Fan

    Member
    7
    Jul 26, 2006
    United States
    @WD_GASTER2, For the UART-to-USB, is something like this sufficient with connections to the TX/RX/GND holes right beside the SD slot? I'm most curious since some more googling indicates there's a lot of other firmwares based on the same kernel (lots of H2/H3 TV boxes) so one of them might be useful to pick out kernel modules (I'm thinking mostly xpad.ko) but I'd rather actually boot into a Linux console on the actual built-in kernel to try that route.

    Looking a little more into resizing partition 7, it's clear the partition table is broken:

    Warning: Spoilers inside!

    As you can see the Extended partition is improperly overlapping partition 2 and it's clear the extended partition should be shifted up 106495 sectors so partition 16 isn't partially hanging outside of the Extended partition block. I'm not really sure how to fix this broken mess. :/ In any case, more details about the partitions:

    Warning: Spoilers inside!

    So, beyond all the really bizarre arrangement, there's clearly ~608MB totally wasted space and about 1.4GB of space tied up in needless file system allocations. I might at some point toy around with actually pruning the absurdity of all of that. *shrug*

    @PSX_Specter, I'd really advise against that. At least until we're not just throwing various .dtb at the system and trying to have them stick. I'm wondering if something about the *orangepi-pc.dtb vs the *orangepi-lite.dtb is not properly setting up throttling for the CPU which is why you notice yours getting so hot? Honestly, I don't know what all .dtb cover but I do know the *orangepi-pc.dtb doesn't seem to actually see the nand. Just the fact that we're sort of jerry-rigging the lite.img to use a different dtb because the orangepi-pc image doesn't work (IIRC) already tells me we're in pretty questionable territory.
     
    Last edited by kuwanger, Oct 14, 2018
  20. WD_GASTER2

    WD_GASTER2 GBAtemp Regular

    Member
    3
    Jun 17, 2018
    France
    i used an ftdi break out board that lets you switch between 3.3 and 5v. to stray on the safe side i use the 3.3v:

    https://www.newegg.com/Product/Prod...Vj7rACh2vzwrPEAYYAiABEgKmXPD_BwE&gclsrc=aw.ds

    you just plug in the tx, rx and gnd to the back pins with some jumper cables and you plug in the micro usb part to a pc.


    the cable you are putting up should work but havent tried it, you will probably need to piggy back it onto a vcc point on the board if you want to get it to work.

    as for the broken partition table i was aware of it. when you burn the nand image as an "emunand" image to an sd card i tried fixing the partition issues on the sd card with a few hard disk partitioning tools but that improperly mounted partition is stopping the tools ive tried from resizing. if that partition is corrected making the 1.4 gb partiton (which emulates an "sd" card in android) resized to a bigger size would be trivial.
     
Loading...