simonowen / trinload

Quazar Trinity network code loader for the SAM Coupe.
4 stars 1 forks source link

Add note that static IP is required #5

Open petemoore opened 1 year ago

petemoore commented 1 year ago

I figured it was simpler to add a comment than implement it! 😆

simonowen commented 1 year ago

It does require a static IP but it uses the one that was configured during the official Trinity setup process. If it can't find the network settings in the EEPROM it will fail with an error saying that they're missing.

Is it worth clarifying that the IP address is not configured as part of TrinLoad itself?

simonowen commented 1 year ago

I skipped adding DHCP as I thought anyone with a Trinity interface would have configured an address to use. Though the protocol seems simple, and as long as it's happy not to have any UDP checksums set it could be fairly quick to implement.

I like the idea of it falling back to DHCP if there are no settings, or perhaps using that if a key is held during boot. I'll stick it on the list... :)

petemoore commented 1 year ago

It does require a static IP but it uses the one that was configured during the official Trinity setup process.

I think in the trinity setup process, you are not required to specify a static IP, but can configure the interface to use DHCP. But I don't think it will actually then use DHCP negotiation to configure a static IP address. In other words, when the setup completes, the IP address stored in the EEPROM will still be 0.0.0.0. So I think the user just needs to be aware that they shouldn't use the DHCP option in that setup program, and instead manually configure an IP address (and e.g. also reserve it in their dhcp server configuration so that it doesn't get assigned to a different host).

If it can't find the network settings in the EEPROM it will fail with an error saying that they're missing.

That seems perfect.

Is it worth clarifying that the IP address is not configured as part of TrinLoad itself?

Absolutely! I didn't make this very clear, so I'll adapt the wording to say that the network settings need to be configured using trinload setup program, and DHCP shouldn't be used there.

petemoore commented 1 year ago

I skipped adding DHCP as I thought anyone with a Trinity interface would have configured an address to use. Though the protocol seems simple, and as long as it's happy not to have any UDP checksums set it could be fairly quick to implement.

I like the idea of it falling back to DHCP if there are no settings, or perhaps using that if a key is held during boot. I'll stick it on the list... :)

I think it is reasonable to require that the interface has been configured (so if it hasn't, that the user is informed that they need to configure their network interface) - so I think your current handling of having no configuration is perfectly fine. I think it would be nice, if the interface is configured to use DHCP, that trinload could then do the negotiation, but I think this also isn't critical, as most people can probably work around it.