Repository navigation
Conversation
…ity DNS Replicates inside the core what a DreamPi (Kazade/dreampi) does beside a real Dreamcast: - reicast_dns_server core option picks the resolver handed to the emulated console over PPP (dns.flyca.st / Shuouma 46.101.91.123 / DreamPi alternate 209.50.50.129 / 8.8.8.8). The legacy 46.101.91.123->dns.flyca.st rewrite is removed so an explicit choice is honored literally. - reicast_dcnow: UdpSink snoops the Dreamcast's DNS queries and a worker POSTs sha256(hostname) to dcnow-2016.appspot.com every 15 s over plain HTTP/80, like dcnow.py; shared domains post once per session. - Port 1998 answers the DreamPi config_server.py JSON with CORS so dreamcast.online/now detects the emulator as a DreamPi; browser GETs get a config page and POST accepts mac=/enable/disable, which is also the only way to set the MAC without editing files (core options are enum-only). - reicast_dcnow_mac: 'auto' uses/generates flycast_dcnow.id in the save dir; a literal AA:BB:CC:DD:EE:FF claims a specific identity (e.g. a real DreamPi's MAC); uppercased before hashing like the Pi's %012X. Generated with [Devin](https://devin.ai) Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
dcnow.cpp shuts down the :1998 listen socket with SHUT_RDWR to break the accept loop; Winsock spells it SD_BOTH, so map it alongside the existing SHUT_RD/SHUT_WR definitions. Needed to build the feature on Windows/mingw. Generated with [Devin](https://devin.ai) Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
option.h: pull <cstring>/<cstdlib> in before namespace config — option_lr.h is included inside 'namespace config', so any header it includes there creates a nested config::std on toolchains where the headers were not already pulled in (clang/libc++), breaking every std:: lookup in the file. rtl8139c.cpp: <cstdlib> for calloc/free. oslib.h: <malloc.h> on _WIN32 for _aligned_malloc/_aligned_free. No functional change; needed to build the core with llvm-mingw. Generated with [Devin](https://devin.ai) Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
Owner
|
I am not sure the team behind Dreamcast Now/DreamPi would agree or be happy with this integration. Did you reach out to them to get their feeling? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds the missing pieces that make libretro Flycast behave like a real DreamPi-equipped Dreamcast for the community service ecosystem — no external Pi required:
reicast_dcnow): reports the running session to dreamcast.online with a stable player identity. The ID is a SHA-256 of a normalized MAC-derived identity, persisted inflycast_dcnow.id(save dir), so the same player keeps the same ID across sessions and can claim it on the site.config_server.py— GET returns the JSON Dreamcast Now expects, and the built-in browser page lets the user view the player ID and set a custom MAC / enable-disable presence without editing option files.reicast_dcnow_mac):autoby default; a literalXX:XX:XX:XX:XX:XXvalue (orenabledfor the generated identity) can be set through the options file or the :1998 page, since libretro core options are enum-only and can't accept free text.reicast_dns_server): intercepts the emulated Dreamcast's DNS queries and forwards them todns.flyca.st, Shuouma (46.101.91.123), the alternate DreamPi DNS (209.50.50.129), or standard DNS — covering the services DreamPi users normally get for free.Why
On DreamPi hardware all of this is "automatic": presence on dreamcast.online, the config endpoint that the site uses to find and validate the device, and DNS redirection to the community servers. Console/embedded ports (and headless libretro frontends) have no way to reproduce any of it today — the only options are buying/building a DreamPi or running the emulated Dreamcast behind one. This gives every libretro user the same experience natively.
Windows portability fixes included
Building the feature on Windows/mingw surfaced two real portability bugs, fixed in this PR:
net_platform.h:SHUT_RDWRwas unmapped on Winsock (SD_BOTH)option.h,oslib.h,rtl8139c.cpp)Verified: builds clean with llvm-mingw (clang 23) producing a working
flycast_libretro.dllwith all libretro exports, and on the libretro fork CI targets.Files
core/cfg/option.*,core/network/{CMakeLists.txt,dcnow.cpp,dcnow.h,net_platform.h,picoppp.cpp},shell/libretro/{libretro.cpp,libretro_core_options.h,option.cpp}(+ small include fixes inoslib.h,rtl8139c.cpp,option.h)Same change set as sysfce2#186 (the libretro mirror), submitted here so it lands upstream first.
Generated with Devin