1
0
mirror of https://github.com/cc65/cc65.git synced 2024-07-01 08:29:37 +00:00
Commit Graph

348 Commits

Author SHA1 Message Date
Oliver Schmidt
89329f1519 Merge pull request #287 from silverdr/target_goodies
moved output of target utils and drivers to separate directory
2016-06-01 11:01:56 +02:00
Oliver Schmidt
b979fb5763 Minor adjustment to recent change. 2016-05-30 14:31:53 +02:00
Christian Groessler
a6c306500a Small optimization in apple2 exec.s. 2016-05-30 14:16:37 +02:00
Patrycjusz R. Łogiewa
ba10c74a7a directory structure changed from driver-centric to target-centric 2016-05-16 19:49:43 +02:00
Patrycjusz R. Łogiewa
93f55c274b moved output of target utils and drivers to separate directory 2016-05-13 14:28:58 +02:00
Oliver Schmidt
e92f354740 Made use of recently added Apple scrcode macro. 2016-03-27 18:27:53 +02:00
Oliver Schmidt
29d1400340 Allow _sys() to call ROM routines.
_sys() is supposed to be (primarily) intended to call ROM routines. Leveraging the "file overlay" mechanism of the cc65 build system allows to provide a Apple II specific _sys() implementation that temporarily switches in the ROM.
2016-03-25 21:57:06 +01:00
Oliver Schmidt
e3cbc7e8b8 Moved run location of ONCE segment.
Make the same changes to the Apple II that were done with 0ee9b2e446 to the C64.

Notes:
- The startup code deliberately doesn't make use of symbols defined for the LC segment as that segment is optional.
- The <...>-asm.cfg configs move the segment BSS to an own memory area BSS although this doesn't seem necessary. However the benefit is that the size of the memeory area MAIN is identical to the number of bytes loaded from disk into RAM. To keep this an invariant for all Apple II configs allows to simplify the EXEHDR to just refer to the symbols defined for MAIN.
2016-03-17 21:07:19 +01:00
Oliver Schmidt
1d1ba3ed3b Adjusted constructors.
The constructors are _NOT_ allowed anymore to access the BSS. Rather they must use the DATA segment or the INIT segment. The latter isn't cleared at any point so the constructors may use it to expose values to the main program. However they must make sure to always write the values as they are not pre-initialized.
2016-03-16 16:28:32 +01:00
Oliver Schmidt
419eb700b5 Renamed INITBSS to INIT and INIT to ONCE.
The way we want to use the INITBSS segment - and especially the fact that it won't have the type bss on all ROM based targets - means that the name INITBSS is misleading. After all INIT is the best name from my perspective as it serves several purposes and therefore needs a rather generic name.

Unfortunately this means that the current INIT segment needs to be renamed too. Looking for a short (ideally 4 letter) name I came up with ONCE as it contains all code (and data) accessed only once during initialization.
2016-03-06 21:27:19 +01:00
Oliver Schmidt
76a5a72403 Adjusted current working directory initialization on Apple and Atari.
Moving __cwd from BSS into INITBSS does of course ;-) not only impact the CBM targets but all targets with disk I/O support.

Note: Code using `__cwd-1` may trigger an ld65 range error because __cwd may end up at the very begining of a segment. As far as I see this is an ld65 bug which I'm not try to fix - at least here.
2015-10-15 00:15:38 +02:00
Oliver Schmidt
0f1c3b0181 Fixed comment. 2015-04-27 09:39:50 +02:00
Oliver Schmidt
1748bb1ab6 Use well-known location BLTU2 for "memmove()". 2015-04-26 14:09:21 +02:00
Oliver Schmidt
3c1cd0d867 Added cmdline support to exec().
The starting point is the CALL2051:REM <cmdline> approach. It uses the BASIC input buffer at $200. ProDOS stores the name of the loaded program at $280 (which we want for argv[0]) leaving us with 128 char buffer. If we run the program via exec() we don't need the CALL2051 but only the REM token (which is just one char). So have a maximum cmdline length of 126 (plus a terminating zero).

There's no specification for ProDOS BIN file cmdline parameters so exec() just supports the CALL2051:REM <cmdline> approach. In contrast ProDOS SYS files allow for a 'startup filename'. A ProDOS filename is short than 126 chars so having exec() general cut the cmdline after 126 chars seems reasonable. If the SYS file we exec() allows for less we cut the cmdline further.

