Skip to content

Conversation

@FozzTexx
Copy link
Contributor

@FozzTexx FozzTexx commented Nov 4, 2025

This should fix the problem with NetSIO.

@FozzTexx FozzTexx requested a review from markjfisher November 4, 2025 03:40
@markjfisher
Copy link
Contributor

markjfisher commented Nov 4, 2025

Still failing on both config (v1.5.1) and config-ng against fujinet-pc.
Same symptoms as yesterday but in non-esp32; it's looping on same command many times.

From logs trying to boot config v1.5.1.
Note commit id in startup

Startup:

07:59:17.262704 > --~--~--~--
07:59:17.262705 > FujiNet v1.5.1+git-841e3d30 2025-11-04 03:38:22 (ATARI) Started @ 0
07:59:17.262709 > Detected Hardware Version: fujinet-pc
07:59:17.262712 > SPIFFS mounted.
07:59:17.262714 > SD mounted (directory "SD").
07:59:17.262716 > fnConfig::load "fnconfig.ini"
07:59:17.262725 > fnConfig::load read 1124 bytes from config file
07:59:17.262744 > Reading wifi section
07:59:17.262763 > disk UNMOUNT
07:59:17.262766 > FileSystemSPIFFS::filehandler_open /autorun.atr rb
07:59:17.262769 > disk MOUNT
07:59:17.262770 > ATR MOUNT
07:59:17.262774 > mounted ATR: paragraphs=5760, sect_size=128, sect_count=720, disk_size=0
07:59:17.262783 > PCLINK[1] MOUNT "SD"
07:59:17.262785 > Creating a default printer using FS_SDFAT storage and type 1
07:59:17.262791 > SIO SETUP
07:59:17.262794 > NetSIO: No WiFi!
07:59:17.262795 > Suspending NetSIO for 400 ms
07:59:17.262796 > Set HSIO baud from 19200 to 57600 (index 8)
07:59:17.262798 > Setup complete @ 0 (0ms)
07:59:17.262799 > DummyWiFiManager::start
07:59:17.262803 > Starting web server http://0.0.0.0:8000
07:59:17.262869 > DummyWiFi connect to SSID "Dummy Cafe"
07:59:17.662000 > Setting up NetSIO (localhost:9997)
07:59:17.662020 > Resolving hostname "localhost"
07:59:17.662527 > Resolved to address 127.0.0.1
07:59:17.662631 > NetSIO ping localhost time=0.073 ms
07:59:17.662639 > ### NetSIO initialized ###
07:59:17.662640 > NetSIO set_baudrate: 19200
07:59:20.186897 > NetSIO peer baudrate: 127840
07:59:21.915972 > NetSIO peer baudrate: 19040

Then booting config, it loops on doing WIFI ENABLED check

07:59:21.916125 >
07:59:21.916127 > CF: 70 ea 00 00 5b
07:59:21.916688 > sioFuji::sio_process() called, baud: 19200
07:59:21.917012 > ACK!
07:59:21.917014 > Fuji cmd: GET WIFI ENABLED: 1
07:59:21.917016 > ->SIO write 1 bytes
07:59:21.917324 > COMPLETE!
07:59:21.917379 > SIO CMD processed in 2 ms
07:59:22.059379 >
07:59:22.059386 > CF: 70 ea 00 00 5b
07:59:22.059944 > sioFuji::sio_process() called, baud: 19200
07:59:22.060259 > ACK!
07:59:22.060260 > Fuji cmd: GET WIFI ENABLED: 1
07:59:22.060261 > ->SIO write 1 bytes
07:59:22.060569 > COMPLETE!
07:59:22.060612 > SIO CMD processed in 1 ms
07:59:22.164207 >
07:59:22.164215 > CF: 70 ea 00 00 5b
07:59:22.164771 > sioFuji::sio_process() called, baud: 19200
07:59:22.165084 > ACK!
07:59:22.165086 > Fuji cmd: GET WIFI ENABLED: 1
07:59:22.165087 > ->SIO write 1 bytes
07:59:22.165427 > COMPLETE!
07:59:22.165435 > SIO CMD processed in 1 ms
07:59:22.307080 >
07:59:22.307082 > CF: 70 ea 00 00 5b
... etc

