Commit Graph

41 Commits

Author SHA1 Message Date
Bobbi Webber-Manners 95615458aa Rebased on latest IP65. Needs latest CC65 to build. 2022-09-14 13:02:41 -04:00
Bobbi Webber-Manners 10eaf46a8d EDIT: change all sprintf()->snprintf(); Add prompting to save_all(). 2020-08-16 17:19:23 -04:00
Oliver Schmidt 6971e9216f Added central error strings. 2020-04-15 14:52:59 +02:00
Oliver Schmidt 0fb3869716 Added support for the upcoming 'Dracarys' ATARI PBI device.
See https://atariage.com/forums/topic/287376-preannouncement-dragon-cart-ii/
2019-05-08 17:23:00 +02:00
Oliver Schmidt 4577c2ab19 Removed Ethernet driver I/O base.
So far the base address of the Ethernet chip was a general property of all Ethernet drivers. It served two purposes:
1. Allowing to use a single Ethernet driver for a certain Ethernet chip, no matter what machine was connected to the chip.
2. Allowing use an Ethernet card in all Apple II slots.

However, we now use customized Ethernet drivers for the individual machines so 1.) isn't relevant anymore. In fact one wants to omit the overhead of a runtime-adjustable base address where it isn't needed.

So only the Apple II slots are left. But this should rather be a driver-internal approach then. We should just hand the driver the slot number the user wants to use and have the driver do its thing.

Independently from the aspect if the driver parameter is a base address or a slot number the parameter handling was changed too. For asm programs there was so far a specific init function to be called prior to the main init function if it was desired to chnage the parameter default. This was done to keep the main init function backward compatible. But now that the parameter (now the slot number) is only used on the Apple II anyhow it seems reasonable to drop the specific init function again and just provide the parameter to the main init function. All C64-only user code can stay as-is. Only Apple II user code needs to by adjusted. Please note that this change only affects asm programs, C programs always used a single init function with the Apple II slot number as parameter.
2019-05-02 14:44:24 +02:00
Oliver Schmidt 6a296b2058 Improved URL selector handling.
parse_url stores the URL selector in the output_buffer - which is currently 520 bytes. A new entry point called parse_url_buffer was added which instead stores the URL selector in a buffer provided by the user.

url_download now calls the new parse_url_buffer instead of parse_url. The buffer for the URL selector is simply the download_buffer. So the download_buffer is used twice: First to hold the URL selector to be sent as request to the server and then to hold the response received from the server.

However, the URL selector still can't exceed the MSS (aka 1460 bytes).

Note: The User-Agent string was shortened by two bytes as that allows a "default" URL (incl. 'http://' but without port number) of exactly 1400 bytes to end up as 1460 bytes URL selector.
2018-11-13 13:19:47 +01:00
Oliver Schmidt 41de6a76bd Allow URLs and URL selectors > 255 chars.
Note: The URL selector is stored in the output_buffer - which is currently 520 bytes. Beside all of the URL (apart from a potential "http://") the 'get' and the 'http_preamble' have to fit into that buffer. Therefore URLs mustn't exceed 450 chars. However, we omit a check to avoid further code size increase as most of the time URLs are known to be much shorter anyhow. If the URLs might become large we just leave it up to the user to check their length.
2018-10-30 22:02:47 +01:00
Oliver Schmidt 4ef85827db Replaced version file with hard coded identifier.
Have the HTTP client work in just the same way the HTTP server does.
2018-08-01 19:00:39 +02:00
Oliver Schmidt 6eb4aef0e8 Enhanced C interface to user input control. 2018-08-01 19:00:39 +02:00
Oliver Schmidt 0bd53f3af7 Added C interface to Ethernet driver configuration. 2018-08-01 19:00:39 +02:00
Oliver Schmidt 6ba4a5bae0 Minimal style consistency improvements. 2018-07-21 18:46:25 +02:00
Oliver Schmidt 3fb437f7cb Added C interface to URL functions. 2018-07-20 18:12:51 +02:00
Oliver Schmidt c1ddcbc5af Added C interface to TFTP functions. 2018-07-20 14:51:20 +02:00
Oliver Schmidt 25ebdca045 Use standard types. 2018-07-19 15:35:03 +02:00
Oliver Schmidt d4f7569278 Removed last KPR_* constants. 2018-02-23 16:41:33 +01:00
Oliver Schmidt c89a2ae1ba Adjusted include file extension to ca65 practice. 2018-02-23 16:36:05 +01:00
Oliver Schmidt b84527c8a3 Removed last KIPPER leftover. 2018-02-23 16:33:21 +01:00
Oliver Schmidt 3c88dec698 Removed unused stuff. 2018-02-23 15:53:03 +01:00
Oliver Schmidt e3077a46a5 Normalized language. 2018-02-22 22:40:52 +01:00
Oliver Schmidt 7090fb5bdd Allow C programs to set the Apple II slot number. 2018-02-22 22:33:47 +01:00
Oliver Schmidt 673e2da011 Added C interface to HTTPD functions. 2017-12-07 23:03:04 +01:00
Oliver Schmidt 2045754236 Made error constants actually usable from C code. 2017-11-09 21:46:40 +01:00
Oliver Schmidt e6684904cf Made tcp_listen return the client IP address.
Together with the recent change to provide the inbound data buffer address and length to the TCP callback function as C parameters this change allows the TCP API to get along without any global variable :-)
2017-11-08 20:59:06 +01:00
Oliver Schmidt e1bf89d1a8 Use parameters for TCP C callback.
In contrast to the multiple UDP callbacks there's only one TCP callback so it easy to provide a wrapper for the C callback that pushes C parameters on the stack.
2017-11-07 23:05:05 +01:00
Oliver Schmidt 9a8ba804bc Added C interface to TCP functions. 2017-11-06 23:36:44 +01:00
Oliver Schmidt c6efcebf97 Added C interface to timer handling. 2017-11-05 23:16:34 +01:00
Oliver Schmidt 3c9ab2eb5f Added C interface to abort key control. 2017-11-05 22:55:55 +01:00
Oliver Schmidt 6680772b04 Introduced C interface to IP65.
The IP5 usage of ld65 segments and zeropage variables was made compatible with cc65 C programs already a while ago. This commit is the next logical step which is to introduce the actual C interface to IP65.