Our 'loader.system' SYS file however allows for an unusually 126 char long "startup filename" as it is targeted towards cc65 BIN porgrams with their 126 cmdline length.
2015-04-26 14:09:20 +02:00
Oliver Schmidt
ae4f9336b3 Behave more like BASIC.SYSTEM and allow for argv[0]. 2015-04-19 21:59:05 +02:00
Oliver Schmidt
24e902059c Allow up 127 chars of cmdline for programs started by the loader. 2015-04-19 21:17:46 +02:00
Oliver Schmidt
3ed3e98ec7 Moved interrupt enabling to the interrupt constructor. 2015-02-16 15:43:08 +01:00
peterferrie
bbd419f365 assert parm count 2014-11-24 10:07:16 -08:00
peterferrie
0c204725bc implement ProDOS seek 2014-11-21 16:04:11 -08:00
Greg King
c7969a78b0 Refined the comments in the target start-up files.
Fixed typo errors.  Made the comments consistent across all those files.
2014-08-24 10:10:20 -04:00
Greg King
0390c34e88 Changed multi-line C comments into another style.
The left side doesn't look unbalanced.
2014-06-30 16:51:07 -04:00
Oliver Schmidt
2c975d3642 Create static drivers directly from source files.
Up to now static drivers were created via co65 from dynamic drivers. However there was an issue with that approach:

The dynamic drivers are "o65 simple files" which obligates that they start with the 'code' segment. However dynamic drivers need to start with the module header - which is written to. For dynamic drivers this isn't more than a conceptual issue because they are always contain a 'data' segment and may therefore only be loaded into writable memory.

However when dynamic drivers are converted to static drivers using co65 then that issue becomes a real problem as then the 'code' segment may end up in non-writable memory - and thus writing to the module header fails.

Instead of changing the way dynamic drivers work I opted to rather make static driver creation totally independent from dynamic drivers. This allows to place the module header in the 'data' segment (see 'module.mac').
2014-06-04 23:50:18 +02:00
Oliver Schmidt
d6c3bd29ac Renamed JUMPTABLE and cleaned up module.cfg.
This change was suppsed to fix the issue that the former JUMPTABLE is merked as 'ro' while it is actually written to in several scenarios. When drivers are converted using co65 and then compiled into ROMs the JUMPTABLE isn't copied to RAM and therefore the write operations in question fail.

