1
0
mirror of https://github.com/cc65/cc65.git synced 2024-12-25 02:29:52 +00:00
Commit Graph

6914 Commits

Author SHA1 Message Date
Chris Cacciatore
c4823c6fd4 Added Duff's Device to tests. 2016-08-15 11:26:03 -07:00
Chris Cacciatore
3bd3fd8749 Removed check for LCURLY in switch statements. 2016-08-15 11:03:02 -07:00
Oliver Schmidt
0ad1880c42 Merge pull request #334 from cacciatc/standard-versioning
All programs print version and exit successfully.
2016-08-14 22:18:19 +02:00
Chris Cacciatore
bad8412131 All programs print version and exit successfully.
* All programs are now using the ProgName variable as well.
2016-08-12 08:54:41 -07:00
Oliver Schmidt
d9a2452b81 Merge pull request #332 from greg-king5/interrupt-functions
Add C-code interfaces for the CBM Kernal functions SCNKEY and UDTIM.
2016-08-11 19:12:36 +02:00
Oliver Schmidt
22d1f1da1b Minor style fix. 2016-08-10 11:38:11 +02:00
Chris Cacciatore
f9482a1b72 Fixed test negation. (#329)
Fixed test negation.
2016-08-09 15:46:51 -04:00
Greg King
2c03b9a1bc Added C-code interfaces for the CBM Kernal functions SCNKEY and UDTIM. 2016-08-07 15:50:10 -04:00
Oliver Schmidt
d90dff5861 Merge pull request #328 from cacciatc/print-sym-name-incompatible-ptr-types
Reporting sym name for incompatible pointer types.
2016-08-05 13:31:34 +02:00
Greg King
33b1d82791 Added the WDC65c02S WAI and STP mnemonics to the disassembler. 2016-08-02 16:38:39 -04:00
Chris Cacciatore
9accf983e1 Reporting sym name for incompatible pointer types. 2016-08-02 11:31:09 -07:00
greg-king5
ac17751699 Merge pull request #326 from dmlloyd/master
Add missing WDC instructions
2016-07-29 13:09:15 -04:00
David M. Lloyd
8f0146f14a Add missing WDC instructions 2016-07-28 11:55:25 -05:00
Greg King
e7e65044e6 Used more mundane addressing in some of the instructions in "zlib/inflatemem.s".
That avoids conflicts with ca65's future .setdp feature.
2016-07-19 10:42:49 -04:00
Oliver Schmidt
fb53bfc25d Merge pull request #323 from bbbradsmith/rand_fix
Fix broken rand() implementation.
2016-07-14 21:58:26 +02:00
Brad Smith
32d000fb4c Fix broken rand() implementation. The high 8 bits were unused, reducing it to a 24-bit implementation (while still doing all the work for a 32-bit one). The best entropy is in the unused high byte, returning these bits in A instead of bits 8-15, which had considerably lower entropy (i.e. rand() & 255 was effectively a 16-bit LCG). 2016-07-11 20:48:47 -04:00
Oliver Schmidt
06bb95d197 Merge pull request #322 from greg-king5/inflatemem
Make inflatemem()'s source file use its enhanced instructions for 65SC02 CPUs, too.
2016-07-10 19:36:35 +02:00
Greg King
c2945bf1ff Made the zlib's inflatemem()'s source file use enhanced instructions for all 65SC02-compatible CPUs (not only the 65C02). 2016-07-10 05:05:38 -04:00
Oliver Schmidt
48448e6bbb Merge pull request #320 from groessler/something_to_pull
sim65: add command line parameter to print number of CPU cycles at exit
2016-07-06 09:12:54 +02:00
Christian Groessler
85d755f214 fix indentation 2016-07-05 17:10:10 +02:00
Christian Groessler
97b517a892 sim65: add command line parameter to print number of CPU cycles at exit 2016-07-05 17:07:39 +02:00
Greg King
a6eb7d0763 Fixed how ca65 handles some debug info from cc65.
ca65 used to claim that an assembler error/warning was found on a C code line; and, that an Assembly line is only indirectly related to it.
Now, ca65 says that the Assembly line has the problem; and, that the Assembly line was produced from the C line.
2016-07-03 07:07:09 -04:00
Greg King
4014783275 Made the samples Makefile run cl65 only when we want a disk image.
That change avoids an error message when we "make clean" from the top-level make-file (it removes the tools before it cleans the samples).
2016-07-03 02:23:59 -04:00
Greg King
90b2f5aff8 Fixed some code that adjusts an index after a deletion from a collection. 2016-07-02 10:26:33 -04:00
Oliver Schmidt
dfea22389c Merge pull request #315 from skry/fixes
Fix typo in samples makefile
2016-06-23 14:57:21 +02:00
Joni Lapilainen
ab10bd4014 Fix typo in samples makefile 2016-06-23 15:46:09 +03:00
Greg King
5d9f4dc89d Made the overlay demo programs compile for CBM targets again.
<conio.h> includes target-specific headers; so, we didn't bother to include <cbm.h> where it is needed.  But, '#include <conio.h>' was removed from some files; so now, we must include <cbm.h> explicitly.
2016-06-19 17:41:18 -04:00
Oliver Schmidt
c9e9679a06 Improved doc and samples default target.
The 'all' target deliberately doesn't build the doc nor the samples. But that doesn't mean that the Makefiles in the 'doc' and 'samples' directories must default to the (empty) 'all' target.
2016-06-19 18:55:00 +02:00
Oliver Schmidt
e47485f925 Added CONIO cursor support.
For quite some time I deliberately didn't add cursor support to the Apple II CONIO imöplementation. I consider it inappropriate to increase the size of cgetc() unduly for a rather seldom used feature.

There's no hardware cursor on the Apple II so displaying a cursor during keyboard input means reading the character stored at the cursor location, writing the cursor character, reading the keyboard and finally writing back the character read initially.

The naive approach is to reuse the part of cputc() that determines the memory location of the character at the cursor position in order to read the character stored there. However that means to add at least one additional JSR / RTS pair to cputc() adding 4 bytes and 12 cycles :-( Apart from that this approach means still a "too" large cgetc().

The approach implemented instead is to include all functionality required by cgetc() into cputc() - which is to read the current character before writing a new one. This may seem surprising at first glance but an LDA(),Y / TAX sequence adds only 3 bytes and 7 cycles so it cheaper than the JSR / RTS pair and allows to brings down the code increase in cgetc() down to a reasonable value.

However so far the internal cputc() code in question saved the X register. Now it uses the X register to return the old character present before writing the new character for cgetc(). This requires some rather small adjustments in other functions using that internal cputc() code.
2016-06-19 15:03:20 +02:00
Oliver Schmidt
2ef43e425a Adjusted to recent change. 2016-06-19 01:39:27 +02:00
Oliver Schmidt
66561c23c1 Made Makefile actually work.
Supported target systems:
* c64 (default)
* apple2
* apple2enh
* atari
* atarixl
2016-06-19 01:22:59 +02:00
Oliver Schmidt
64c10aa2fe Minor simplification. 2016-06-18 23:57:18 +02:00
Oliver Schmidt
9bc096d9b0 Make use of doesclrscrafterexit(). 2016-06-18 23:57:17 +02:00
Oliver Schmidt
520641890d Merge pull request #313 from greg-king5/plus4-joy
Fix the Plus/4 (and C16) joystick driver.
2016-06-18 23:23:55 +02:00
Greg King
f91a7e749b Fixed the Plus/4 joystick driver.
It chooses a stick correctly.  And, it reads the fire button.
2016-06-18 13:18:26 -04:00
Oliver Schmidt
a7323d399e Merge pull request #312 from groessler/atari-exec-devel
Fix exec() for atarixl target.
2016-06-16 11:49:18 +02:00
Christian Groessler
a9c69bb8c9 A small rearrangement of instructions in Atari's exec() to let the comments
make sense again.
2016-06-16 00:47:13 +02:00
Christian Groessler
ec7751332f Fix exec() for atarixl target.
The final part of exec() called 'excexit' and only then restored the
stack pointer to its value at program entry.  'excexit' does all
cleanup (the same as '_exit()'), which means that on the atarixl
target the ROM is banked in again.  On big programs the 'SP_save'
variable might reside at a high memory address which is no longer
accessible after the ROM has been banked in.
The change just moves the restoration of the stack pointer before
the call to 'excexit'.

Another change lets exec.s compile if UCASE_FILENAME is not defined.
And some other small cleanups, also in open.s.
2016-06-15 23:52:16 +02:00
Oliver Schmidt
2c8b8d90bf Merge pull request #311 from groessler/something_to_pull
Fix doesclrscrafterexit() function on atarixl target.
2016-06-15 08:59:50 +02:00
Oliver Schmidt
d8dfc29297 Merge pull request #310 from groessler/atari-exec-devel
Implement exec() for Atari XDOS.
2016-06-15 08:58:23 +02:00
Christian Groessler
d0faf471b8 Some improvements to Atari exec() after review. 2016-06-14 20:44:57 +02:00
Christian Groessler
4aa9a414c6 Fix doesclrscrafterexit() function on atarixl target.
On atarixl, the screen is always cleared, regardless of the running DOS.
2016-06-13 21:16:27 +02:00
Christian Groessler
94ba9575ec Implement exec() for Atari XDOS.
- Adds new ENOEXEC error code, also used by Apple2 targets.
- Maximum command line length is 40, incl. program name. This is
  an XDOS restriction.
- testcode/lib/tinyshell.c has been extended to be able to run
  programs.
2016-06-13 20:40:01 +02:00
Oliver Schmidt
271b65aa70 Added hint on how to quit program. 2016-06-12 23:48:19 +02:00
Oliver Schmidt
98973ee901 Avoid warnings on monochrom targets (and remove unnecessary code). 2016-06-12 23:30:29 +02:00
Oliver Schmidt
524813ff60 Allow to build samples from the main Makefile. 2016-06-12 23:30:29 +02:00
Oliver Schmidt
4fc27ffc98 Merge pull request #309 from greg-king5/map-zero
Allow character code 0x00 to be remapped with other character codes.
2016-06-11 16:13:24 +02:00
Greg King
573381a340 Allowed character code zero to be remapped with other character codes. 2016-06-11 06:43:19 -04:00
Oliver Schmidt
e95d07aa97 Merge pull request #308 from greg-king5/funcref
Update the function reference document.
2016-06-09 08:57:03 +02:00
Greg King
0835985999 Updated the function reference document.
* Added doesclrscrafterexit() to cc65.h's list.
* Added header-file function lists for some new target platforms.
2016-06-08 21:05:56 -04:00