IP65 for C programs shares the the ip65.lib / ip65_tcp.lib with IP65 for assembler programs. However the various libraries from the 'drivers' are not reused. Instead there's exactly one library for every target named ip65_<target>.lib. Those libraries contain only functions used by ip65.lib / ip65_tcp.lib.

TODOs:

- Introduce c64_timer.s and atr_timer.s.
- Add a C interface to the rest of the IP65 functionality (especially TCP).
2017-11-05 14:28:49 +01:00
Oliver Schmidt 9fb964c828 Generalized Apple II slot setting.
In order to allow setting the Apple II slot from host computer independent code the slot setting function was renamed and dummies were added for the other host computers.
2017-06-04 00:10:36 +02:00
Oliver Schmidt ae98e5c01d Removed cfg_get_configuration_ptr.
cfg_get_configuration_ptr was introduced for NB64 - which is out of scope for this IP65.
2015-07-08 16:20:47 +02:00
Oliver Schmidt e451b74b07 Made use of recent changes for the web server demo.
The Apple 2 web server now uses the "combo" library and optionally uses a2_set_slot to scan all slots for the Ethernet card. Combining both with DHCP allows for complete auto configuration.
2015-07-08 15:51:59 +02:00
Oliver Schmidt 8279ef4d63 Introduced IP65 "combo" libraries.
Up to now every IP65 library contained exactly one Ethernet driver. In scenarios without strict memory limitations I might however be benefitial to have an IP65 library containing all Ethernet drivers available for a given target.

The Ethernet hardware detection that was already present before is used in this scenario to try to initialize one Ethernet driver after the other until one succeeds. If all drivers fail to initialize the user gets informed as usual.

The WIZ811MJ driver was primarily introduced for orthogonality reasons. There are however at least two W5100-based prototypes for the C64 so it makes at least some sense. The name was chosen as sort of placeholder for "something containing a W5100 chip".
2015-07-08 10:13:08 +02:00
Oliver Schmidt 90dacb979e Added some linefeeds to clean up console output. 2015-04-13 22:38:55 +02:00
Oliver Schmidt 2ae35b34d9 Replaced custom zeropage variables with cc65 default zeropage variables. 2014-07-07 20:56:21 +02:00
Oliver Schmidt e54bb71bcc General source code cleanup.
- Tab chars were partially used with the unusual width of two blanks. I removed them altogether.
- Line endings were inconsistent even iniside individual files. I normalized them.
- I introduced a consistent coding style regarding comment indenting and blank line usage.
- I removed trailing spaces.
- I removed newlines following unnamed labels.
- ...
2013-12-27 14:57:56 +01:00
Oliver Schmidt e1c4a4caf6 Some more cleanup.
- Removed VT100 font belonging to NETBOOT65.
- Removed machine / cart specific tests.
- Have Makefiles ignore errors on the clean goal.
2013-12-27 14:48:16 +01:00
Oliver Schmidt ecdaac2ff8 Distilled IP65 out of NETBOOT65. 2013-12-13 22:24:03 +01:00
jonnosan 401effa912 restructure source tree to get better split between client (ca65) and server (ruby) files
git-svn-id: http://svn.code.sf.net/p/netboot65/code@13 93682198-c243-4bdb-bd91-e943c89aac3b
2009-01-22 01:15:28 +00:00
jonnosan 90aa476625 fixed bug affecting printing of strings that crossed a page boundary
git-svn-id: http://svn.code.sf.net/p/netboot65/code@5 93682198-c243-4bdb-bd91-e943c89aac3b
2009-01-10 12:45:57 +00:00
jonnosan b035d8a091 git-svn-id: http://svn.code.sf.net/p/netboot65/code@4 93682198-c243-4bdb-bd91-e943c89aac3b 2009-01-10 12:04:57 +00:00
jonnosan 5456aff2a8 git-svn-id: http://svn.code.sf.net/p/netboot65/code@1 93682198-c243-4bdb-bd91-e943c89aac3b 2009-01-10 08:41:35 +00:00