However unfortunately I didn't succeed in changing that :-( Just setting the former JUMPTABLE to 'rw' broke the drivers. So I placed the DATA segment directly after the former JUMPTABLE segment. This made the drivers converted with co65 work again - obviously after changing libsrc/Makefile:235 from '--code-label' to '--data-label'. But the actual dynamic drivers still didn't work as the former JUMPTABLE wasn't placed as the beginning of the loaded file anymore. That effect could be changed by exchanging src/ld65/o65.c:1391 with src/ld65/o65.c:1394 but doing so broke the drivers again :-((
2014-05-01 21:44:39 +02:00
Oliver Schmidt
9da0e8e600 Moved LOADER.SYSTEM description.
The LOADER.SYSTEM description is now available in the cc65 Wiki (https://github.com/cc65/cc65/wiki/LOADER.SYSTEM).
2014-03-15 18:09:55 +01:00
Oliver Schmidt
3f0af9b241 Have src/Makefile and libsrc/Make use disjoint work directories.
Building the clean target in src or libsrc should only delete stuff created by the make in those directories. Having both separated allows the Travis CI build to replace the native binaries with cross built binaries while keeping everything else.
2014-03-05 23:24:35 +01:00
Oliver Schmidt
4452156d1a Avoid indirect jmp with unknown vector address. 2014-01-26 18:10:01 +01:00
Oliver Schmidt
94eb2a2ed7 Some fine tuning of the mouse driver interface harmonization. 2014-01-17 21:09:15 +01:00
Oliver Schmidt
4065cb1983 Harmonized interface between mouse drivers and callbacks.
The Apple2 doesn't have sprites so the Apple2 mouse callbacks place a special character on the text screen to indicate the mouse position. In order to support the necessary character removing and redrawing the Apple2 mouse driver called the Apple2 mouse callbacks in an "unusual way". So far so (sort of) good.

However the upcoming Atari mouse driver aims to support both "sprite-type" mouse callbacks as well as "text-char-type" mouse callbacks. Therefore the interface between mouse drivers and callbacks needs to be extended to allow the mouse callbacks to hide their different types from the mouse driver.

The nature of this change can be seen best by looking at the Apple2 file modifications. The CBM drivers and callbacks (at least the current ones) don't benefit from this change.
2014-01-15 22:47:59 +01:00
Mario Patiño
9b157a5b1e Defined a struct to contain the date and time data
To keep backward compatibility auxtype and the date/time are kept
separated.
A struct similar to the one used in dirent.h is used to access the
create_date and create_time fields.
2013-08-03 19:08:36 +02:00
Oliver Schmidt
5ed1fac0d6 Use unique variables for cc65 toolchain.
Originally I used the usual variables (like $(CC) and $(CFLAGS) ) but after
all this doesn't make sense as any predefined values and/or user defined
settings can only be wrong.
2013-06-04 23:39:00 +02:00
Oliver Schmidt
b0dd6c614f Added library reference tgi_libref to TGI interface. 2013-06-01 12:42:00 +02:00
Oliver Schmidt
ae409e4978 Added library reference ser_libref to SER interface. 2013-06-01 11:03:14 +02:00
Oliver Schmidt
744abda24f Added library reference mouse_libref to MOU interface. 2013-06-01 00:53:17 +02:00
Oliver Schmidt
23650cb946 Added library reference joy_libref to JOY interface. 2013-06-01 00:36:08 +02:00
Oliver Schmidt
619b215260 Added library reference em_libref to EMD interface.
Occasionally dynamically drivers suffer from not being to refer to
content in the C library. Therefore I added a mechanism to allow
a C library for a certian target to define a symbol that will be
handed over to dynamic drivers for that target. Then the drivers
can use their refernce to that symbol to access content in the C
library.
2013-06-01 00:11:31 +02:00
Oliver Schmidt
85885001b1 Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
Oliver Schmidt
54c54f8499 Include targetutil intermediates in dependency handling. 2013-05-09 09:27:36 +02:00
Oliver Schmidt
e4347b5c74 Removed unintentionally committed intermediate file. 2013-05-09 09:18:19 +02:00
Oliver Schmidt
092653cb5b Added support for building targetutils. 2013-05-09 01:12:26 +02:00
Oliver Schmidt
81e467cdc2 Replaced whole bunch for Makefiles with a single generic Makefile.
- No complex shell logic.
- "Source file shadowing" for all targets via vpath.
- Dependency handling.
- True incremental build.
- Don't write into source directories.
- Easy cleanup by just removing 'wrk'.
2013-05-04 22:15:30 +02:00
Oliver Schmidt
008b4c4e1d Replaced whole bunch for Makefiles with a single generic Makefile.
- No complex shell logic.
- "Source file shadowing" for all targets via vpath.
- Dependency handling.
- True incremental build.
- Don't write into source directories.
- Easy cleanup by just removing 'wrk'.
2013-05-04 22:10:48 +02:00
Oliver Schmidt
b1c38729d0 Exclude apple2enh-only functionality from apple2 biuld on source code level. 2013-05-01 22:02:47 +02:00
Oliver Schmidt
6891862bbe Adjusted include directive for local header. 2013-05-01 21:53:30 +02:00
ol.sc
4a5bd362ac Removed unnecessary include.
git-svn-id: svn://svn.cc65.org/cc65/trunk@5988 b7a2c559-68d2-44c3-8de9-860c34a00d81
2013-02-14 16:16:57 +00:00
ol.sc
7c9171ee87 Moved IRQ hooking / unhooking from startup code to constructor / destructor to avoid linking in the hooking / unhooking code (and callirq) for the majority of cc65 prorams not linking in interruptors.
git-svn-id: svn://svn.cc65.org/cc65/trunk@5985 b7a2c559-68d2-44c3-8de9-860c34a00d81
2013-02-12 22:39:38 +00:00
ol.sc
6860ac7dfd Introduced static standard drivers.
git-svn-id: svn://svn.cc65.org/cc65/trunk@5891 b7a2c559-68d2-44c3-8de9-860c34a00d81
2012-11-01 19:53:47 +00:00
ol.sc
1bba8355da Fixed typo.
git-svn-id: svn://svn.cc65.org/cc65/trunk@5889 b7a2c559-68d2-44c3-8de9-860c34a00d81
2012-10-31 23:39:58 +00:00
ol.sc
a3c940e315 Convert dynamically loadable drivers into statically linkable drivers and add them to the target libraries.
git-svn-id: svn://svn.cc65.org/cc65/trunk@5887 b7a2c559-68d2-44c3-8de9-860c34a00d81
2012-10-29 20:26:26 +00:00
ol.sc
89d4f4a90c Introduced getcurrentdevice() and implemented it for CBM and Apple.
git-svn-id: svn://svn.cc65.org/cc65/trunk@5863 b7a2c559-68d2-44c3-8de9-860c34a00d81
2012-10-21 14:35:17 +00:00
ol.sc
272b8e7185 I wasn't aware that the unit numbers in the ProDOS device list contain device type identifiers in the low nibble. So if we can't use the device list entries as-is we can as well present the high nibble as low nibble to the user thus providing more meaningful device numbers.
git-svn-id: svn://svn.cc65.org/cc65/trunk@5852 b7a2c559-68d2-44c3-8de9-860c34a00d81
2012-10-15 21:59:51 +00:00
ol.sc
e0efad70bf Removed TABs.
git-svn-id: svn://svn.cc65.org/cc65/trunk@5849 b7a2c559-68d2-44c3-8de9-860c34a00d81
2012-10-14 12:51:02 +00:00
ol.sc
61d4b6b03f Removed DIO specific typedefs which were just aliases to basic types and replaced the term 'drive' with 'device' in order to harmonize with the recently added device.h.
git-svn-id: svn://svn.cc65.org/cc65/trunk@5847 b7a2c559-68d2-44c3-8de9-860c34a00d81
2012-10-11 18:22:49 +00:00
ol.sc
d99d5f3337 Replaced Apple II specific solution with implementation of recently introduced devicedir().
git-svn-id: svn://svn.cc65.org/cc65/trunk@5846 b7a2c559-68d2-44c3-8de9-860c34a00d81
2012-10-10 20:55:56 +00:00
ol.sc
0f1cd50883 Replaced Apple II specific solution with implementation of recently introduced mass-storage device enumaration.
git-svn-id: svn://svn.cc65.org/cc65/trunk@5821 b7a2c559-68d2-44c3-8de9-860c34a00d81
2012-09-09 13:38:32 +00:00
ol.sc
dccb0c8dde We now don't define the memory area RAM anymore. So use the segment STARTUP - as done in crt0.s.
git-svn-id: svn://svn.cc65.org/cc65/trunk@5729 b7a2c559-68d2-44c3-8de9-860c34a00d81
2012-06-16 22:58:03 +00:00
ol.sc
610bb14988 Avoid mixing of memory areas and segments in address computations (and made move of segment INIT somewhat more readable).
git-svn-id: svn://svn.cc65.org/cc65/trunk@5726 b7a2c559-68d2-44c3-8de9-860c34a00d81
2012-06-16 22:13:58 +00:00
ol.sc
95686b169e Moved actual computation of DOS 3.3 header to linker configurations:
- This will allow for different "formulas".
- This brings things together in one place.

git-svn-id: svn://svn.cc65.org/cc65/trunk@5716 b7a2c559-68d2-44c3-8de9-860c34a00d81
2012-06-14 20:44:35 +00:00
ol.sc
9cc99876b2 Moved Apple EXEHDR to separate module (similiar to CBMs).
git-svn-id: svn://svn.cc65.org/cc65/trunk@5708 b7a2c559-68d2-44c3-8de9-860c34a00d81
2012-06-10 21:05:51 +00:00
ol.sc
80a7a8df00 Moving the quit-hook towards the end of page 3 as far as possible slightly increases the compatibility with BIN programs making use of page 3 themselves.
git-svn-id: svn://svn.cc65.org/cc65/trunk@5358 b7a2c559-68d2-44c3-8de9-860c34a00d81
2012-01-02 11:09:25 +00:00
uz
7ed3fdc803 Fixed range errors when negative numbers where used as bytes. This wasn't
flagged by older ca65 versions because of errors in the range checks.


git-svn-id: svn://svn.cc65.org/cc65/trunk@5166 b7a2c559-68d2-44c3-8de9-860c34a00d81
2011-08-15 15:23:31 +00:00
uz
4026a28c60 Added a new flags byte to the TGI headers. Bumped the API version.
git-svn-id: svn://svn.cc65.org/cc65/trunk@5083 b7a2c559-68d2-44c3-8de9-860c34a00d81
2011-07-17 11:23:27 +00:00
ol.sc
ba7b4d5e86 Back to revision 3818: The value of COLOR_WHITE changed back from 3 to 1.
git-svn-id: svn://svn.cc65.org/cc65/trunk@5023 b7a2c559-68d2-44c3-8de9-860c34a00d81
2011-05-05 20:43:10 +00:00
ol.sc
b4fda77b6c The TGI kernel will call SETVIEWPAGE(0) after calling INIT so there's no need to switch to the first page here.
git-svn-id: svn://svn.cc65.org/cc65/trunk@5022 b7a2c559-68d2-44c3-8de9-860c34a00d81
2011-05-03 21:40:51 +00:00
ol.sc
4aa00e84e1 Removed tgi_load() and all corresponding infrastructure. The idea behind tgi_load() was to be able to describe a TGI mode in a target-neutral way by resolution and colordepth. However it turned out that there arn't any cc65 targets sharing any resolution. As a result the only working target-independent approach for a TGI program is to call tgi_loaddriver(tgi_stddrv); and then look up the resolution provided - and to adapt to that resolution.
git-svn-id: svn://svn.cc65.org/cc65/trunk@5016 b7a2c559-68d2-44c3-8de9-860c34a00d81
2011-05-02 10:38:48 +00:00
ol.sc
14cfadbc75 Computed pixel aspect ratio (PAR) by presuming a display aspect ratio (DAR) of 4/3 for a classic CRT and using the given driver resolutions as storage aspect ratio (SAR).
git-svn-id: svn://svn.cc65.org/cc65/trunk@5001 b7a2c559-68d2-44c3-8de9-860c34a00d81
2011-04-30 12:46:03 +00:00
ol.sc
905c1252f5 No need to explicitly set two page in 40 column mode as two pages are the default anyway.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4999 b7a2c559-68d2-44c3-8de9-860c34a00d81
2011-04-28 13:06:37 +00:00
ol.sc
5e37ed1a16 Target-specific black & white values for use by the target-shared TGI kernel
git-svn-id: svn://svn.cc65.org/cc65/trunk@4993 b7a2c559-68d2-44c3-8de9-860c34a00d81
2011-04-25 17:11:23 +00:00
ol.sc
012e3e456a Added TGI_COLOR_... macros to be used both for hires and lores. Introduced color mapping on lores to allow for common color macros.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4992 b7a2c559-68d2-44c3-8de9-860c34a00d81
2011-04-25 11:16:56 +00:00
ol.sc
98fdd6f792 Added toascii().
git-svn-id: svn://svn.cc65.org/cc65/trunk@4991 b7a2c559-68d2-44c3-8de9-860c34a00d81
2011-04-22 12:14:28 +00:00
ol.sc
a25d9bdf4b Improved exec():
- Copy the pathname to $280 for SYS programs
- Make sure 80 column firmware is off (which btw. switches to the normal character set) which should increase program compatibility
Now "only" cmdline support should be left to do.

git-svn-id: svn://svn.cc65.org/cc65/trunk@4976 b7a2c559-68d2-44c3-8de9-860c34a00d81
2011-02-11 23:22:26 +00:00
ol.sc
e4aa2a549b Added MACHID - we'll need it sooner or later...
git-svn-id: svn://svn.cc65.org/cc65/trunk@4975 b7a2c559-68d2-44c3-8de9-860c34a00d81
2011-02-11 23:15:20 +00:00
ol.sc
56d04f523f Added first implementation of exec(). No support for commandline parameters so far.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4969 b7a2c559-68d2-44c3-8de9-860c34a00d81
2011-02-06 22:27:31 +00:00
ol.sc
110f911ccb Introduced constructor to raise the ProDOS 8 file level - and extended the destructor to restore the file level again. This is a prerequisite to allow the upcoming exec() to open a file before the destructors run and continue reading from of it after the destructors have run.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4955 b7a2c559-68d2-44c3-8de9-860c34a00d81
2011-01-29 21:43:26 +00:00
ol.sc
9e31f7fb63 Set the priority of the main() args constructor to 24 simply be cause most other targets do - and adjust the priority of the dos detection constructor to stay higher than the main() args constructor.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4954 b7a2c559-68d2-44c3-8de9-860c34a00d81
2011-01-29 21:39:17 +00:00
ol.sc
d2f59fb8b0 The constructor doesn't have any interaction with other constructors so there seems to be no need for a priority at all.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4953 b7a2c559-68d2-44c3-8de9-860c34a00d81
2011-01-29 21:36:18 +00:00
uz
a9990fbcf3 Changed priorities of destructors so atexit will be called before open files
are closed on exit, so atexit handlers may close the files themselves or
whatever is necessary for a clean shutdown.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4939 b7a2c559-68d2-44c3-8de9-860c34a00d81
2011-01-28 10:55:03 +00:00
ol.sc
76c543a26f Saved two bytes.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4924 b7a2c559-68d2-44c3-8de9-860c34a00d81
2011-01-26 22:11:23 +00:00
ol.sc
b4c237b2b1 Minor beautification.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4922 b7a2c559-68d2-44c3-8de9-860c34a00d81
2011-01-26 21:37:42 +00:00
ol.sc
bee54df029 Allow to set the ProDOS type and auxtype on creating new files in a similiar way done on the CBMs.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4902 b7a2c559-68d2-44c3-8de9-860c34a00d81
2011-01-05 16:09:08 +00:00
uz
fa1b5047dd Fixed order of options in call to ld65, which became important after the
latest changes.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4843 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-11-09 21:33:14 +00:00
ol.sc
07680d2376 Read number of total blocks from ProDOS 8 volume directory header - and fall back on the constant 280 only for non-ProDOS 8 disks.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4750 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-07-17 19:16:25 +00:00
ol.sc
f15910e5f1 Made use of the new common __directerrno and __mappederrno function.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4749 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-07-17 19:13:07 +00:00
ol.sc
b1dab3a37d Use MLI error names from ProDOS 8 Technical Reference Manual Quick Reference Card (and not Section 4.8 !).
git-svn-id: svn://svn.cc65.org/cc65/trunk@4748 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-07-17 19:11:51 +00:00
ol.sc
b9740f52e2 Saved one byte.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4747 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-07-17 19:07:57 +00:00
ol.sc
f1d7044b7c Adjusted parameter handling to match prototype.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4733 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-07-07 22:28:14 +00:00
ol.sc
51d4a5bf79 Use MLI error names from ProDOS 8 Technical Reference Manual (and ProDOS 8 Technical Note #21).
git-svn-id: svn://svn.cc65.org/cc65/trunk@4724 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-06-16 21:21:01 +00:00
ol.sc
a0359724ff - Use ProDOS 8 unit number as parameter.
- Don't access the drive, just check its presence.

git-svn-id: svn://svn.cc65.org/cc65/trunk@4723 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-06-16 21:19:47 +00:00
ol.sc
ab068d43e3 Use MLI error names from ProDOS 8 Technical Reference Manual (and ProDOS 8 Technical Note #21).
git-svn-id: svn://svn.cc65.org/cc65/trunk@4722 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-06-16 21:16:14 +00:00
ol.sc
148a6569e5 Clear __oserror on success.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4721 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-06-15 21:44:18 +00:00
ol.sc
155c5629a9 Make use of the new common __directerrno and __mappederrno function.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4720 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-06-15 20:38:05 +00:00
ol.sc
5741b6e7d3 Minor comment style adjustment.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4717 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-06-07 19:20:10 +00:00
ol.sc
2273b7575c DIO functions always set _oserror.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4715 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-06-04 21:41:22 +00:00
ol.sc
1568376fbf Adjustment to recent change in ca65 relative include path handling.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4713 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-06-04 20:58:40 +00:00
ol.sc
c8c604f353 Minor optimization.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4712 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-06-04 20:52:52 +00:00
ol.sc
710f59b654 Align rootdir() return value rather with POSIX functions than with DIO functions.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4680 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-06-02 07:03:54 +00:00
ol.sc
2e0ab6f863 Set _oserror only on error.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4679 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-06-01 21:01:59 +00:00
ol.sc
05b23194d9 Added function to find out the volume name of a ProDOS 8 disk in a ProDOS 8 device.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4668 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-05-26 21:02:35 +00:00
ol.sc
1bbbed5e96 Added functions to learn about the unit numbers of the ProDOS 8 devices found.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4663 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-05-24 20:10:19 +00:00
ol.sc
186657e5ad Save some cycles.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4646 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-04-22 19:51:34 +00:00
ol.sc
47a8b9191a Minor reformatting.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4557 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-01-24 14:53:48 +00:00
ol.sc
e9f69ad123 Factored out generic LINE implementation based on SETPIXEL from the three drivers previously containing the identical code.
Note: Originally I planned to create a module to be linked to the driver. However this turned out to cause quite some issues with the Makefiles - especially on the Apple2 where one driver uses to generic LINE implementation and the other doesn't. The final Makefile was so ugly that I rather opted for including the code in question on source level. In order to avoid to unwanted cross dependencies the whole .inc file content is wrapped in its own scope.

git-svn-id: svn://svn.cc65.org/cc65/trunk@4553 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-01-24 11:21:44 +00:00
ol.sc
246a8db9ac Some optimization.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4546 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-01-08 23:09:02 +00:00
ol.sc
c71c75c162 - Added ioctl for mixing graphics with 4 lines of text.
- Preserve drawing color during CLEAR.

git-svn-id: svn://svn.cc65.org/cc65/trunk@4545 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-01-08 22:45:59 +00:00
ol.sc
c3ef1369f3 Minor comment adjustment.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4544 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-01-08 22:24:38 +00:00
ol.sc
651df0889c Minor comment adjustment.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4531 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-12-19 13:09:57 +00:00
ol.sc
8ea7c876d6 Added macro for ssc slot selection.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4528 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-12-13 11:23:20 +00:00
ol.sc
fd82520622 Added ioctl for mixing graphics with 4 lines of text.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4521 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-12-12 23:06:58 +00:00
ol.sc
6b148748a9 Replaced left-over tab with space.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4510 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-12-09 18:16:02 +00:00
ol.sc
1bec071755 - Replaced font .byte's with font .incbin file
- Adjusted font width declaration from 8 to 7
- Modified font using Beagle Bros Shape Mechanic font editor to look like Apple2 text mode glyphs (with the exception of '_' because OUTTEXT _always_ inserts 2 empty pixels between chars)

git-svn-id: svn://svn.cc65.org/cc65/trunk@4437 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-11-03 22:20:48 +00:00
ol.sc
9fa0acfefc Removed unintentionally added line.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4430 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-11-02 22:10:13 +00:00
ol.sc
2fcb498f58 Removed generic macpack
git-svn-id: svn://svn.cc65.org/cc65/trunk@4429 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-11-02 21:54:51 +00:00
ol.sc
4b601bea40 - Adjusted TEXTSTYLE and OUTTEXT to TGI specs
- Removed defunct scaling support from TEXTSTYLE
- Optimized OUTTEXT
- Clarified font source and format
- Removed generic macpack

git-svn-id: svn://svn.cc65.org/cc65/trunk@4428 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-11-02 21:38:18 +00:00
ol.sc
6da8c5639c Changes to the TGI driver API:
* Removed CIRCLE
  * Aspect ratio is a new header variable
  * Removed the reserved bytes - it's easier to bump the API version
  * Clipping is done completely in the wrapper

git-svn-id: svn://svn.cc65.org/cc65/trunk@4407 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-10-30 21:44:36 +00:00
ol.sc
50c1db0331 Changes to the TGI driver API:
* Removed CIRCLE
  * Aspect ratio is a new header variable
  * Removed the reserved bytes - it's easier to bump the API version
  * Clipping is done completely in the wrapper

git-svn-id: svn://svn.cc65.org/cc65/trunk@4398 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-10-29 23:11:46 +00:00
ol.sc
5f609164d6 This is what was actually meant in the first place.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4279 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-30 08:04:34 +00:00
uz
9329908927 Stefan Haubenthal fixed a few typos.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4252 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-28 07:29:56 +00:00
ol.sc
fd0fa0241e Adjusted driver to the recent kernel interface change (code rearrange ment necessary to stay in 6502 branch reach).
git-svn-id: svn://svn.cc65.org/cc65/trunk@4251 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-27 23:26:41 +00:00
ol.sc
dfc6162e91 Fixed bug triggered if all 8 io buffer slots may be used.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4242 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-26 21:32:05 +00:00
uz
8be28482ac Remove this copy of the apple include file - a copy was added to asminc
before and we don't need it twice.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4229 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-25 13:46:18 +00:00
uz
5c5d01d84a Moved most platform assembler includes into asminc, so they will be available
in the distribution. 
Added --forget-inc-paths to the command line of the assembler in the
Makefiles, because the assembler does now have builtin paths and will find
include files from an installation first.
Hopefully fixed any problems that arose from the two changes.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4223 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-24 17:44:22 +00:00
uz
0508d655f1 Fixed an error.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4213 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-22 19:10:46 +00:00
uz
90b7dd065d Build files in the extra directory.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4212 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-22 19:00:12 +00:00
ol.sc
5c35c213f6 Added author hint - as contained in the other source files.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4211 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-22 17:30:50 +00:00
ol.sc
6345e4b0cd Added alternative implementation for ProDOS 8 I/O buffer management. The purpose of this implementation is to avoid pulling in the heap stuff (and especially the C-written posix_memalign() function) into small file utility-like applications. It saves in this scenario > 1400 Bytes. It manages memory blocks between $0800 and the cc65 start address. This is especially usefull for the now supported "native" SYS programs starting at $2000.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4210 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-22 17:29:49 +00:00
ol.sc
0c161a6cdd Now that cc65 programs can run as SYS files themselves my ProDOS Loader ulimately has to change from a minimalistic shell replacement to a pure loader (without exit hook). This approach simplifies several things. However the "reboot after exit" option now present as a ProDOS Loader variant has to move into the cc65 program.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4172 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-14 19:58:06 +00:00
ol.sc
b7df1ed5d4 Being loaded by my 'ProDOS Loader' needs to be classified as being loaded as BIN from an interpreter (and not as SYS). But the 'ProDOS Loader' zeros the system bitmap up to the system global page (this is what it's about) so additionally check page $03 protection which is zero when loaded as SYS but one when loaded by 'ProDOS Loader 1.4'.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4168 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-13 19:50:09 +00:00
ol.sc
c271f18d00 Hooking into the MLI call needs much more thoughts - and is currently not necessary...
git-svn-id: svn://svn.cc65.org/cc65/trunk@4159 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-12 20:55:20 +00:00
ol.sc
2b98ab38f7 Addon to 4155: Fixed error.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4157 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-12 06:58:20 +00:00
ol.sc
736db8789e Much better approach for ProDOS 8 IO-buffer custom implementations - the first one was actually kind of stupid.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4155 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-11 19:54:29 +00:00
ol.sc
c8e1d7e0d2 Adjusted Apple2 targets to the new standard mouse driver paradigm.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4154 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-11 19:35:13 +00:00
uz
7de61e351c Define a standard driver and mode for tgi graphics and use it in the sample
program. The standard driver and mode is the first one in the tgi_mode_table.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4153 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-11 18:59:37 +00:00
ol.sc
aeccd3a776 Allow to run programs as ProDOS SYS files (beside BIN files). To do so detect at runtime if BASIC.SYSTEM is present by checking the "signature" of the last system bitmap byte.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4146 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-11 16:27:20 +00:00
ol.sc
773e05b5f3 Removed '_' prefix from textframe(xy) because this prefix for non-standard symbols isn't necessary if they are declared in non-standard include files.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4143 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-10 19:18:15 +00:00
ol.sc
d91fe6b877 ProDOS 8 requires an page-aligned 1kB IO-buffer for every open file. The implementation using posix_memalign() is universally correct but quite expensive. There I added support for overriding this implementation with maybe limited (i.e. to one open file) but cheaper custom implementations.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4142 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-10 09:59:26 +00:00
ol.sc
19397b742d Fixed typo.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4141 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-10 09:35:37 +00:00
ol.sc
648a1b5427 Added support for switching between 40/80 columns. As the Apple //e 80 column firmware features converting the current screen content on switching if was already active before the idea is to keep the 80 column firmware active and initialize it (which clears the screen) only if necessary.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4140 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-10 09:04:05 +00:00
ol.sc
96b731dd96 Just presume alternate charset to be active on the //e - how shouldn't it if conio usage activates it.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4127 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-07 14:00:17 +00:00
ol.sc
78a7af13e6 Adjusted to the changed default start address.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4120 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-04 21:32:41 +00:00
ol.sc
0d25264ed4 Minor reformatting.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4119 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-04 21:28:16 +00:00
uz
8216bf1d6a Force an import of the special symbol __STARTUP__ in the C compiler when
main() is encountered. Define this symbol in the startup code. This will
automatically force linking of the startup code which can then reside inside
the standard library as any other object file.


git-svn-id: svn://svn.cc65.org/cc65/trunk@3988 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-07-31 12:05:42 +00:00
uz
2363a6f5c7 Move common data and ex-/imports into an assembler include named time.inc.
git-svn-id: svn://svn.cc65.org/cc65/trunk@3972 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-07-27 17:59:27 +00:00
uz
4812feb44b git-svn-id: svn://svn.cc65.org/cc65/trunk@3863 b7a2c559-68d2-44c3-8de9-860c34a00d81 2008-08-02 22:02:54 +00:00
cuz
258a8e7d4c Move zpsave into its own segment to decrease the executable size.
git-svn-id: svn://svn.cc65.org/cc65/trunk@3852 b7a2c559-68d2-44c3-8de9-860c34a00d81
2008-07-15 18:34:20 +00:00
cuz
966843dc1d The value of COLOR_WHITE changed from 1 to 3.
git-svn-id: svn://svn.cc65.org/cc65/trunk@3818 b7a2c559-68d2-44c3-8de9-860c34a00d81
2008-03-25 19:08:26 +00:00
cuz
1a5a724f1b Removed obsolete files.
git-svn-id: svn://svn.cc65.org/cc65/trunk@3817 b7a2c559-68d2-44c3-8de9-860c34a00d81
2008-03-25 19:07:52 +00:00
cuz
feae688346 Oliver Schmidt updated the graphics drivers and part of the C library for the
Apple machines.


git-svn-id: svn://svn.cc65.org/cc65/trunk@3816 b7a2c559-68d2-44c3-8de9-860c34a00d81
2008-03-16 09:37:22 +00:00
cuz
b8293aaf8a New version by Oliver Schmidt
git-svn-id: svn://svn.cc65.org/cc65/trunk@3767 b7a2c559-68d2-44c3-8de9-860c34a00d81
2007-01-24 21:07:11 +00:00
cuz
88aedc2e29 Update from Oliver Schmidt
git-svn-id: svn://svn.cc65.org/cc65/trunk@3766 b7a2c559-68d2-44c3-8de9-860c34a00d81
2007-01-05 16:16:34 +00:00
cuz
620f19464d Added build rules for the apple2-auxmem driver.
git-svn-id: svn://svn.cc65.org/cc65/trunk@3763 b7a2c559-68d2-44c3-8de9-860c34a00d81
2006-08-18 16:40:45 +00:00
cuz
c784f056f7 New extended memory driver by Stefan Haubenthal.
git-svn-id: svn://svn.cc65.org/cc65/trunk@3762 b7a2c559-68d2-44c3-8de9-860c34a00d81
2006-08-17 19:50:23 +00:00