Free C-Compiler for CC2 Kategorie: Progr. Assembler, TaskingTools, OS (von Eric Hospel - 10.03.2002 14:05) | |
| |
For all of you who want to program the C-Control II in C, on the site of Hightec (www.hightec-rt.com) you can download a free Gnu C-compiler package for the C16x. This compiler is not crippled like the Tasking compiler on the Conrad CD. It generates code for the large memory model needed if you want to work with more than one segment. However, no C libray is supplied for the large memory model. This is not a big problem since you can write your own library functions ( I've already written string manipulation functions and 32-bit divide functions). I've converted my application from C2 to C and the speed difference is HUGE. The C-code is loaded in segment 3 and called from a C2 dummy progam. I've rewritten the C2 functions I needed in C. The following C2 functions are available: - I2C access (output only for the moment), - Internal LCD, - ADC converters, - Digital I/O, - PLM outputs, - Beep, - Serial port (output only for the moment), - 1 ms timer. Still to to: - Add interrupt support, - rewrite all C2 library functions to C, - floating point routines (if needed), - Adapt (replace) the OS to use more (all) segments for c-code. Please note there are a few drawbacks: no multi tasking (-yet-) and you need to be familiar with C and makefiles. So if you don't need (much) more speed you might want to stick with the C2 language. But I you need the full speed of the C164 with using assembly code thismight be very useful. Maybe Andre H. can reserve some room on this site to collect new functions for use with the C-compiler. If there any interrest I can mail the files (makefile & .bat file) I use to this forum. | |
Antwort schreiben Antworten: Re: Free C-Compiler for CC2 (von Alexander Bornschlegl - 15.03.2002 13:55) Re: Free C-Compiler for CC2 (von Eric Hospel - 15.03.2002 15:56) Re: Free C-Compiler for CC2 (von Mario Fischer - 13.03.2002 10:51) Re: Free C-Compiler for CC2 (von magic - 10.03.2002 15:34) Re: Free C-Compiler for CC2 (von Eric Hospel - 10.03.2002 19:59) Re: Free C-Compiler for CC2 (von Eric Hospel - 11.03.2002 8:50) |