@FozzTexx
Copy link
Contributor Author

FozzTexx commented Nov 4, 2025

Strange, it comes up ok in the emulator I've been testing in.

image

@FozzTexx
Copy link
Contributor Author

FozzTexx commented Nov 4, 2025

Can you try this branch and see if it works? If not, can you bisect it and see which commit it breaks at? I started at 31f6107 and kept making incremental commits.

https://github.com/FozzTexx/fujinet-platformio/tree/netsio-siocom-1-class

@markjfisher
Copy link
Contributor

The failing commit is 46be02c:

fujinet-firmware-master on  HEAD (70a76ed) (BISECTING) via △ v4.1.2 via 🐍 v3.13.7
❯ git bisect good
46be02c15099d0c88a12f517470de958e5fd7f5f is the first bad commit
commit 46be02c15099d0c88a12f517470de958e5fd7f5f
Author: Chris Osborn <[email protected]>
Date:   Mon Nov 3 19:27:44 2025 -0800

    Inherits from IOChannel

 lib/bus/sio/NetSIO.cpp | 30 +++++++++++++++++++++++++++++-
 lib/bus/sio/NetSIO.h   | 18 ++++++++++++++++--
 2 files changed, 45 insertions(+), 3 deletions(-)

@markjfisher
Copy link
Contributor

I'm using Altirra with the python bridge which has always been rock solid.
I think atari800 has a different implementation of the NetSIO built into application.

@FozzTexx
Copy link
Contributor Author

FozzTexx commented Nov 4, 2025

I'm using Altirra with the python bridge which has always been rock solid. I think atari800 has a different implementation of the NetSIO built into application.

Guess I'm spending the day trying to figure out how to run Altirra and reproduce. 😅

@markjfisher
Copy link
Contributor

markjfisher commented Nov 4, 2025

I'm using Altirra with the python bridge which has always been rock solid. I think atari800 has a different implementation of the NetSIO built into application.

Guess I'm spending the day trying to figure out how to run Altirra and reproduce. 😅

not sure if your distro has it in (arch AUR does).
I run this on my linux box:

altirra config-v1.5.1.com

The bridge is run with:

cd fujinet-emulator-bridge/fujinet-bridge
python3 -m netsiohub

Obviously you have to run a fujinet-pc too.

You'll need to setup your ROMs in Altirra.
In System/Configure System, Computer/Firmware, click the "Firmware Manager..." button

These are the high level ROMs I have installed:

image

You can dump the ROMs in a folder and add them all in one go, it detects most types. I'll send you a pack.

To configure Altirra to use the bridge:
System/Configure System, Peripherals/Devices
Click "Add..." and right at the bottom of the list is "Other devices/Custom device".
Click that and choose the "netsio.atdevice" from the emulator-bridge/altirra-custom-device folder.
If you're on WINE, you'll have to pick it from the Z drive. My path is:
image

You will then have a custom device that talks to the bridge:
image

If the bridge isn't up, it will show an error.

Now you can exit altirra (it should save config to a default place) and then you can rerun your altirra commad again.

If you're running wine directly, you can run something like

wine /path/to/Altirra64.exe

That should be enough to get going.

You can also create/use "portable" config files for altirra and run it with:

wine /path/to/Altirra64.exe /portable /portablealt:my-altirra.ini

and that will create a local file instead of affecting your global one.
It'll create it if it's missing, then use it next time around and update it with any device changes etc.

I find that's a better way to manage it, so you can copy the ini file around.

@FozzTexx
Copy link
Contributor Author

FozzTexx commented Nov 4, 2025

Got altirra running and I'm able to reproduce the problem at the same commit.

@FozzTexx
Copy link
Contributor Author

FozzTexx commented Nov 4, 2025

Works for me in Altirra now

@markjfisher
Copy link
Contributor

Same here. Excellent!

@markjfisher markjfisher merged commit ed96d7e into FujiNetWIFI:master Nov 5, 2025
36 of 42 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants