1
0
mirror of https://github.com/cc65/cc65.git synced 2024-07-05 06:28:57 +00:00
Commit Graph

154 Commits

Author SHA1 Message Date
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
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
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
uz
7252f071a2 Changed the startup module and the linker config for the C128 to use the
common loadaddr and exehdr modules.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4872 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-11-17 13:00:34 +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
d1f5b74f01 Now that we reduce the size of the RAM memory area by the stacksize in the linker configuration we need to add the stacksize to end of the RAM area when setting the initial stack pointer in the startup code.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4822 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-10-02 10:37:20 +00:00
uz
09adce2fec Added patches to make systime work correctly with the different video systems
(Stefan Haubenthal).


git-svn-id: svn://svn.cc65.org/cc65/trunk@4624 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-03-19 20:46:56 +00:00
uz
21c38fa7db Removed a forgotten ScrollSave variable (Stefan Haubenthal).
git-svn-id: svn://svn.cc65.org/cc65/trunk@4623 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-03-17 17:09:24 +00:00
uz
44852e317e Shortened the code
git-svn-id: svn://svn.cc65.org/cc65/trunk@4620 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-03-08 18:40:55 +00:00
uz
9656dde9e3 Fix scrolling (again). The old code switched off scrolling completely, as a
consequence it didn't work when write(FILENO_STDOUT, ...) was used. So we will
have to disable scrolling on a per character basis in cputc.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4617 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-03-07 13:37:58 +00:00
uz
2bd1f2f69f Fixed a problem with a disabled cursor: Switching off the cursor using the
kernal routine does not work, when the cursor is not at the same position
where it was switched on, because when switching it on, the kernal remembers
the character attribute and restores this when switching it off. So characters
may get the wrong attribute. The solution is to always switch the cursor on,
before switching it off.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4592 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-02-18 20:31:50 +00:00
uz
4bf888aa62 Fixed a video problem: When switching the display, the SCROLL flag gets
cleared, which in turn causes the display to scroll when a character is output
in the lower right corner.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4590 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-02-15 18:32:15 +00:00
ol.sc
d1aad57b98 Initialize _curunit from the zeropage value DEVNUM (aka First Address) in a constructor with a very high priority to be called before DEVNUM gets overwritten by other constructors.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4588 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-02-14 23:12:54 +00:00
uz
7d03059240 Fixes for the ptvjoy drivers by Marco van den Heuvel.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4581 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-02-04 21:02:00 +00:00
uz
44bb5c62e6 Moved the extended RAM driver to c128-ram2.emd and restored the old one.
Machines with RAM in pages 2+3 are quite rare, so it's better to have the
additional code+features in a separate driver.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4575 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-02-04 18:28:56 +00:00
uz
1524b0c13f Added code to the driver to use also banks 2 and 3 if present. Contributed by
Marco van den Heuvel.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4569 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-02-01 17:56:37 +00:00
uz
6c2fb80084 Added size checking code contributed by Marco van den Heuvel.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4568 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-02-01 07:20:06 +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
16129b2724 Quite some minor changes to have the two C128 TGI driver source files only differ where they are semantically different.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4552 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-01-23 08:55:37 +00:00
uz
7e2a24176f Replaced $30 by literal '0' for better readability.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4513 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-12-10 22:12:24 +00:00
uz
13698871cb Removed the call to CLRCH in the startup code.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4512 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-12-10 21:22:17 +00:00
uz
60bc009991 * Moved the BASIC stub that calls the compiled program into it's own segment
named EXEHDR.
* Renamed BASICHDR to EXEHDR for the PET-II machines.
* Moved the call to CHRCH in front of the code that saves the zero page, since
  open files are sometimes remembered in the zero page, so we need to close
  them before we grab a copy.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4507 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-12-09 12:42:24 +00:00
uz
bfbf94404b Squeezed bytes and cycles out of the kbhit functions for almost all platforms.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4480 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-11-24 18:31:16 +00:00
uz
c7a33334ba Don't hardcode the address of the SYS call for the startup code of the
Commodore machines.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4474 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-11-23 12:01:24 +00:00
uz
5304a8149e 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@4396 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-10-29 20:13:56 +00:00
uz
ed15f337d9 Use a simple expression now that ldwarning is available as an assert action.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4324 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-10-04 13:04:53 +00:00
uz
7ecdaf3d6e Use the new ldwarning assert action.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4322 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-10-04 12:42:32 +00:00
uz
634e84f12a Changed the existing Commodore mouse drivers for the new API. UNTESTED!
git-svn-id: svn://svn.cc65.org/cc65/trunk@4232 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-26 11:35:32 +00:00
uz
83be732983 The CIA TOD needs a write to the 1/10 sec register to start. Shortened the
code by using initialized data.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4224 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-24 19:40:36 +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
80fc3a0b48 Replaced the condition for the assertion in toggle_videomode by something that
is still always false, but will be evaluated by the linker instead of the
assembler. The assembler will otherwise emit a warning when just translating
the module.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4190 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-18 17:39:23 +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
uz
7c2823e780 Added the mouse_stddrv variable for the C64 and C128.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4149 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-11 16:51:21 +00:00
uz
931b6418bf Changed the prototype of videomode() to take and return an unsigned instead of
an unsigned char. Two more video mode constants as discussed on the list.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4133 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-08 16:25:12 +00:00
uz
74bfd6ee31 New function videomode() for the C128. Marked toggle_videomode as deprecated.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4126 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-09-07 13:21:04 +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
931add050e Added a systime implementation by Stefan Haubenthal with a few changes. The
routine reads the TOD clock of CIA1 on the C64 and C128. Since systime was a
dummy routine common for all CBMs before, this change adds an individual dummy
routine for all other CBM systems. CBM510/610 do also have a TOD clock, so a
similar function as in the C64 could be used ...


git-svn-id: svn://svn.cc65.org/cc65/trunk@3974 b7a2c559-68d2-44c3-8de9-860c34a00d81
2009-07-27 18:44:37 +00:00
uz
7e9b6e7311 Fixed problems with the startup code (Greg King): Interrupts must be hooked
before calling initlib because initlib calls contructors and may install
drivers, which enable hardware interrupts. Similar for donelib.


git-svn-id: svn://svn.cc65.org/cc65/trunk@3897 b7a2c559-68d2-44c3-8de9-860c34a00d81
2008-08-31 18:22:51 +00:00
uz
2b098710d9 Added Koala Pad mouse drivers written by Stefan Haubenthal.
git-svn-id: svn://svn.cc65.org/cc65/trunk@3877 b7a2c559-68d2-44c3-8de9-860c34a00d81
2008-08-05 20:54:35 +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
f257b2ee81 Moved the data that keeps a copy of the used zero page locations in its own
segment to reduce the executable size.


git-svn-id: svn://svn.cc65.org/cc65/trunk@3849 b7a2c559-68d2-44c3-8de9-860c34a00d81
2008-07-03 19:39:14 +00:00
cuz
263b7863a3 Oliver Schmidt fixed errors in the LINE and SETPIXELCLIP routines.
git-svn-id: svn://svn.cc65.org/cc65/trunk@3812 b7a2c559-68d2-44c3-8de9-860c34a00d81
2008-02-25 07:47:04 +00:00
cuz
4b8d90d2de Changed the mouse API: Introduced a new flag byte that contains information
about the driver, the mouse kernel needs to know. Current supported: Two flags
to enable interrupts before or after calling the driver INSTALL routine.


git-svn-id: svn://svn.cc65.org/cc65/trunk@3741 b7a2c559-68d2-44c3-8de9-860c34a00d81
2006-05-21 11:25:31 +00:00
cuz
cbdcab4fdb Change the sematics of callirq and the existing interruptors: The interrupts
must now return carry set if the interrupt has been handled, and carry clear
if not. The callirq routine will stop calling handlers with the first handler
that claims to have handled the interrupt. callirq will return the carry flag
to the caller as it came from the last interruptor called.


git-svn-id: svn://svn.cc65.org/cc65/trunk@3491 b7a2c559-68d2-44c3-8de9-860c34a00d81
2005-04-25 20:10:10 +00:00
cuz
d0bee35728 Move constructor code into the INIT segment
git-svn-id: svn://svn.cc65.org/cc65/trunk@3405 b7a2c559-68d2-44c3-8de9-860c34a00d81
2005-02-26 09:28:46 +00:00
cuz
a939b2b7e9 Added the IRQ entry
git-svn-id: svn://svn.cc65.org/cc65/trunk@3287 b7a2c559-68d2-44c3-8de9-860c34a00d81
2004-11-07 11:33:08 +00:00
cuz
16c81eb942 Add the irq entry point
git-svn-id: svn://svn.cc65.org/cc65/trunk@3279 b7a2c559-68d2-44c3-8de9-860c34a00d81
2004-11-06 13:12:57 +00:00
cuz
303304fe90 Add definitions for tools so the makefile is useful by itself.
git-svn-id: svn://svn.cc65.org/cc65/trunk@3262 b7a2c559-68d2-44c3-8de9-860c34a00d81
2004-10-26 19:28:26 +00:00
cuz
7b13d79bde Use get_tv.inc
git-svn-id: svn://svn.cc65.org/cc65/trunk@3259 b7a2c559-68d2-44c3-8de9-860c34a00d81
2004-10-26 19:05:19 +00:00