From c4a712f3106d076f09ccb6783501d97e1f8490f8 Mon Sep 17 00:00:00 2001 From: Winfried Ritsch Date: Tue, 12 Apr 2005 09:14:51 +0000 Subject: This commit was generated by cvs2svn to compensate for changes in r2726, which included commits to RCS files with non-trunk default branches. svn path=/trunk/externals/iem/comport/; revision=2727 --- bird/bird.c | 375 ++++++++ bird/bird.dll | Bin 0 -> 36864 bytes bird/bird.pd_linux | Bin 0 -> 6896 bytes comport.dll | Bin 0 -> 36864 bytes comport.exp | Bin 0 -> 578 bytes comport.lib | Bin 0 -> 1952 bytes comport.pd_linux | Bin 0 -> 9604 bytes comport/CHANGES.txt | 8 + comport/LICENCE.txt | 360 ++++++++ comport/README.txt | 29 + comport/comport.c | 979 ++++++++++++++++++++ comport/makefile | 82 ++ comport/testcomport.pd | 81 ++ docs/Serial-Programming-HOWTO.book.pdf | Bin 0 -> 19999 bytes docs/serial.doc | Bin 0 -> 127488 bytes docs/serial.pdf | 1565 ++++++++++++++++++++++++++++++++ licence.txt | 361 ++++++++ makefile | 104 +++ pd_bird.bat | 5 + pd_comport.bat | 5 + testbird.pd | 96 ++ testbird.sh | 2 + testcomport.pd | 78 ++ testcomport.sh | 2 + vcmakefile.dsp | 85 ++ vcmakefile.dsw | 29 + vcmakefile.ncb | Bin 0 -> 33792 bytes vcmakefile.opt | Bin 0 -> 53760 bytes vcmakefile.plg | 29 + 29 files changed, 4275 insertions(+) create mode 100644 bird/bird.c create mode 100644 bird/bird.dll create mode 100644 bird/bird.pd_linux create mode 100644 comport.dll create mode 100644 comport.exp create mode 100644 comport.lib create mode 100644 comport.pd_linux create mode 100644 comport/CHANGES.txt create mode 100644 comport/LICENCE.txt create mode 100644 comport/README.txt create mode 100644 comport/comport.c create mode 100644 comport/makefile create mode 100644 comport/testcomport.pd create mode 100644 docs/Serial-Programming-HOWTO.book.pdf create mode 100644 docs/serial.doc create mode 100644 docs/serial.pdf create mode 100644 licence.txt create mode 100644 makefile create mode 100644 pd_bird.bat create mode 100644 pd_comport.bat create mode 100644 testbird.pd create mode 100644 testbird.sh create mode 100644 testcomport.pd create mode 100644 testcomport.sh create mode 100644 vcmakefile.dsp create mode 100644 vcmakefile.dsw create mode 100644 vcmakefile.ncb create mode 100644 vcmakefile.opt create mode 100644 vcmakefile.plg diff --git a/bird/bird.c b/bird/bird.c new file mode 100644 index 0000000..5f3df3c --- /dev/null +++ b/bird/bird.c @@ -0,0 +1,375 @@ +/*********************************************************************** +************************************************************************ +bird.c - controls and parses one flock of bird out of a comport + +Author: W. Ritsch 16.01.97 +Desc.: put the object in a correct parse state and send commands + +first input: where data from bird is thrown in (eg.from comport) +first output: a list of data which size is dependen on the parse mode +second output: to control the bird eg connect to a comport in + +*/ + +#ifdef NT +#pragma warning( disable : 4244 ) +#pragma warning( disable : 4305 ) +#endif + +#include +#include /* general I/O */ +#include /* for string commands */ +#include "m_pd.h" + +#define B_MAX_DATA 32 /* Maximal awaited data per record */ +#define B_MAX_CMDDATA 6 /* Maximum of awaited cmd arguments */ + +typedef struct { + + t_object x_obj; + t_outlet *x_out2; + t_int x_n; + t_atom *x_vec; + + int databytes; /* expected databytes */ + int datacount; /* count bytes in record */ + int phase_wait; /* wait for phasebit */ + + int datamode; /* data mode is data or examine*/ +/* int flowmode; stream or point mode */ + int phase_error; + + void (*writefun)(void *this,unsigned char c); + + unsigned char data[B_MAX_DATA]; /* maximal record length */ + char *argname; + int argc; + int argv[B_MAX_DATA]; + + int verbose; + +} bird_t; + +bird_t *bird_init( bird_t *this); +int bird_data( bird_t *this, unsigned char data ); +void bird_setwritefun(bird_t *this,void (*newwritefun)(void *bird,unsigned char c)); +void bird_send(bird_t *this,unsigned char chr); +void bird_bang(bird_t *this); +void bird_set(bird_t *this,char *cmdname,long *cmddata); + + + +typedef struct { + + char *name; + unsigned char cmd; + int cmdbytes; /* number of cmd arguments */ + int cmdsize; /* size of arguments in bytes (most 2) */ + int databytes; /* number of awaited data */ + int datamode; /* data mode is ignore, point flow or examine*/ + +} bird_cmd; + + +/* defines Modes for data receiving */ +#define B_MODE_IGNORE 0 +#define B_MODE_POINT 1 +#define B_MODE_STREAM 2 +#define B_MODE_EXAM 3 + +/*#define B_STREAM_ON 1 + #define B_STREAM_OFF 0 +*/ +#define B_WAIT_PHASE 1 +#define B_FOUND_PHASE 0 + + +/* definitions */ + +/* cmds accepted by the flock */ +static bird_cmd cmds[]= { + + /* cmd , value, nr of cmdatabytes, cmddatasize, nr datainbytes + data modes, if change always point */ + {"ANGLES", 'W', 0, 0, 6, B_MODE_POINT}, + {"MATRIX", 'X', 0, 0, 18, B_MODE_POINT}, + {"POSITION", 'V', 0, 0, 6, B_MODE_POINT}, + {"QUATER", 0x5C, 0, 0, 8, B_MODE_POINT}, + {"POSANG", 'Y', 0, 0, 12, B_MODE_POINT}, + {"POSMAT", 'Z', 0, 0, 24, B_MODE_POINT}, + {"POSQUATER", ']', 0, 0, 14, B_MODE_POINT}, + /* output cmd */ + {"POINT", 'B', 0, 0, 0, B_MODE_POINT}, + {"STREAM", 64, 0, 0, 0, B_MODE_STREAM}, + {"RUN", 'F', 0, 0, 0, B_MODE_IGNORE}, + {"SLEEP", 'G', 0, 0, 0, B_MODE_IGNORE}, + /* set cmds */ + {"AngleAlign1", 'J', 6, 2, 0, B_MODE_IGNORE}, + {"AngleAlign2", 'q', 3, 2, 0, B_MODE_IGNORE}, + {"Hemisphere", 'L', 2, 1, 0, B_MODE_IGNORE}, + {"RefFrame1", 'H', 6, 2, 0, B_MODE_IGNORE}, + {"RefFrame2", 'r', 3, 2, 0, B_MODE_IGNORE}, + {"RepRate1", 'Q', 0, 0, 0, B_MODE_IGNORE}, + {"RepRate2", 'R', 0, 0, 0, B_MODE_IGNORE}, + {"RepRate8", 'S', 0, 0, 0, B_MODE_IGNORE}, + {"RepRate32", 'T', 0, 0, 0, B_MODE_IGNORE}, + { NULL, '\0', 0, 0, 0, B_MODE_IGNORE} +}; + + + +/* -------------------- the serial object methods -------------------- */ +bird_t *bird_init( bird_t *this) +{ + if(this == NULL){ + this = malloc(sizeof(bird_t)); + } + if(this == NULL){ + post("Could not allocate data for bird_t"); + } + + this->databytes = 0; + this->datacount = 0; + this->phase_wait = B_WAIT_PHASE; + this->datamode = B_MODE_IGNORE; + this->phase_error = 0; + this->writefun = NULL; + + this->argname = "STARTUP_MODE"; + this->argc = 0; + + + return this; +} + +int bird_data( bird_t *this, unsigned char data ) +{ + int i; + + if(this->datamode != B_MODE_IGNORE){ + + /* STREAM or POINT Mode */ + + /* Phase was detected */ + if(this->phase_wait == B_FOUND_PHASE && data < 0x80){ + + this->data[this->datacount] = data; /* store data */ + this->datacount++; /* increment counter */ + + if(this->databytes <= this->datacount){ /* last byte of record */ + this->datacount = 0; + this->phase_wait = B_WAIT_PHASE; + + /* interpret and output */ + this->argc = this->databytes / 2; + for(i=0;idatabytes;i+=2){ + + this->argv[i/2] = (this->data[i]<<2)+(this->data[i+1]<<9); + + /* printf("list[%2d]=%7d (%3d,%3d) ",i, + ((this->data[i]<<2)+(this->data[i+1]<<9)), + this->data[i],this->data[i+1]); + */ + } + // printf("\n"); + return this->argc; + }; + } + else{ /* Phase wait */ + + if( (data & 0x80) == 0x00 ){ /* phase bit not found */ + if(this->phase_error == 0) + if(this->verbose)post("phase error:%x",data); + this->phase_error++; + } + else{ + this->phase_wait = B_FOUND_PHASE; /* phase found */ + this->data[0] = data & 0x7F; /* store first data */ + this->datacount = 1; /* wait for next */ + this->phase_error = 0; /* phase error reset */ + }; + + }; + }; /* stream or point mode */ + return 0; +} + + +void bird_setwritefun(bird_t *bird,void (*newwritefun)(void *this,unsigned char c)) +{ + //if(bird == NULL) return; better segfault and you find the error... + bird->writefun = newwritefun; +} + +void bird_send(bird_t *this,unsigned char chr) +{ + // if(this == NULL)return; better segfault and you find the error... + if(this->writefun)this->writefun(this,chr); +} + +/* with bang to trigger a data output (POINT) */ + +void bird_bang(bird_t *this) +{ + if(this->datamode == B_MODE_POINT) + bird_send(this,'B'); +} + +/* set the modes for the bird */ +void bird_set(bird_t *this,char *cmdname,long *cmddata) +{ + int i,j; + long data; + bird_cmd *cmd = cmds; + + /* search for cmd */ + while(cmd->name != (char *) 0l && strcmp(cmd->name,cmdname) != 0)cmd++; + + if(cmd->name == (char *) 0l){ + post("bird:Dont know how to set %s",cmdname); + return; + } + + /* CMD found */ + if(cmd->databytes > 0){ /* if databytes awaited, else dont change */ + + this->databytes = cmd->databytes; /* expected databytes per record */ + this->datacount = 0; /* start with first */ + this->argname = cmd->name; + + if( cmd->datamode == B_MODE_EXAM) + this->phase_wait = B_FOUND_PHASE; /* wait for phase-bit */ + else + this->phase_wait = B_WAIT_PHASE; /* wait for phase-bit */ + } + + if( cmd->datamode != B_MODE_IGNORE) /* go into data mode */ + this->datamode = cmd->datamode; + + + if(cmd->cmdbytes >= 0){ /* is a real cmd for bird */ + + bird_send(this,cmd->cmd); + + for(i=0; i < cmd->cmdbytes;i++){ + + data = cmddata[i]; + + for(j=0; j < cmd->cmdsize;j++){ /* send it bytewise */ + bird_send(this, (unsigned char) (data&0xFF)); + data >>= 8; + }; + }; + + } + + if(this->verbose)post("command %s (%c): databytes=%d, mode=%d, phase=%d", + cmd->name,cmd->cmd, + this->databytes, + this->datamode, this->phase_wait); + +} + + +/* ---------------- pd object bird ----------------- */ + +/* code for bird pd class */ + + +void bird_float(bird_t *x, t_floatarg f) +{ + int n,i; + + if((n=bird_data(x,(unsigned char) f)) > 0){ + + /* make list and output */ + + for(i=0; i < x->argc ; i++){ + x->x_vec[i].a_type = A_FLOAT; + x->x_vec[i].a_w.w_float = x->argv[i]; + } + outlet_list(x->x_obj.ob_outlet, &s_list, x->argc, x->x_vec); + } +} + +void bird_setting(bird_t *x, t_symbol *s, int argc, t_atom *argv) +{ + int i; + char *cmdnam; + long buffer[ B_MAX_CMDDATA ]; + + if(argc < 1) return; + cmdnam = argv[0].a_w.w_symbol->s_name; + + if(argc > (B_MAX_CMDDATA +1)) + argc = B_MAX_CMDDATA +1; + + for(i=1;i< argc;i++) + if(argv[i].a_type != A_FLOAT) + post("bird set arg %d no float",i); + else + buffer[i-1] = argv[i].a_w.w_float; + + bird_set(x,cmdnam,buffer); +} + +void bird_verbose(bird_t *x, t_floatarg f) +{ + if(f) x->verbose = 1; + else x->verbose = 0; +} + +void bird_free(bird_t *x) +{ + freebytes(x->x_vec, x->x_n * sizeof(*x->x_vec)); +} + +t_class *bird_class; + +void bird_output(void *x,unsigned char c) +{ + outlet_float(((bird_t *)x)->x_out2, (t_float) c); +} + +void *bird_new(void) +{ + bird_t *x; + + x = (bird_t *)pd_new(bird_class); + + outlet_new(&x->x_obj, &s_list); + x->x_out2 = outlet_new(&x->x_obj, &s_float); + + + x->x_vec = (t_atom *)getbytes((x->x_n=B_MAX_DATA) * sizeof(*x->x_vec)); + + bird_init(x); + bird_setwritefun(x,bird_output); + + bird_set(x,"RUN",NULL); + + bird_set(x,"POSANG",NULL); + // out_byte('W'); + + bird_set(x,"POINT",NULL); + // out_byte(64); + + x->verbose = 0; + + return (void *)x; +} + +void bird_setup(void) +{ + bird_class = class_new(gensym("bird"), (t_newmethod)bird_new, + (t_method)bird_free, sizeof(bird_t), 0, 0); + + /* maximum commandatasize is 6*/ + class_addmethod(bird_class, (t_method)bird_setting, gensym("set"), A_GIMME, 0); + class_addmethod(bird_class, (t_method)bird_verbose, gensym("verbose"), A_FLOAT, 0); + + class_addbang(bird_class,bird_bang); + + class_addfloat(bird_class, bird_float); +} + diff --git a/bird/bird.dll b/bird/bird.dll new file mode 100644 index 0000000..a2a18ee Binary files /dev/null and b/bird/bird.dll differ diff --git a/bird/bird.pd_linux b/bird/bird.pd_linux new file mode 100644 index 0000000..7021aa1 Binary files /dev/null and b/bird/bird.pd_linux differ diff --git a/comport.dll b/comport.dll new file mode 100644 index 0000000..ad6ecb7 Binary files /dev/null and b/comport.dll differ diff --git a/comport.exp b/comport.exp new file mode 100644 index 0000000..b79b0b4 Binary files /dev/null and b/comport.exp differ diff --git a/comport.lib b/comport.lib new file mode 100644 index 0000000..c456240 Binary files /dev/null and b/comport.lib differ diff --git a/comport.pd_linux b/comport.pd_linux new file mode 100644 index 0000000..d3c3a57 Binary files /dev/null and b/comport.pd_linux differ diff --git a/comport/CHANGES.txt b/comport/CHANGES.txt new file mode 100644 index 0000000..3247476 --- /dev/null +++ b/comport/CHANGES.txt @@ -0,0 +1,8 @@ +1.0RC1 - (12.4.2005) + + first check in pure-data.sourceforge.net + added print feature and USB devices from posted by Marc Boon + +0.9beta2 (somedate before 2004) + + CHANGES.txt startet diff --git a/comport/LICENCE.txt b/comport/LICENCE.txt new file mode 100644 index 0000000..9ca2743 --- /dev/null +++ b/comport/LICENCE.txt @@ -0,0 +1,360 @@ +comport - PD External for the serial Ports + +Institute for Electronic Music and Acoustics +Copyright (C) 1998-2005 Winfried Ritsch + + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. (see below) + +--------------------------- GPL.TXT ------------------------- + + + GNU GENERAL PUBLIC LICENSE + Version 2, June 1991 + + Copyright (C) 1989, 1991 Free Software Foundation, Inc. + 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to share and change free +software--to make sure the software is free for all its users. This +General Public License applies to most of the Free Software +Foundation's software and to any other program whose authors commit to +using it. (Some other Free Software Foundation software is covered by +the GNU Library General Public License instead.) You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. + + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if you +distribute copies of the software, or if you modify it. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must give the recipients all the rights that +you have. You must make sure that they, too, receive or can get the +source code. And you must show them these terms so they know their +rights. + + We protect your rights with two steps: (1) copyright the software, and +(2) offer you this license which gives you legal permission to copy, +distribute and/or modify the software. + + Also, for each author's protection and ours, we want to make certain +that everyone understands that there is no warranty for this free +software. If the software is modified by someone else and passed on, we +want its recipients to know that what they have is not the original, so +that any problems introduced by others will not reflect on the original +authors' reputations. + + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that redistributors of a free +program will individually obtain patent licenses, in effect making the +program proprietary. To prevent this, we have made it clear that any +patent must be licensed for everyone's free use or not licensed at all. + + The precise terms and conditions for copying, distribution and +modification follow. + + + GNU GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License applies to any program or other work which contains +a notice placed by the copyright holder saying it may be distributed +under the terms of this General Public License. The "Program", below, +refers to any such program or work, and a "work based on the Program" +means either the Program or any derivative work under copyright law: +that is to say, a work containing the Program or a portion of it, +either verbatim or with modifications and/or translated into another +language. (Hereinafter, translation is included without limitation in +the term "modification".) Each licensee is addressed as "you". + +Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running the Program is not restricted, and the output from the Program +is covered only if its contents constitute a work based on the +Program (independent of having been made by running the Program). +Whether that is true depends on what the Program does. + + 1. You may copy and distribute verbatim copies of the Program's +source code as you receive it, in any medium, provided that you +conspicuously and appropriately publish on each copy an appropriate +copyright notice and disclaimer of warranty; keep intact all the +notices that refer to this License and to the absence of any warranty; +and give any other recipients of the Program a copy of this License +along with the Program. + +You may charge a fee for the physical act of transferring a copy, and +you may at your option offer warranty protection in exchange for a fee. + + 2. You may modify your copy or copies of the Program or any portion +of it, thus forming a work based on the Program, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) You must cause the modified files to carry prominent notices + stating that you changed the files and the date of any change. + + b) You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any + part thereof, to be licensed as a whole at no charge to all third + parties under the terms of this License. + + c) If the modified program normally reads commands interactively + when run, you must cause it, when started running for such + interactive use in the most ordinary way, to print or display an + announcement including an appropriate copyright notice and a + notice that there is no warranty (or else, saying that you provide + a warranty) and that users may redistribute the program under + these conditions, and telling the user how to view a copy of this + License. (Exception: if the Program itself is interactive but + does not normally print such an announcement, your work based on + the Program is not required to print an announcement.) + + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Program, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Program, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Program. + +In addition, mere aggregation of another work not based on the Program +with the Program (or with a work based on the Program) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may copy and distribute the Program (or a work based on it, +under Section 2) in object code or executable form under the terms of +Sections 1 and 2 above provided that you also do one of the following: + + a) Accompany it with the complete corresponding machine-readable + source code, which must be distributed under the terms of Sections + 1 and 2 above on a medium customarily used for software interchange; or, + + b) Accompany it with a written offer, valid for at least three + years, to give any third party, for a charge no more than your + cost of physically performing source distribution, a complete + machine-readable copy of the corresponding source code, to be + distributed under the terms of Sections 1 and 2 above on a medium + customarily used for software interchange; or, + + c) Accompany it with the information you received as to the offer + to distribute corresponding source code. (This alternative is + allowed only for noncommercial distribution and only if you + received the program in object code or executable form with such + an offer, in accord with Subsection b above.) + +The source code for a work means the preferred form of the work for +making modifications to it. For an executable work, complete source +code means all the source code for all modules it contains, plus any +associated interface definition files, plus the scripts used to +control compilation and installation of the executable. However, as a +special exception, the source code distributed need not include +anything that is normally distributed (in either source or binary +form) with the major components (compiler, kernel, and so on) of the +operating system on which the executable runs, unless that component +itself accompanies the executable. + +If distribution of executable or object code is made by offering +access to copy from a designated place, then offering equivalent +access to copy the source code from the same place counts as +distribution of the source code, even though third parties are not +compelled to copy the source along with the object code. + + + 4. You may not copy, modify, sublicense, or distribute the Program +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense or distribute the Program is +void, and will automatically terminate your rights under this License. +However, parties who have received copies, or rights, from you under +this License will not have their licenses terminated so long as such +parties remain in full compliance. + + 5. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Program or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Program (or any work based on the +Program), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Program or works based on it. + + 6. Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the +original licensor to copy, distribute or modify the Program subject to +these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + + 7. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Program at all. For example, if a patent +license would not permit royalty-free redistribution of the Program by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Program. + +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply and the section as a whole is intended to apply in other +circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system, which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + + 8. If the distribution and/or use of the Program is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Program under this License +may add an explicit geographical distribution limitation excluding +those countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. + + 9. The Free Software Foundation may publish revised and/or new versions +of the General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. + + 10. If you wish to incorporate parts of the Program into other free +programs whose distribution conditions are different, write to the author +to ask for permission. For software which is copyrighted by the Free +Software Foundation, write to the Free Software Foundation; we sometimes +make exceptions for this. Our decision will be guided by the two goals +of preserving the free status of all derivatives of our free software and +of promoting the sharing and reuse of software generally. + + NO WARRANTY + + 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, +REPAIR OR CORRECTION. + + 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. + + END OF TERMS AND CONDITIONS + + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) 19yy + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + +Also add information on how to contact you by electronic and paper mail. + +If the program is interactive, make it output a short notice like this +when it starts in an interactive mode: + + Gnomovision version 69, Copyright (C) 19yy name of author + Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, the commands you use may +be called something other than `show w' and `show c'; they could even be +mouse-clicks or menu items--whatever suits your program. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the program + `Gnomovision' (which makes passes at compilers) written by James Hacker. + + , 1 April 1989 + Ty Coon, President of Vice + +This General Public License does not permit incorporating your program into +proprietary programs. If your program is a subroutine library, you may +consider it more useful to permit linking proprietary applications with the +library. If this is what you want to do, use the GNU Library General +Public License instead of this License. + diff --git a/comport/README.txt b/comport/README.txt new file mode 100644 index 0000000..aff44fa --- /dev/null +++ b/comport/README.txt @@ -0,0 +1,29 @@ +comport - PD external for unix/windows to use the serial ports + + (c) 1998-2005 Winfried Ritsch (see LICENCE.txt) + Institute for Electronic Music - Graz + +on Windows the COM0, COM1, ... are used and +under Unix devices /dev/ttyS0, /dev/ttyS1, ... +and new on unix /dev/USB0, ... and can be accessed via a Index. + +Please see testcomport.pd for more help. + +USE: There should be a external comport.dll for windows, comport.pd_linux for linux and so on. + +just copy it to the extra folder of your pd Installation or working directory. +Please see testcomport.pd for more help. + +compile: + + Unix (Linux): + make pd_linux, make pd_irix5, make pd_irix6 + should produce a comport.pd_linux, .... + + + Windows: use nmake or just use Fast Build under MSVC++ + nmake pd_nt + + +If you have improvements or questions feel free to contact me under +ritsch _at_ iem.at diff --git a/comport/comport.c b/comport/comport.c new file mode 100644 index 0000000..0fa9369 --- /dev/null +++ b/comport/comport.c @@ -0,0 +1,979 @@ +/* comport - PD external for unix/windows + + (c) 1998-2005 Winfried Ritsch (see LICENCE.txt) + Institute for Electronic Music - Graz + +*/ + +#include "m_pd.h" + +#ifdef NT +#pragma warning( disable : 4244 ) +#pragma warning( disable : 4305 ) +#include +#include +#else +#include +#include +#include /* for TERMIO ioctl calls */ +#include +#define HANDLE int +#define INVALID_HANDLE_VALUE -1 +#endif + +#include +#include + + +typedef struct comport +{ + t_object x_obj; + + long n; /* the state of a last input */ + + HANDLE comhandle; /* holds the comport handle */ + +#ifdef NT + DCB dcb; /* holds the comm pars */ + DCB dcb_old; /* holds the comm pars */ + COMMTIMEOUTS old_timeouts; +#else + struct termios oldcom_termio; /* save the old com config */ + struct termios com_termio; /* for the new com config */ +#endif + + short comport; /* holds the comport # */ + float baud; /* holds the current baud rate */ + + short rxerrors; /* holds the rx line errors */ + + t_clock *x_clock; + int x_hit; + double x_deltime; + +} t_comport; + +#ifndef TRUE +#define TRUE 1 +#define FALSE 0 +#endif + +#ifndef ON +#define ON 1 +#define OFF 0 +#endif + +/* + Serial Port Return Values +*/ +#define NODATAAVAIL -1 +#define RXERRORS -2 +#define RXBUFOVERRUN -4 +#define TXBUFOVERRUN -5 + +#ifdef NT + +#define COMPORT_MAX 8 +static char *sys_com_port[COMPORT_MAX] = +{ + "COM1", "COM2", "COM3", "COM4", + "COM5", "COM6", "COM7", "COM8" +}; + +static +long baudspeedbittable[] = +{ + CBR_256000, + CBR_128000, + CBR_115200, + CBR_57600, + CBR_56000, + CBR_38400, + CBR_19200, + CBR_14400, + CBR_9600, + CBR_4800, + CBR_2400, + CBR_1200, + CBR_600, + CBR_300, + CBR_110 +}; + +#else /* NT */ + +#ifdef IRIX +#define COMPORT_MAX 2 +static char *sys_com_port[COMPORT_MAX] = +{ + "/dev/ttyd1", "/dev/ttyd2" +}; +#define OPENPARAMS (O_RDWR|O_NDELAY|O_NOCTTY) +#define TIONREAD FIONREAD /* re map the IOCTL function */ +#define BAUDRATE_256000 -1 +#define BAUDRATE_128000 -1 +#define BAUDRATE_115200 -1 +#define BAUDRATE_57600 -1 +#define BAUDRATE_56000 -1 +#define BAUDRATE_38400 B38400 +#define BAUDRATE_14400 B19200 /* 14400 gibts nicht */ +#else /* IRIX */ +#define COMPORT_MAX 16 +static char *sys_com_port[COMPORT_MAX] = +{ + "/dev/ttyS0", "/dev/ttyS1", "/dev/ttyS2", "/dev/ttyS3", + "/dev/ttyS4", "/dev/ttyS5", "/dev/ttyS6", "/dev/ttyS7", + "/dev/ttyUSB0", "/dev/ttyUSB1", "/dev/ttyUSB2", "/dev/ttyUSB3", + "/dev/ttyUSB4", "/dev/ttyUSB5", "/dev/ttyUSB6", "/dev/ttyUSB7" +}; +#define OPENPARAMS (O_RDWR|O_NDELAY|O_NOCTTY) +#define BAUDRATE_256000 -1 +#define BAUDRATE_128000 -1 +#define BAUDRATE_115200 B115200 +#define BAUDRATE_57600 B57600 +#define BAUDRATE_56000 B57600 /* 56000 gibts nicht */ +#define BAUDRATE_38400 B38400 +#define BAUDRATE_14400 B19200 /* 14400 gibts nicht */ + +#endif /* else IRIX */ + +static +short baudspeedbittable[] = +{ + BAUDRATE_256000, /* CPU SPECIFIC */ + BAUDRATE_128000, /* CPU SPECIFIC */ + BAUDRATE_115200, /* CPU SPECIFIC */ + BAUDRATE_57600, /* CPU SPECIFIC */ + BAUDRATE_56000, + BAUDRATE_38400, /* CPU SPECIFIC */ + B19200, + BAUDRATE_14400, + B9600, + B4800, + B2400, + B1200, + B600, + B300, + B110 +}; + +struct timeval null_tv; + +#endif /* else NT */ + + +#define BAUDRATETABLE_LEN 15 + +static +long baudratetable[] = +{ + 256000L, + 128000L, + 115200L, + 57600L, + 56000L, + 38400L, + 19200L, + 14400L, + 9600L, + 4800L, + 2400L, + 1200L, + 600L, + 300L, + 110L +}; /* holds the baud rate selections */ + +t_class *comport_class; + +/* --------- sys independend serial setup helpers ---------------- */ + +static long get_baud_ratebits(t_float *baud) +{ + int i = 0; + + while(i < BAUDRATETABLE_LEN && baudratetable[i] > *baud) + i++; + + /* nearest Baudrate finding */ + if(i==BAUDRATETABLE_LEN || baudspeedbittable[i] < 0){ + post("*Warning* The baud rate %d is not suported or out of range, using 9600\n",*baud); + i = 7; + } + *baud = baudratetable[i]; + + return baudspeedbittable[i]; +} + + +/* ------------ sys dependend serial setup helpers ---------------- */ + + +/* --------------------- NT ------------------------------------ */ + +#ifdef NT + + +static float set_baudrate(t_comport *x,t_float baud) +{ + x->dcb.BaudRate = get_baud_ratebits(&baud); + + return baud; +} + +/* bits are 5,6,7,8(default) */ + +static float set_bits(t_comport *x, int nr) +{ + + if(nr < 4 && nr > 8) + nr = 8; + + // number of bits/byte, 4-8 + return x->dcb.ByteSize = nr; +} + + +/* 1 ... Parity even, -1 parity odd , 0 (default) no parity */ +static float set_parity(t_comport *x,int n) +{ + switch(n){ + case 1: + x->dcb.fParity = TRUE; // enable parity checking + x->dcb.Parity = 2; // 0-4=no,odd,even,mark,space + return 1; + + case -1: + x->dcb.fParity = TRUE; // enable parity checking + x->dcb.Parity = 1; // 0-4=no,odd,even,mark,space + return -1; + + default: + x->dcb.fParity = FALSE; // enable parity checking + x->dcb.Parity = 0; // 0-4=no,odd,even,mark,space + } + return 0; +} + + +/* aktivate second stop bit with 1, 0(default)*/ +static float set_stopflag(t_comport *x, int nr) +{ + if(nr == 1){ + x->dcb.StopBits = 1; // 0,1,2 = 1, 1.5, 2 + return 1; + } + else + x->dcb.StopBits = 0; // 0,1,2 = 1, 1.5, 2 + + return 0; +} + +/* never testet */ +static int set_ctsrts(t_comport *x, int nr) +{ + if(nr == 1){ + x->dcb.fOutxCtsFlow = TRUE; // CTS output flow control + x->dcb.fRtsControl = RTS_CONTROL_ENABLE; // RTS flow control + return 1; + } + x->dcb.fOutxCtsFlow = FALSE; // CTS output flow control + x->dcb.fRtsControl = RTS_CONTROL_DISABLE; // RTS flow control + return 0; +} + +static int set_xonxoff(t_comport *x, int nr) +{ + // x->dcb.fTXContinueOnXoff = FALSE; // XOFF continues Tx + + if(nr == 1){ + x->dcb.fOutX = TRUE; // XON/XOFF out flow control + x->dcb.fInX = TRUE; // XON/XOFF in flow control + return 1; + } + + x->dcb.fOutX = FALSE; // XON/XOFF out flow control + x->dcb.fInX = FALSE; // XON/XOFF in flow control + return 0; +} + + +static int set_serial(t_comport *x) +{ + + if (SetCommState(x->comhandle, &(x->dcb))) + return 1; + + return 0; +} + +static HANDLE open_serial(int com_nr, t_comport *x) +{ + HANDLE fd; + + COMMTIMEOUTS timeouts; + + float *baud = &(x->baud); + + if(com_nr < 0 || com_nr >= COMPORT_MAX) { + post("comport open %d, baud %d not valid (args: [portnum] [baud])",com_nr,*baud); + return INVALID_HANDLE_VALUE; + } + + fd = CreateFile( sys_com_port[com_nr], + GENERIC_READ | GENERIC_WRITE, + 0, + 0, + OPEN_EXISTING, + FILE_FLAG_OVERLAPPED, + 0); + + if(fd == INVALID_HANDLE_VALUE) + { + post("** ERROR ** could not open device %s:\n failure(%d): %s\n", + sys_com_port[com_nr],errno,strerror(errno)); + return INVALID_HANDLE_VALUE; + } + + /* Save the Current Port Configuration */ + + if (!GetCommState(fd, &(x->dcb_old))){ + post("** ERROR ** could not get old dcb of device %s\n", + sys_com_port[com_nr]); + + CloseHandle(fd); + return INVALID_HANDLE_VALUE; + } + + memset(&(x->dcb), sizeof(DCB), 0); + + if (!GetCommState(fd, &(x->dcb))){ + post("** ERROR ** could not get new dcb of device %s\n", + sys_com_port[com_nr]); + + CloseHandle(fd); + return INVALID_HANDLE_VALUE; + } + + + x->dcb.fBinary = TRUE; // binary mode, no EOF check + + // x->dcb.fOutxDsrFlow = FALSE; // DSR output flow control + // x->dcb.fDtrControl = DTR_CONTROL_DISABLE; // DTR flow control type + + // x->dcb.fDsrSensitivity = FALSE; // DSR sensitivity + + x->dcb.fErrorChar = FALSE; // enable error replacement + // x->dcb.fNull = FALSE; // enable null stripping + + // DWORD x->dcb.fAbortOnError:1; // abort reads/writes on error + + // char x->dcb.XonChar; // Tx and Rx XON character + // char x->dcb.XoffChar; // Tx and Rx XOFF character + // char x->dcb.ErrorChar; // error replacement character + // char x->dcb.EofChar; // end of input character + // char x->dcb.EvtChar; // received event character + + + set_bits(x,8); /* CS8 */ + set_stopflag(x,0); /* ~CSTOPB */ + set_ctsrts(x,0); /* ~CRTSCTS;*/ + set_xonxoff(x,1); /* (IXON | IXOFF | IXANY) */ + set_baudrate(x,*baud); + + x->comhandle = fd; + + if(set_serial(x)) + { + post("Opened serial line device %s\n",sys_com_port[com_nr]); + } + else + { + post("** ERROR ** could not set params to control dcb of device %s\n", + sys_com_port[com_nr]); + CloseHandle(fd); + return INVALID_HANDLE_VALUE; + } + + + + if (!GetCommTimeouts(fd, &(x->old_timeouts))){ + post("Couldnt get old timeouts for serial device"); + }; + + //setting new timeouts for read to immidiatly return + timeouts.ReadIntervalTimeout = MAXDWORD; + timeouts.ReadTotalTimeoutMultiplier = 0; + timeouts.ReadTotalTimeoutConstant = 0; + timeouts.WriteTotalTimeoutMultiplier = 0; + timeouts.WriteTotalTimeoutConstant = 0; + + if (!SetCommTimeouts(fd, &timeouts)){ + post("Couldnt set timeouts for serial device"); + return INVALID_HANDLE_VALUE; + }; + + + return fd; +} + +static HANDLE close_serial(t_comport *x) +{ + if(x->comhandle != INVALID_HANDLE_VALUE){ + + if (!SetCommState(x->comhandle, &(x->dcb_old)) ) + { + post("** ERROR ** could not reset params to DCB of device %s\n", + sys_com_port[x->comport]); + } + + if (!SetCommTimeouts(x->comhandle, &(x->old_timeouts))){ + post("Couldnt reset old_timeouts for serial device"); + }; + + CloseHandle(x->comhandle); + } + + return INVALID_HANDLE_VALUE; +} + + +static int write_serial(t_comport *x, unsigned char chr) +{ + OVERLAPPED osWrite = {0}; + DWORD dwWritten; + DWORD dwRes; + + /* post("open send %d",chr); */ + + if (!WriteFile(x->comhandle, &chr, 1, &dwWritten, &osWrite)) { + if (GetLastError() != ERROR_IO_PENDING) + post("WriteFile failed, but isn't delayed on serialdevice"); + return 0; + } + return 1; +} + +#else /* NT */ +/* ----------------- POSIX - UNIX ------------------------------ */ + + +static float set_baudrate(t_comport *x,t_float baud) +{ + struct termios *tio = &(x->com_termio); + + long baudbits = get_baud_ratebits(&baud); + + cfsetispeed(tio, baudbits); + cfsetospeed(tio, baudbits); + + return baud; +} + +/* bits are 5,6,7,8(default) */ + +static float set_bits(t_comport *x, int nr) +{ + struct termios *tio = &(x->com_termio); + tio->c_cflag &= ~CSIZE; + switch(nr){ + case 5: tio->c_cflag |= CS5; return 5; + case 6: tio->c_cflag |= CS6; return 6; + case 7: tio->c_cflag |= CS7; return 7; + default: tio->c_cflag |= CS8; + } + return 8; +} + + +/* 1 ... Parity even, -1 parity odd , 0 (default) no parity */ +static float set_parity(t_comport *x,int n) +{ + struct termios *tio = &(x->com_termio); + + switch(n){ + case 1: + tio->c_cflag |= PARENB; tio->c_cflag &= ~PARODD; return 1; + case -1: + tio->c_cflag |= PARENB | PARODD; return -1; + default: + tio->c_cflag &= ~PARENB; + } + return 0; +} + + +/* aktivate second stop bit with 1, 0(default)*/ +static float set_stopflag(t_comport *x, int nr) +{ + struct termios *tio = &(x->com_termio); + + if(nr == 1){ + tio->c_cflag |= CSTOPB; + return 1; + } + else + tio->c_cflag &= ~CSTOPB; + return 0; +} + +/* never testet */ +static int set_ctsrts(t_comport *x, int nr) +{ + struct termios *tio = &(x->com_termio); + + if(nr == 1){ + tio->c_cflag |= CRTSCTS; + return 1; + } + tio->c_cflag &= ~CRTSCTS; + return 0; +} + +static int set_xonxoff(t_comport *x, int nr) +{ + struct termios *tio = &(x->com_termio); + + if(nr == 1){ + tio->c_iflag |= (IXON | IXOFF | IXANY); + return 1; + } + + tio->c_iflag &= ~IXON & ~IXOFF & ~IXANY; + return 0; +} + +static int open_serial(int com_nr, t_comport *x) +{ + HANDLE fd; + struct termios *old = &(x->oldcom_termio); + struct termios *new = &(x->com_termio); + float *baud = &(x->baud); + + if(com_nr < 0 || com_nr >= COMPORT_MAX) { + post("comport open %d, baud %d not valid (args: [portnum] [baud])"); + return INVALID_HANDLE_VALUE; + } + + if((fd = open(sys_com_port[com_nr], OPENPARAMS)) == INVALID_HANDLE_VALUE) + { + post("** ERROR ** could not open device %s:\n failure(%d): %s\n", + sys_com_port[com_nr],errno,strerror(errno)); + return INVALID_HANDLE_VALUE; + } + + /* set no wait on any operation */ + fcntl(fd, F_SETFL, FNDELAY); + + /* Save the Current Port Configuration */ + if(tcgetattr(fd, old) == -1 || tcgetattr(fd, new) == -1){ + post("** ERROR ** could not get termios-structure of device %s\n", + sys_com_port[com_nr]); + close(fd); + return INVALID_HANDLE_VALUE; + } + + + /* Setupt the new port configuration...NON-CANONICAL INPUT MODE + .. as defined in termios.h + */ + + /* enable input and ignore modem controls */ + new->c_cflag |= (CREAD | CLOCAL); + + /* always nocanonical, this means raw i/o no terminal */ + new->c_lflag &= ~(ICANON | ECHO | ECHOE | ISIG); + + /* no post processing */ + new->c_oflag &= ~OPOST; + + /* setup to return after 0 seconds + ..if no characters are received + TIME units are assumed to be 0.1 secs */ + /* not needed anymore ??? in new termios in linux + new->c_cc[VMIN] = 0; + new->c_cc[VTIME] = 0; + */ + + /* defaults, see input */ + + set_bits(x,8); /* CS8 */ + set_stopflag(x,0); /* ~CSTOPB */ + set_ctsrts(x,0); /* ~CRTSCTS;*/ + set_xonxoff(x,1); /* (IXON | IXOFF | IXANY) */ + set_baudrate(x,*baud); + + if(tcsetattr(fd, TCSAFLUSH, new) != -1) + { + post("Opened serial line device %s\n",sys_com_port[com_nr]); + } + else + { + post("** ERROR ** could not set params to ioctl of device %s\n", + sys_com_port[com_nr]); + close(fd); + return INVALID_HANDLE_VALUE; + } + + return fd; +} + + +static int close_serial(t_comport *x) +{ + struct termios *tios = &(x->com_termio); + HANDLE fd = x->comhandle; + + if(fd != INVALID_HANDLE_VALUE){ + tcsetattr(fd, TCSANOW, tios); + close(fd); + } + return INVALID_HANDLE_VALUE; +} + + +static int set_serial(t_comport *x) +{ + if(tcsetattr(x->comhandle, TCSAFLUSH, &(x->com_termio)) == -1) + return 0; + return 1; +} + +static int write_serial(t_comport *x, unsigned char chr) +{ + + return write(x->comhandle,(char *) &chr,1); + + /* flush pending I/O chars */ + /* but nowadays discards them ;-( + else{ + ioctl(x->comhandle,TCFLSH,TCOFLUSH); + } + */ +} + + +#endif /* else NT */ + + +/* ------------------- serial pd methods --------------------------- */ +static void comport_pollintervall(t_comport *x, t_floatarg g) +{ + if (g < 1) g = 1; + x->x_deltime = g; +} + +static void comport_tick(t_comport *x) +{ + unsigned char chr; + int err; + HANDLE fd = x->comhandle; + + x->x_hit = 0; + + + if(fd == INVALID_HANDLE_VALUE) return; + + /* while there are bytes, read them and send them out, ignore errors */ +#ifdef NT + { + DWORD dwCommEvent; + DWORD dwRead; + + err = 0; + +// if (!SetCommMask(x->comhandle, EV_RXCHAR)) +// post(" Error setting communications event mask for serial device"); + +// for ( ; ; ) { +// if (WaitCommEvent(x->comhandle, &dwCommEvent,NULL)) { + do { + + if(ReadFile(x->comhandle, &chr, 1, &dwRead, NULL)) + if(dwRead > 0) + outlet_float(x->x_obj.ob_outlet, (t_float) chr); + else{ + err = -1; + break; + } + } while (dwRead); +// } +// else{ +// post("serial dev: Error in WaitCommEvent"); + // break; +// } + //} + } +#else + { + fd_set com_rfds; + FD_ZERO(&com_rfds); + FD_SET(fd,&com_rfds); + + while((err=select(fd+1,&com_rfds,NULL,NULL,&null_tv)) > 0) { + + err = read(fd,(char *) &chr,1); + + /* while( (err = read(fd,(char *) &chr,1)) > 0){ */ + outlet_float(x->x_obj.ob_outlet, (t_float) chr); + + }; + } +#endif + + if(err < 0){ /* if an readerror detected */ + if(x->rxerrors == 0) /* post it once */ + post("RXERRORS on serial line\n"); + x->rxerrors = 1; /* remember */ + } + + if (!x->x_hit) clock_delay(x->x_clock, 1); +} + +static void comport_float(t_comport *x,t_float f) +{ + unsigned char chr = ((int) f) & 0xFF; /* brutal conv */ + + if (write_serial(x,chr) != 1) + { + post("Write error, maybe TX-OVERRUNS on serial line"); + } +} + +static void *comport_new(t_floatarg comnr, t_floatarg fbaud) { + + t_comport test; + t_comport *x; + int com_nr = comnr; + HANDLE fd; + + +/* Open the Comport for RD and WR and get a handle */ + test.baud = fbaud; + fd = open_serial(com_nr,&test); + + if(fd == INVALID_HANDLE_VALUE ){ + /* postings in open routine */ + return 0; + } + + /* Now nothing really bad could happen so we create the class */ + + x = (t_comport *)pd_new(comport_class); + + x->comport = com_nr; + x->baud = test.baud; + x->comhandle = fd; /* holds the comport handle */ + +#ifdef NT + + memcpy(&(test.dcb_old),&(x->dcb_old),sizeof(DCB)); // save the old com config + memcpy(&(test.dcb),&(x->dcb),sizeof(DCB)); // for the new com config + +#else + /* save the old com and new com config */ + bcopy(&(test.oldcom_termio),&(x->oldcom_termio),sizeof(struct termios)); + bcopy(&(test.com_termio),&(x->com_termio),sizeof(struct termios)); +#endif + + x->rxerrors = 0; /* holds the rx line errors */ + + outlet_new(&x->x_obj, &s_float); + + x->x_hit = 0; + x->x_deltime = 1; + x->x_clock = clock_new(x, (t_method)comport_tick); + + clock_delay(x->x_clock, x->x_deltime); + + return x; +} + + +static void +comport_free(t_comport *x) +{ + post("close serial..."); + + clock_unset(x->x_clock); + clock_free(x->x_clock); + x->comhandle = close_serial(x); +} + +/* ---------------- use serial settings ------------- */ + +static void comport_baud(t_comport *x,t_floatarg f) +{ + if(f == x->baud){ + post("baudrate already %f\n",x->baud); + return; + } + + x->baud = set_baudrate(x,f); + + if(x->comhandle == INVALID_HANDLE_VALUE)return; + + if(set_serial(x) == 0){ + post("** ERROR ** could not set baudrate of device %s\n", + sys_com_port[x->comport]); + } + else post("set baudrate of %s to %f\n",sys_com_port[x->comport],x->baud); +} + +static void comport_bits(t_comport *x,t_floatarg f) +{ + f = set_bits(x,f); + + if(x->comhandle == INVALID_HANDLE_VALUE)return; + + if(set_serial(x) == 0){ + post("** ERROR ** could not set bits of device %s\n", + sys_com_port[x->comport]); + } + else post("set bits of %s to %f\n",sys_com_port[x->comport],f); +} + + +static void comport_parity(t_comport *x,t_floatarg f) +{ + f = set_parity(x,f); + + if(x->comhandle == INVALID_HANDLE_VALUE)return; + + if(set_serial(x) == 0){ + post("** ERROR ** could not set extra paritybit of device %s\n", + sys_com_port[x->comport]); + } + else post("set extra paritybit of %s to %f\n",sys_com_port[x->comport],f); +} + +static void comport_stopbit(t_comport *x,t_floatarg f) +{ + f = set_stopflag(x,f); + + if(x->comhandle == INVALID_HANDLE_VALUE)return; + + if(set_serial(x) == 0){ + post("** ERROR ** could not set extra stopbit of device %s\n", + sys_com_port[x->comport]); + } + else post("set extra stopbit of %s to %f\n",sys_com_port[x->comport],f); +} + +static void comport_rtscts(t_comport *x,t_floatarg f) +{ + f = set_ctsrts(x,f); + + if(x->comhandle == INVALID_HANDLE_VALUE)return; + + if(set_serial(x) == 0){ + post("** ERROR ** could not set rts_cts of device %s\n", + sys_com_port[x->comport]); + } + else post("set rts-cts of %s to %f\n",sys_com_port[x->comport],f); +} + +static void comport_xonxoff(t_comport *x,t_floatarg f) +{ + f = set_xonxoff(x,f); + + if(x->comhandle == INVALID_HANDLE_VALUE)return; + + if(set_serial(x) == 0){ + post("** ERROR ** could not set xonxoff of device %s\n", + sys_com_port[x->comport]); + } + else post("set xonxoff of %s to %f\n",sys_com_port[x->comport],f); +} + +static void comport_close(t_comport *x) +{ + clock_unset(x->x_clock); + x->x_hit = 1; + x->comhandle = close_serial(x); +} + +static void comport_open(t_comport *x, t_floatarg f) +{ + if(x->comhandle != INVALID_HANDLE_VALUE) + comport_close(x); + + + x->comhandle = open_serial(f,x); + + clock_delay(x->x_clock, x->x_deltime); +} + +/* + dangerous but if you really have some stupid devicename ... + you can open any file on systems if suid is set on pd be careful +*/ + +static void comport_devicename(t_comport *x, t_symbol *s) +{ + if(x->comport >= 0 && x->comport < COMPORT_MAX){ + sys_com_port[x->comport] = s->s_name; + } +} + +static void comport_print(t_comport *x, t_symbol *s, int argc, t_atom *argv) +{ + static char buf[256]; + while(argc--) { + atom_string(argv++, buf, 255); + char *pch = buf; + while(*pch != 0) { + write_serial(x, *pch++); + } + if(argc > 0) { + write_serial(x, ' '); + } + } +} +/* ---------------- SETUP OBJECTS ------------------ */ + +void comport_setup(void) +{ + comport_class + = class_new(gensym("comport"), (t_newmethod)comport_new, + (t_method)comport_free, sizeof(t_comport), + 0, A_DEFFLOAT, A_DEFFLOAT, 0); + + class_addfloat(comport_class, (t_method)comport_float); + + /* + class_addbang(comport_class, comport_bang + */ + + + class_addmethod(comport_class, (t_method)comport_baud, gensym("baud"), + A_FLOAT, 0); + + + class_addmethod(comport_class, (t_method)comport_bits, gensym("bits"), + A_FLOAT, 0); + class_addmethod(comport_class, (t_method)comport_stopbit, gensym("stopbit"), + A_FLOAT, 0); + class_addmethod(comport_class, (t_method)comport_rtscts, gensym("rtscts"), + A_FLOAT, 0); + class_addmethod(comport_class, (t_method)comport_parity, gensym("parity"), + A_FLOAT, 0); + class_addmethod(comport_class, (t_method)comport_xonxoff, gensym("xonxoff"), + A_FLOAT, 0); + class_addmethod(comport_class, (t_method)comport_close, gensym("close"), 0); + class_addmethod(comport_class, (t_method)comport_open, gensym("open"), + A_FLOAT, 0); + class_addmethod(comport_class, (t_method)comport_devicename, gensym("devicename"), + A_SYMBOL, 0); + class_addmethod(comport_class, (t_method)comport_print, gensym("print"), + A_GIMME, 0); + + class_addmethod(comport_class, (t_method)comport_pollintervall, gensym("pollintervall"), + A_FLOAT, 0); +#ifndef NT + null_tv.tv_sec = 0; /* no wait */ + null_tv.tv_usec = 0; +#endif +} + + diff --git a/comport/makefile b/comport/makefile new file mode 100644 index 0000000..48e9db2 --- /dev/null +++ b/comport/makefile @@ -0,0 +1,82 @@ +# comport - PD external for unix/windows +# +# (c) 1998-2005 Winfried Ritsch (see LICENCE.txt) +# Institute for Electronic Music - Graz +# +# + +current: + echo choose one command: make pd_linux, make pd_nt, make pd_irix5, make pd_irix6 + +# ----------------------- NT ----------------------- +pd_nt: comport.dll + +.SUFFIXES: .dll + +PDNTCFLAGS = /W3 /WX /DNT /DPD /nologo /DWIN2000 + +VC="C:\Programme\Microsoft Visual Studio\Vc98" +PDROOT="C:\Programme\pd" + +PDNTINCLUDE = /I. /I$(PDROOT)\tcl\include /I$(PDROOT)\src /I$(VC)\include + +PDNTLDIR = $(VC)\lib +PDNTLIB = $(PDNTLDIR)\libc.lib \ + $(PDNTLDIR)\oldnames.lib \ + $(PDNTLDIR)\kernel32.lib \ + $(PDROOT)\bin\pd.lib + +.c.dll: + cl $(PDNTCFLAGS) $(PDNTINCLUDE) /c $*.c + link /dll /export:$*_setup $*.obj $(PDNTLIB) + +# ----------------------- IRIX 5.x ----------------------- +pd_irix5: comport.pd_irix5 + +.SUFFIXES: .pd_irix5 + +SGICFLAGS5 = -o32 -DPD -DSGI -O2 + + +SGIINCLUDE = -I../../src + +.c.pd_irix5: + cc $(SGICFLAGS5) $(SGIINCLUDE) -o $*.o -c $*.c + ld -elf -shared -rdata_shared -o $*.pd_irix5 $*.o + rm $*.o + +# ----------------------- IRIX 6.x ----------------------- +pd_irix6: comport.pd_irix6 + +.SUFFIXES: .pd_irix6 + +SGICFLAGS6 = -DPD -DSGI -n32 \ + -OPT:roundoff=3 -OPT:IEEE_arithmetic=3 -OPT:cray_ivdep=true \ + -Ofast=ip32 + +SGICFLAGS5 = -DPD -O2 -DSGI + +SGIINCLUDE = -I/../../src + +.c.pd_irix6: + cc $(SGICFLAGS6) $(SGIINCLUDE) -o $*.o -c $*.c + ld -elf -shared -rdata_shared -o $*.pd_irix6 $*.o + rm $*.o + +# ----------------------- LINUX i386 ----------------------- + +pd_linux: comport.pd_linux + +.SUFFIXES: .pd_linux + +LINUXCFLAGS = -DPD -O2 -funroll-loops -fomit-frame-pointer \ + -Wall -W -Wshadow -Wstrict-prototypes -Werror \ + -Wno-unused -Wno-parentheses -Wno-switch + +LINUXINCLUDE = -I../../src + +.c.pd_linux: + cc $(LINUXCFLAGS) $(LINUXINCLUDE) -o $*.o -c $*.c + ld -export_dynamic -shared -o $*.pd_linux $*.o -lc -lm + strip --strip-unneeded $*.pd_linux + rm $*.o diff --git a/comport/testcomport.pd b/comport/testcomport.pd new file mode 100644 index 0000000..0dbfcf2 --- /dev/null +++ b/comport/testcomport.pd @@ -0,0 +1,81 @@ +#N canvas 199 244 693 475 10; +#X obj 97 231 comport 1 9600; +#X msg 13 213 66; +#X obj 88 361 print; +#X floatatom 195 190 4 0 0 0 - - -; +#X msg 12 171 64; +#X text 12 191 point; +#X text 11 150 stream; +#X msg 13 263 86; +#X text 13 238 position; +#X msg 16 307 70; +#X msg 14 347 71; +#X text 15 290 run; +#X text 14 325 sleep; +#X floatatom 121 269 4 0 0 0 - - -; +#X obj 90 325 spigot; +#X msg 109 298 1; +#X msg 143 299 0; +#X msg 314 48 bits 8; +#X msg 313 72 stopbit 0; +#X msg 312 100 parity 0; +#X msg 313 129 xonxoff 1; +#X msg 313 155 rtscts 0; +#X text 392 103 parity 1=even \, -1=odd \, 0=off; +#X text 392 74 extra stopbit 1=on \, 0=off; +#X text 394 49 databits 5 \, 6 \, 7 \, 8; +#X text 393 20 use exact or higher baudrate; +#X obj 94 200 r comctl; +#X obj 271 294 s comctl; +#X text 394 128 use handshake xon/off 1=on 0=off; +#X text 392 154 cts/rts hardwarehandshake 1=on 0=off; +#X msg 318 201 pollintervall 1; +#X text 430 191 set pollintervall for read in ms; +#X text 430 205 (default is 1 tick 1ms); +#X msg 317 233 close; +#X msg 317 259 open 1; +#X msg 314 23 baud 10000; +#X text 383 230 Close Serial port; +#X text 381 263 Open seriel board Nr (0=COM1 \, 1=COM2 \, ...); +#X msg 263 354 devicename /dev/ttyS1; +#X text 257 375 Danger !!! you can open every file in your system and +maybe if suid is root damage the system.; +#X text 258 336 set devicename for actuell port \, then close and open +again; +#X obj 195 165 spigot; +#X msg 214 138 1; +#X msg 247 143 0; +#X obj 190 112 key; +#X text 260 324 never should be needed except for sys admins (only +unix); +#X msg 309 0 baud 300; +#X text 3 -10 (C) 1998-2005 IEM Winfried Ritsch GPL (see LICENSE.txt) +; +#X text 14 388; +#X text 1 41 please improve...; +#X connect 0 0 13 0; +#X connect 0 0 14 0; +#X connect 1 0 0 0; +#X connect 3 0 0 0; +#X connect 4 0 0 0; +#X connect 7 0 0 0; +#X connect 9 0 0 0; +#X connect 10 0 0 0; +#X connect 14 0 2 0; +#X connect 15 0 14 1; +#X connect 16 0 14 1; +#X connect 17 0 27 0; +#X connect 18 0 27 0; +#X connect 19 0 27 0; +#X connect 20 0 27 0; +#X connect 21 0 27 0; +#X connect 26 0 0 0; +#X connect 30 0 27 0; +#X connect 33 0 27 0; +#X connect 34 0 27 0; +#X connect 35 0 27 0; +#X connect 41 0 3 0; +#X connect 42 0 41 1; +#X connect 43 0 41 1; +#X connect 44 0 41 0; +#X connect 46 0 27 0; diff --git a/docs/Serial-Programming-HOWTO.book.pdf b/docs/Serial-Programming-HOWTO.book.pdf new file mode 100644 index 0000000..91328af Binary files /dev/null and b/docs/Serial-Programming-HOWTO.book.pdf differ diff --git a/docs/serial.doc b/docs/serial.doc new file mode 100644 index 0000000..8cd6310 Binary files /dev/null and b/docs/serial.doc differ diff --git a/docs/serial.pdf b/docs/serial.pdf new file mode 100644 index 0000000..b901cea --- /dev/null +++ b/docs/serial.pdf @@ -0,0 +1,1565 @@ +%PDF-1.2 +% +1 0 obj<>endobj +2 0 obj<>endobj +3 0 obj<>endobj +4 0 obj<>endobj +5 0 obj<>endobj +6 0 obj<>endobj +7 0 obj<>endobj +8 0 obj<>endobj +9 0 obj<>endobj +10 0 obj<>endobj +11 0 obj<>endobj +12 0 obj<>endobj +13 0 obj<>endobj +14 0 obj<>endobj +15 0 obj<>endobj +16 0 obj<>endobj +17 0 obj<>endobj +18 0 obj<>endobj +19 0 obj<>endobj +20 0 obj<>endobj +21 0 obj<>endobj +22 0 obj<>endobj +23 0 obj<>endobj +24 0 obj<>endobj +25 0 obj<>endobj +26 0 obj<>endobj +27 0 obj<>endobj +28 0 obj<>endobj +29 0 obj<>endobj +30 0 obj<>endobj +31 0 obj<>endobj +32 0 obj<>endobj +33 0 obj<>endobj +34 0 obj<>endobj +35 0 obj<>endobj +36 0 obj<>endobj +37 0 obj<>endobj +38 0 obj[12 0 R +13 0 R +14 0 R +15 0 R +16 0 R +17 0 R +18 0 R +19 0 R +20 0 R +21 0 R +22 0 R +23 0 R +24 0 R +25 0 R +26 0 R +27 0 R +28 0 R +29 0 R +30 0 R +31 0 R +32 0 R +33 0 R +34 0 R +35 0 R +36 0 R +37 0 R +]endobj +39 0 obj<>endobj +40 0 obj<>endobj +41 0 obj<>endobj +42 0 obj<>endobj +43 0 obj<>endobj +44 0 obj<>endobj +45 0 obj<>endobj +46 0 obj<>endobj +47 0 obj[40 0 R +42 0 R +44 0 R +46 0 R +]endobj +48 0 obj<>endobj +49 0 obj<>endobj +50 0 obj<>endobj +51 0 obj<>endobj +52 0 obj<>endobj +53 0 obj<>endobj +54 0 obj<>endobj +55 0 obj[48 0 R +49 0 R +50 0 R +51 0 R +52 0 R +53 0 R +54 0 R +]endobj +56 0 obj<>endobj +57 0 obj<>endobj +58 0 obj<>endobj +59 0 obj<>endobj +60 0 obj<>endobj +61 0 obj[56 0 R +57 0 R +58 0 R +59 0 R +60 0 R +]endobj +62 0 obj<>endobj +63 0 obj[62 0 R +]endobj +64 0 obj<>endobj +65 0 obj<>endobj +66 0 obj<>endobj +67 0 obj<>endobj +68 0 obj<>endobj +69 0 obj<>endobj +70 0 obj[64 0 R +65 0 R +66 0 R +67 0 R +68 0 R +69 0 R +]endobj +71 0 obj<>endobj +72 0 obj<>endobj +73 0 obj<>endobj +74 0 obj<>endobj +75 0 obj<>endobj +76 0 obj<>endobj +77 0 obj<>endobj +78 0 obj<>endobj +79 0 obj<>endobj +80 0 obj<>endobj +81 0 obj<>endobj +82 0 obj<>endobj +83 0 obj<>endobj +84 0 obj<>endobj +85 0 obj<>endobj +86 0 obj<>endobj +87 0 obj<>endobj +88 0 obj<>endobj +89 0 obj<>endobj +90 0 obj<>endobj +91 0 obj<>endobj +92 0 obj<>endobj +93 0 obj<>endobj +94 0 obj<>endobj +95 0 obj<>endobj +96 0 obj<>endobj +97 0 obj<>endobj +98 0 obj<>endobj +99 0 obj<>endobj +100 0 obj<>endobj +101 0 obj<>endobj +102 0 obj<>endobj +103 0 obj<>endobj +104 0 obj<>endobj +105 0 obj<>endobj +106 0 obj<>endobj +107 0 obj<>endobj +108 0 obj<>endobj +109 0 obj<>endobj +110 0 obj<>endobj +111 0 obj<>endobj +112 0 obj<>endobj +113 0 obj<>endobj +114 0 obj<>endobj +115 0 obj<>endobj +116 0 obj<>endobj +117 0 obj<>endobj +118 0 obj<>endobj +119 0 obj<>endobj +120 0 obj<>endobj +121 0 obj<>endobj +122 0 obj<>endobj +123 0 obj<>endobj +124 0 obj<>endobj +125 0 obj<>endobj +126 0 obj<>endobj +127 0 obj<>endobj +128 0 obj<>endobj +129 0 obj<>endobj +130 0 obj<>endobj +131 0 obj<>endobj +132 0 obj<>endobj +133 0 obj<>endobj +134 0 obj<>endobj +135 0 obj<>endobj +136 0 obj<>endobj +137 0 obj<>endobj +138 0 obj<>endobj +139 0 obj<>endobj +140 0 obj<>endobj +141 0 obj<>endobj +142 0 obj<>endobj +143 0 obj<>endobj +144 0 obj<>endobj +145 0 obj<>endobj +146 0 obj<>endobj +147 0 obj<>endobj +148 0 obj<>endobj +149 0 obj<>endobj +150 0 obj<>endobj +151 0 obj<>endobj +152 0 obj<>endobj +153 0 obj<>endobj +154 0 obj<>endobj +155 0 obj<>endobj +156 0 obj<>endobj +157 0 obj<>endobj +158 0 obj<>endobj +159 0 obj<>endobj +160 0 obj<>endobj +161 0 obj<>endobj +162 0 obj<>endobj +163 0 obj<>endobj +164 0 obj<>endobj +165 0 obj<>endobj +166 0 obj<>endobj +167 0 obj<>endobj +168 0 obj<>endobj +169 0 obj<>endobj +170 0 obj<>endobj +171 0 obj<>endobj +172 0 obj<>endobj +173 0 obj<>endobj +174 0 obj<>endobj +175 0 obj<>endobj +176 0 obj<>endobj +177 0 obj<>endobj +178 0 obj<>endobj +179 0 obj<>endobj +180 0 obj<>endobj +181 0 obj<>endobj +182 0 obj<>endobj +183 0 obj<>endobj +184 0 obj<>endobj +185 0 obj<>endobj +186 0 obj<>endobj +187 0 obj<>endobj +188 0 obj<>endobj +189 0 obj<>endobj +190 0 obj<>endobj +191 0 obj<>endobj +192 0 obj<>endobj +193 0 obj<>endobj +194 0 obj<>endobj +195 0 obj<>endobj +196 0 obj<>endobj +197 0 obj<>endobj +198 0 obj<>endobj +199 0 obj<>endobj +200 0 obj<>endobj +201 0 obj<>endobj +202 0 obj<>endobj +203 0 obj<>endobj +204 0 obj<>endobj +205 0 obj<>endobj +206 0 obj<>endobj +207 0 obj<>endobj +208 0 obj<>endobj +209 0 obj<>endobj +210 0 obj<>endobj +211 0 obj<>endobj +212 0 obj<>endobj +213 0 obj<>endobj +214 0 obj<>endobj +215 0 obj<>endobj +216 0 obj<>endobj +217 0 obj<>endobj +218 0 obj<>endobj +219 0 obj<>endobj +220 0 obj<>endobj +221 0 obj<>endobj +222 0 obj<>endobj +223 0 obj<>endobj +224 0 obj[71 0 R +72 0 R +73 0 R +74 0 R +75 0 R +76 0 R +77 0 R +78 0 R +79 0 R +80 0 R +81 0 R +82 0 R +83 0 R +84 0 R +85 0 R +86 0 R +87 0 R +88 0 R +89 0 R +90 0 R +91 0 R +92 0 R +93 0 R +94 0 R +95 0 R +96 0 R +97 0 R +98 0 R +99 0 R +100 0 R +101 0 R +102 0 R +103 0 R +104 0 R +105 0 R +106 0 R +107 0 R +108 0 R +109 0 R +110 0 R +111 0 R +112 0 R +113 0 R +114 0 R +115 0 R +116 0 R +117 0 R +118 0 R +119 0 R +120 0 R +121 0 R +122 0 R +123 0 R +124 0 R +125 0 R +126 0 R +127 0 R +128 0 R +129 0 R +130 0 R +131 0 R +132 0 R +133 0 R +134 0 R +135 0 R +136 0 R +137 0 R +138 0 R +139 0 R +140 0 R +141 0 R +142 0 R +143 0 R +144 0 R +145 0 R +146 0 R +147 0 R +148 0 R +149 0 R +150 0 R +151 0 R +152 0 R +153 0 R +154 0 R +155 0 R +156 0 R +157 0 R +158 0 R +159 0 R +160 0 R +161 0 R +162 0 R +163 0 R +164 0 R +165 0 R +166 0 R +167 0 R +168 0 R +169 0 R +170 0 R +171 0 R +172 0 R +173 0 R +174 0 R +175 0 R +176 0 R +177 0 R +178 0 R +179 0 R +180 0 R +181 0 R +182 0 R +183 0 R +184 0 R +185 0 R +186 0 R +187 0 R +188 0 R +189 0 R +190 0 R +191 0 R +192 0 R +193 0 R +194 0 R +195 0 R +196 0 R +197 0 R +198 0 R +199 0 R +200 0 R +201 0 R +202 0 R +203 0 R +204 0 R +205 0 R +206 0 R +207 0 R +208 0 R +209 0 R +210 0 R +211 0 R +212 0 R +213 0 R +214 0 R +215 0 R +216 0 R +217 0 R +218 0 R +219 0 R +220 0 R +221 0 R +222 0 R +223 0 R +]endobj +225 0 obj<>endobj +226 0 obj<>endobj +227 0 obj<>endobj +228 0 obj<>endobj +229 0 obj<>endobj +230 0 obj<>endobj +231 0 obj<>endobj +232 0 obj[225 0 R +226 0 R +227 0 R +228 0 R +229 0 R +230 0 R +231 0 R +]endobj +233 0 obj<>endobj +234 0 obj<>endobj +235 0 obj<>endobj +236 0 obj<>endobj +237 0 obj<>endobj +238 0 obj<>endobj +239 0 obj<>endobj +240 0 obj<>endobj +241 0 obj<>endobj +242 0 obj<>endobj +243 0 obj<>endobj +244 0 obj<>endobj +245 0 obj<>endobj +246 0 obj<>endobj +247 0 obj<>endobj +248 0 obj<>endobj +249 0 obj<>endobj +250 0 obj<>endobj +251 0 obj<>endobj +252 0 obj<>endobj +253 0 obj<>endobj +254 0 obj<>endobj +255 0 obj<>endobj +256 0 obj<>endobj +257 0 obj<>endobj +258 0 obj<>endobj +259 0 obj<>endobj +260 0 obj<>endobj +261 0 obj<>endobj +262 0 obj<>endobj +263 0 obj<>endobj +264 0 obj<>endobj +265 0 obj<>endobj +266 0 obj<>endobj +267 0 obj<>endobj +268 0 obj<>endobj +269 0 obj<>endobj +270 0 obj<>endobj +271 0 obj<>endobj +272 0 obj<>endobj +273 0 obj<>endobj +274 0 obj<>endobj +275 0 obj<>endobj +276 0 obj<>endobj +277 0 obj<>endobj +278 0 obj<>endobj +279 0 obj<>endobj +280 0 obj<>endobj +281 0 obj<>endobj +282 0 obj<>endobj +283 0 obj<>endobj +284 0 obj<>endobj +285 0 obj<>endobj +286 0 obj<>endobj +287 0 obj<>endobj +288 0 obj<>>>>>endobj +289 0 obj<>stream +xM0Fm`ɾdAB,zbFbX!,XHdWN@R"竲#UTw&?c~/pkΛx U{,?|mؽnޛ֜_~4_myۜ>:cY6ooaC^.侚МwoFr7 她}}HqLc34fyf3LHfQ`R//G>uWǂrdr (O0Uh99uhޑyK0qW憞O::^kJ  :*_Łp$Cp<:Rcva7TؘB@h4 e:u7TH*,ȴ p$zCC0M@+FytE|Pa=Yy!pWM$j 8RX KNBy7J/CG-PW!*%*dA8-}ݲ7@y!@&B%)\q@7S8-&dr +E?0w>55-EeT/j..7;`} + -«,ZPu%B5rtDwyMKt@y 8lHFVTxr +"юqgƺ N[ rм|Լoendstream +endobj +290 0 obj +725 +endobj +291 0 obj<>>>endobj +292 0 obj<>stream +x+2T0BCc3Jr +r +HHendstream +endobj +293 0 obj +31 +endobj +294 0 obj<>>>/Annots 38 0 R>>endobj +295 0 obj<>stream +xM8>&Uذ2RaR58 aȯW Z8&E ҿ\|< +zӌSQNFݢK4q-d~O!Gc6u|VQFRn(EύH8jH;^Fz:T5+ڋ,GS-jWUdaHy9۰TP|DƋ(Pie"GEYeAW0Ո/Dc@i'2^Uf[:vH`CY)n;hԙbAH +[\EiKx]d@[@NSq]t%Oxȉ!c؜Sn4U0q2omT)K/ڴ6%i:Ӭ&I+c>MZ䠇{ %zy?8a?oH"8sE<*YibC"T; 0>KZI/& =@E9h<]6nLzoÙꑿBuC,!Y+.ǻ/zˎ!Z,.ˡ;}(&+T.7}!=Flh) +Կ^GO08{h mB)T 3]G +}a?|r] 5 s.oNKcO]^twa7endstream +endobj +296 0 obj +1013 +endobj +297 0 obj<>>>>>endobj +298 0 obj<>stream +x- Ew:j\Mtj #thI}3ݗ\4 yS#eVҒO)Nwa⌅1lн,TyYFz Yb(؍}Rx*endstream +endobj +299 0 obj +138 +endobj +300 0 obj<>>>>>endobj +301 0 obj<>stream +xVrF+&a>$:lRQ. `@ `݅hӳLRҁ$3==>Y [jMY5L><➒6wn%%aϖ}VNgLA_jU҃֙} Unh*PfZn쵣/koMfuRe\-I9G]ܑ+O2q8O(д`iXu#%so }ucš +fgUwlm>(—|UB_Z\w@ yjW cLs{b2"@8ZZ@ >`F7񢀹̵@mΝ5UC|JQ+=}/ttJd u5F׻AQSVٞ):XŪ Eɴ(#d9cW#?J'7XOuZzxS3~(zk FR"Cwxm +50@L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3~\ )Z.}"Sڵ8 Q#Tuo^bkG6}O:ҢSbd{aBz>~ZjM82Zώ}4T,,^4aDwZ){73qq,CZ[@4 Qu^DѫIqm8\7P>Xlp`"rƣ)(`vGI^w `%<К8YO曭4uU6~fL{.Ȗ7,dt ngbiSK.2cKakim;{qG{ȻON22pbcendstream +endobj +356 0 obj +763 +endobj +357 0 obj<>>>>>endobj +358 0 obj<>stream +xVksFίÇۼNPS&FS7cy703Rkf/نVM=anSx>>ύ>u,+7'&raMws1kS~ѽ0dVLkaJR:UN=ctaUy d6HLKiamgx4C `_5sUbN't~K_{ک +˨3(]2></uj]"DvOX!s񗡭(EP$R-#Wq%oYq\.9iӴ veJx/: drπ|,9ܶUgI(UMJiiS즹a_ ӂtI:%#Q_A۾QFh$QDZk.b!Դ?493N:4M^$1YG9-BmC97ԻK/@]-!B#&d +>C:GAx3DF_S #"BbxF䓰OTVWAVKB5se_d?Sw^ ?^?·[D3!!A݄w +Y..:}۵t& +ZսbpuO3VM<иئF)۱'y33pha-_?o^ӖNƯ%-endstream +endobj +359 0 obj +1103 +endobj +360 0 obj<>>>>>endobj +361 0 obj<>stream +xVrF}Wt% +d-ybκdAbIL[u ӗӧÒ.)>gw\ +8qgaD lrDce<! !?8ےʪ(6d6QQnS)MJEHSJF*%Im6FhS61ڧK3DEd.}? e:SΓ:_'iG**MՖa+hY(Y'>QAhWIZJ]W"#O5RBH%g\Ho6IVL-tQ$FyRT%B1{W::;6 +'ԣI/#VJjgAwCdkG\?5k᳴U֠1'ljI8MU]rJv9hxݹC7(;^0M:6f@B +n%\A )l\<7燱ـ`1fmJ0u !~VtFїp6?I'_p<'_g8軚%JT1^< %OA|-S8>: G +IIUwUd(Sd^r#aWb_ Sqr3 Wa +Y406(Y$4-֪(d~4bqZAc0>>>>>endobj +364 0 obj<>stream +x- DwFZ46j5 5ep%BJq5w]ݓ0(N:duP` ePR/:㭺svp|YmON*{y)o$Q?(Syos5j5&b֒b|-endstream +endobj +365 0 obj +144 +endob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Y'ny3 P>+[mӬQ*C)mLǓK9 Xj Fd˸`R- |- qLhqS(И܁uVGQg'Ѿwe%PLۺh`omp,wvŀ8hgbFcA(R^סO'w\endstream +endobj +407 0 obj +348 +endobj +408 0 obj<>endobj +409 0 obj<>endobj +410 0 obj<>endobj +411 0 obj<>endobj +412 0 obj<>endobj +413 0 obj<>endobj +414 0 obj<>endobj +415 0 obj<>endobj +416 0 obj<>endobj +417 0 obj<>endobj +418 0 obj<>endobj +419 0 obj<>endobj +420 0 obj<>endobj +421 0 obj<>endobj +422 0 obj<>endobj +423 0 obj<>endobj +424 0 obj<>endobj +425 0 obj<>endobj +426 0 obj<>endobj +427 0 obj<>endobj +428 0 obj<>endobj +429 0 obj<>endobj +430 0 obj<>endobj +431 0 obj<>endobj +432 0 obj<>endobj +433 0 obj<>endobj +434 0 obj<>endobj +435 0 obj<>endobj +436 0 obj<>endobj +437 0 obj<>endobj +438 0 obj<>endobj +439 0 obj<>endobj +440 0 obj<>endobj +441 0 obj<>endobj +442 0 obj<>endobj +443 0 obj<>endobj +444 0 obj<>endobj +445 0 obj<>endobj +446 0 obj<>endobj +447 0 obj<>endobj +448 0 obj<>endobj +449 0 obj<>endobj +450 0 obj<>endobj +451 0 obj<>endobj +452 0 obj<>endobj +453 0 obj<>endobj +454 0 obj<>1<>2<>4<>]>>>>endobj +xref +0 455 +0000000000 65535 f +0000000015 00000 n +0000000239 00000 n +0000001796 00000 n +0000001870 00000 n +0000001952 00000 n +0000002030 00000 n +0000002107 00000 n +0000002186 00000 n +0000002269 00000 n +0000002350 00000 n +0000002435 00000 n +0000002494 00000 n +0000002599 00000 n +0000002704 00000 n +0000002809 00000 n +0000002914 00000 n +0000003019 00000 n +0000003124 00000 n +0000003229 00000 n +0000003334 00000 n +0000003439 00000 n +0000003544 00000 n +0000003649 00000 n +0000003754 00000 n +0000003859 00000 n +0000003964 00000 n +0000004069 00000 n +0000004174 00000 n +0000004279 00000 n +0000004384 00000 n +0000004489 00000 n +0000004594 00000 n +0000004699 00000 n +0000004804 00000 n +0000004909 00000 n +0000005014 00000 n +0000005119 00000 n +0000005224 00000 n +0000005423 00000 n +0000005472 00000 n +0000005557 00000 n +0000005606 00000 n +0000005691 00000 n +0000005740 00000 n +0000005823 00000 n +0000005872 00000 n +0000005956 00000 n +0000006001 00000 n +0000006106 00000 n +0000006209 00000 n +0000006313 00000 n +0000006418 00000 n +0000006523 00000 n +0000006628 00000 n +0000006733 00000 n +0000006799 00000 n +0000006904 00000 n +0000007009 00000 n +0000007114 00000 n +0000007219 00000 n +0000007324 00000 n +0000007376 00000 n +0000007481 00000 n +0000007505 00000 n +0000007609 00000 n +0000007714 00000 n +0000007819 00000 n +0000007924 00000 n +0000008029 00000 n +0000008134 00000 n +0000008193 00000 n +0000008297 00000 n +0000008401 00000 n +0000008506 00000 n +0000008611 00000 n +0000008716 00000 n +0000008821 00000 n +0000008926 00000 n +0000009031 00000 n +0000009136 00000 n +0000009241 00000 n +0000009346 00000 n +0000009451 00000 n +0000009556 00000 n +0000009661 00000 n +0000009766 00000 n +0000009871 00000 n +0000009976 00000 n +0000010081 00000 n +0000010186 00000 n +0000010291 00000 n +0000010396 00000 n +0000010501 00000 n +0000010606 00000 n +0000010711 00000 n +0000010816 00000 n +0000010921 00000 n +0000011026 00000 n +0000011131 00000 n +0000011236 00000 n +0000011342 00000 n +0000011448 00000 n +0000011554 00000 n +0000011660 00000 n +0000011766 00000 n +0000011872 00000 n +0000011978 00000 n +0000012084 00000 n +0000012190 00000 n +0000012296 00000 n +0000012402 00000 n +0000012508 00000 n +0000012614 00000 n +0000012720 00000 n +0000012826 00000 n +0000012932 00000 n +0000013038 00000 n +0000013144 00000 n +0000013250 00000 n +0000013356 00000 n +0000013462 00000 n +0000013568 00000 n +0000013674 00000 n +0000013780 00000 n +0000013886 00000 n +0000013992 00000 n +0000014098 00000 n +0000014204 00000 n +0000014309 00000 n +0000014415 00000 n +0000014521 00000 n +0000014627 00000 n +0000014733 00000 n +0000014839 00000 n +0000014945 00000 n +0000015051 00000 n +0000015157 00000 n +0000015263 00000 n +0000015369 00000 n +0000015475 00000 n +0000015581 00000 n +0000015687 00000 n +0000015793 00000 n +0000015899 00000 n +0000016005 00000 n +0000016111 00000 n +0000016217 00000 n +0000016323 00000 n +0000016428 00000 n +0000016534 00000 n +0000016640 00000 n +0000016746 00000 n +0000016852 00000 n +0000016958 00000 n +0000017064 00000 n +0000017170 00000 n +0000017276 00000 n +0000017382 00000 n +0000017488 00000 n +0000017594 00000 n +0000017700 00000 n +0000017806 00000 n +0000017912 00000 n +0000018018 00000 n +0000018124 00000 n +0000018230 00000 n +0000018336 00000 n +0000018441 00000 n +0000018547 00000 n +0000018653 00000 n +0000018759 00000 n +0000018865 00000 n +0000018971 00000 n +0000019077 00000 n +0000019183 00000 n +0000019289 00000 n +0000019395 00000 n +0000019501 00000 n +0000019607 00000 n +0000019713 00000 n +0000019819 00000 n +0000019925 00000 n +0000020031 00000 n +0000020137 00000 n +0000020243 00000 n +0000020349 00000 n +0000020455 00000 n +0000020561 00000 n +0000020667 00000 n +0000020773 00000 n +0000020879 00000 n +0000020985 00000 n +0000021091 00000 n +0000021197 00000 n +0000021303 00000 n +0000021409 00000 n +0000021515 00000 n +0000021621 00000 n +0000021727 00000 n +0000021833 00000 n +0000021939 00000 n +0000022045 00000 n +0000022151 00000 n +0000022257 00000 n +0000022363 00000 n +0000022469 00000 n +0000022575 00000 n +0000022681 00000 n +0000022787 00000 n +0000022893 00000 n +0000022999 00000 n +0000023104 00000 n +0000023210 00000 n +0000023316 00000 n +0000023422 00000 n +0000023528 00000 n +0000023633 00000 n +0000023738 00000 n +0000023842 00000 n +0000023946 00000 n +0000024050 00000 n +0000024154 00000 n +0000024258 00000 n +0000024362 00000 n +0000025575 00000 n +0000025679 00000 n +0000025783 00000 n +0000025888 00000 n +0000025994 00000 n +0000026100 00000 n +0000026205 00000 n +0000026311 00000 n +0000026385 00000 n +0000026419 00000 n +0000026453 00000 n +0000027256 00000 n +0000027305 00000 n +0000027354 00000 n +0000027403 00000 n +0000027451 00000 n +0000027500 00000 n +0000027549 00000 n +0000027598 00000 n +0000027647 00000 n +0000027696 00000 n +0000027745 00000 n +0000027794 00000 n +0000027843 00000 n +0000027892 00000 n +0000027941 00000 n +0000027990 00000 n +0000028039 00000 n +0000028088 00000 n +0000028137 00000 n +0000028186 00000 n +0000028235 00000 n +0000028284 00000 n +0000028333 00000 n +0000028382 00000 n +0000028431 00000 n +0000028480 00000 n +0000028528 00000 n +0000028577 00000 n +0000028626 00000 n +0000028675 00000 n +0000028724 00000 n +0000028773 00000 n +0000028822 00000 n +0000028871 00000 n +0000028920 00000 n +0000028969 00000 n +0000029018 00000 n +0000029067 00000 n +0000029116 00000 n +0000029165 00000 n +0000029214 00000 n +0000029263 00000 n +0000029312 00000 n +0000029361 00000 n +0000029410 00000 n +0000029459 00000 n +0000029508 00000 n +0000029557 00000 n +0000029606 00000 n +0000029655 00000 n +0000029704 00000 n +0000029753 00000 n +0000030142 00000 n +0000030295 00000 n +0000031091 00000 n +0000031112 00000 n +0000031207 00000 n +0000031309 00000 n +0000031329 00000 n +0000031485 00000 n +0000032569 00000 n +0000032591 00000 n +0000032705 00000 n +0000032914 00000 n +0000032935 00000 n +0000033076 00000 n +0000034216 00000 n +0000034238 00000 n +0000034402 00000 n +0000036500 00000 n +0000036522 00000 n +0000036663 00000 n +0000037912 00000 n +0000037934 00000 n +0000038110 00000 n +0000044227 00000 n +0000044249 00000 n +0000044422 00000 n +0000046081 00000 n +0000046103 00000 n +0000046253 00000 n +0000047480 00000 n +0000047502 00000 n +0000047652 00000 n +0000049062 00000 n +0000049084 00000 n +0000049198 00000 n +0000049407 00000 n +0000049428 00000 n +0000049587 00000 n +0000050471 00000 n +0000050492 00000 n +0000050642 00000 n +0000051772 00000 n +0000051794 00000 n +0000051953 00000 n +0000053579 00000 n +0000053601 00000 n +0000053760 00000 n +0000055100 00000 n +0000055122 00000 n +0000055291 00000 n +0000056329 00000 n +0000056350 00000 n +0000056509 00000 n +0000057874 00000 n +0000057896 00000 n +0000058055 00000 n +0000059625 00000 n +0000059647 00000 n +0000059806 00000 n +0000061142 00000 n +0000061164 00000 n +0000061323 00000 n +0000062638 00000 n +0000062660 00000 n +0000062833 00000 n +0000064559 00000 n +0000064581 00000 n +0000064731 00000 n +0000065565 00000 n +0000065586 00000 n +0000065718 00000 n +0000066892 00000 n +0000066914 00000 n +0000067073 00000 n +0000068393 00000 n +0000068415 00000 n +0000068529 00000 n +0000068744 00000 n +0000068765 00000 n +0000068938 00000 n +0000069980 00000 n +0000070001 00000 n +0000070160 00000 n +0000071520 00000 n +0000071542 00000 n +0000071692 00000 n +0000072640 00000 n +0000072661 00000 n +0000072811 00000 n +0000074261 00000 n +0000074283 00000 n +0000074433 00000 n +0000075576 00000 n +0000075598 00000 n +0000075739 00000 n +0000076413 00000 n +0000076434 00000 n +0000076596 00000 n +0000078373 00000 n +0000078395 00000 n +0000078557 00000 n +0000081025 00000 n +0000081047 00000 n +0000081209 00000 n +0000084804 00000 n +0000084826 00000 n +0000084979 00000 n +0000086560 00000 n +0000086582 00000 n +0000086723 00000 n +0000087617 00000 n +0000087638 00000 n +0000087761 00000 n +0000089013 00000 n +0000089035 00000 n +0000089191 00000 n +0000092602 00000 n +0000092624 00000 n +0000092780 00000 n +0000093199 00000 n +0000093220 00000 n +0000093275 00000 n +0000093380 00000 n +0000093493 00000 n +0000093672 00000 n +0000093791 00000 n +0000093943 00000 n +0000094036 00000 n +0000094200 00000 n +0000094325 00000 n +0000094438 00000 n +0000094542 00000 n +0000094669 00000 n +0000094815 00000 n +0000094920 00000 n +0000095042 00000 n +0000095167 00000 n +0000095294 00000 n +0000095403 00000 n +0000095578 00000 n +0000095717 00000 n +0000095820 00000 n +0000095934 00000 n +0000096048 00000 n +0000096163 00000 n +0000096269 00000 n +0000096437 00000 n +0000096541 00000 n +0000096691 00000 n +0000096802 00000 n +0000096925 00000 n +0000097100 00000 n +0000097242 00000 n +0000097357 00000 n +0000097485 00000 n +0000097610 00000 n +0000097768 00000 n +0000097878 00000 n +0000098007 00000 n +0000098137 00000 n +0000098293 00000 n +0000098395 00000 n +0000098510 00000 n +0000098639 00000 n +0000098738 00000 n +0000098893 00000 n +0000098981 00000 n +trailer +<> +startxref +99209 +%%EOF diff --git a/licence.txt b/licence.txt new file mode 100644 index 0000000..ecd9d35 --- /dev/null +++ b/licence.txt @@ -0,0 +1,361 @@ +comport - PD External for the serial Ports + + + +Institute for Electronic Music and Acoustics +Copyright (C) 1998-2005 Winfried Ritsch + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. (see below) + +--------------------------- GPL.TXT ------------------------- + + + GNU GENERAL PUBLIC LICENSE + Version 2, June 1991 + + Copyright (C) 1989, 1991 Free Software Foundation, Inc. + 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to share and change free +software--to make sure the software is free for all its users. This +General Public License applies to most of the Free Software +Foundation's software and to any other program whose authors commit to +using it. (Some other Free Software Foundation software is covered by +the GNU Library General Public License instead.) You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. + + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if you +distribute copies of the software, or if you modify it. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must give the recipients all the rights that +you have. You must make sure that they, too, receive or can get the +source code. And you must show them these terms so they know their +rights. + + We protect your rights with two steps: (1) copyright the software, and +(2) offer you this license which gives you legal permission to copy, +distribute and/or modify the software. + + Also, for each author's protection and ours, we want to make certain +that everyone understands that there is no warranty for this free +software. If the software is modified by someone else and passed on, we +want its recipients to know that what they have is not the original, so +that any problems introduced by others will not reflect on the original +authors' reputations. + + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that redistributors of a free +program will individually obtain patent licenses, in effect making the +program proprietary. To prevent this, we have made it clear that any +patent must be licensed for everyone's free use or not licensed at all. + + The precise terms and conditions for copying, distribution and +modification follow. + + + GNU GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License applies to any program or other work which contains +a notice placed by the copyright holder saying it may be distributed +under the terms of this General Public License. The "Program", below, +refers to any such program or work, and a "work based on the Program" +means either the Program or any derivative work under copyright law: +that is to say, a work containing the Program or a portion of it, +either verbatim or with modifications and/or translated into another +language. (Hereinafter, translation is included without limitation in +the term "modification".) Each licensee is addressed as "you". + +Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running the Program is not restricted, and the output from the Program +is covered only if its contents constitute a work based on the +Program (independent of having been made by running the Program). +Whether that is true depends on what the Program does. + + 1. You may copy and distribute verbatim copies of the Program's +source code as you receive it, in any medium, provided that you +conspicuously and appropriately publish on each copy an appropriate +copyright notice and disclaimer of warranty; keep intact all the +notices that refer to this License and to the absence of any warranty; +and give any other recipients of the Program a copy of this License +along with the Program. + +You may charge a fee for the physical act of transferring a copy, and +you may at your option offer warranty protection in exchange for a fee. + + 2. You may modify your copy or copies of the Program or any portion +of it, thus forming a work based on the Program, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) You must cause the modified files to carry prominent notices + stating that you changed the files and the date of any change. + + b) You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any + part thereof, to be licensed as a whole at no charge to all third + parties under the terms of this License. + + c) If the modified program normally reads commands interactively + when run, you must cause it, when started running for such + interactive use in the most ordinary way, to print or display an + announcement including an appropriate copyright notice and a + notice that there is no warranty (or else, saying that you provide + a warranty) and that users may redistribute the program under + these conditions, and telling the user how to view a copy of this + License. (Exception: if the Program itself is interactive but + does not normally print such an announcement, your work based on + the Program is not required to print an announcement.) + + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Program, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Program, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Program. + +In addition, mere aggregation of another work not based on the Program +with the Program (or with a work based on the Program) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may copy and distribute the Program (or a work based on it, +under Section 2) in object code or executable form under the terms of +Sections 1 and 2 above provided that you also do one of the following: + + a) Accompany it with the complete corresponding machine-readable + source code, which must be distributed under the terms of Sections + 1 and 2 above on a medium customarily used for software interchange; or, + + b) Accompany it with a written offer, valid for at least three + years, to give any third party, for a charge no more than your + cost of physically performing source distribution, a complete + machine-readable copy of the corresponding source code, to be + distributed under the terms of Sections 1 and 2 above on a medium + customarily used for software interchange; or, + + c) Accompany it with the information you received as to the offer + to distribute corresponding source code. (This alternative is + allowed only for noncommercial distribution and only if you + received the program in object code or executable form with such + an offer, in accord with Subsection b above.) + +The source code for a work means the preferred form of the work for +making modifications to it. For an executable work, complete source +code means all the source code for all modules it contains, plus any +associated interface definition files, plus the scripts used to +control compilation and installation of the executable. However, as a +special exception, the source code distributed need not include +anything that is normally distributed (in either source or binary +form) with the major components (compiler, kernel, and so on) of the +operating system on which the executable runs, unless that component +itself accompanies the executable. + +If distribution of executable or object code is made by offering +access to copy from a designated place, then offering equivalent +access to copy the source code from the same place counts as +distribution of the source code, even though third parties are not +compelled to copy the source along with the object code. + + + 4. You may not copy, modify, sublicense, or distribute the Program +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense or distribute the Program is +void, and will automatically terminate your rights under this License. +However, parties who have received copies, or rights, from you under +this License will not have their licenses terminated so long as such +parties remain in full compliance. + + 5. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Program or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Program (or any work based on the +Program), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Program or works based on it. + + 6. Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the +original licensor to copy, distribute or modify the Program subject to +these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + + 7. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Program at all. For example, if a patent +license would not permit royalty-free redistribution of the Program by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Program. + +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply and the section as a whole is intended to apply in other +circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system, which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + + 8. If the distribution and/or use of the Program is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Program under this License +may add an explicit geographical distribution limitation excluding +those countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. + + 9. The Free Software Foundation may publish revised and/or new versions +of the General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. + + 10. If you wish to incorporate parts of the Program into other free +programs whose distribution conditions are different, write to the author +to ask for permission. For software which is copyrighted by the Free +Software Foundation, write to the Free Software Foundation; we sometimes +make exceptions for this. Our decision will be guided by the two goals +of preserving the free status of all derivatives of our free software and +of promoting the sharing and reuse of software generally. + + NO WARRANTY + + 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, +REPAIR OR CORRECTION. + + 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. + + END OF TERMS AND CONDITIONS + + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) 19yy + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + +Also add information on how to contact you by electronic and paper mail. + +If the program is interactive, make it output a short notice like this +when it starts in an interactive mode: + + Gnomovision version 69, Copyright (C) 19yy name of author + Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, the commands you use may +be called something other than `show w' and `show c'; they could even be +mouse-clicks or menu items--whatever suits your program. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the program + `Gnomovision' (which makes passes at compilers) written by James Hacker. + + , 1 April 1989 + Ty Coon, President of Vice + +This General Public License does not permit incorporating your program into +proprietary programs. If your program is a subroutine library, you may +consider it more useful to permit linking proprietary applications with the +library. If this is what you want to do, use the GNU Library General +Public License instead of this License. + diff --git a/makefile b/makefile new file mode 100644 index 0000000..761d12e --- /dev/null +++ b/makefile @@ -0,0 +1,104 @@ +# comport PD External Unix(Linux)/Windows +# +# IEM - Institute for Electronic Music and Acoustic, Graz +# +# Author: Winfried Ritsch +# Maintainer: Win +# +# Licence: GPL - Gnu Public Licence + + +current: pd_nt + echo make pd_linux, pd_nt, pd_irix5, or pd_irix6 + + +# ----------------------- NT ----------------------- +pd_nt: comport.dll bird.dll + +.SUFFIXES: .dll + +PDNTCFLAGS = /W3 /WX /DNT /DPD /nologo /DWIN2000 + +VC="C:\Programme\Microsoft Visual Studio\Vc98" +PDROOT="C:\Programme\pd" + +PDNTINCLUDE = /I. /I$(PDROOT)\tcl\include /I$(PDROOT)\src /I$(VC)\include + +PDNTLDIR = $(VC)\lib +PDNTLIB = $(PDNTLDIR)\libc.lib \ + $(PDNTLDIR)\oldnames.lib \ + $(PDNTLDIR)\kernel32.lib \ + $(PDROOT)\bin\pd.lib + +.c.dll: + cl $(PDNTCFLAGS) $(PDNTINCLUDE) /c $*.c + link /dll /export:$*_setup $*.obj $(PDNTLIB) + +# ----------------------- IRIX 5.x ----------------------- + +pd_irix5: comport.pd_irix5 bird.pd_irix5 + +.SUFFIXES: .pd_irix5 + +SGICFLAGS5 = -o32 -DPD -DSGI -O2 + + +SGIINCLUDE = -I../../src + +.c.pd_irix5: + cc $(SGICFLAGS5) $(SGIINCLUDE) -o $*.o -c $*.c + ld -elf -shared -rdata_shared -o $*.pd_irix5 $*.o + rm $*.o + +# ----------------------- IRIX 6.x ----------------------- + +pd_irix6: comport.pd_irix6 bird.pd_irix6 + +.SUFFIXES: .pd_irix6 + +SGICFLAGS6 = -DPD -DSGI -n32 \ + -OPT:roundoff=3 -OPT:IEEE_arithmetic=3 -OPT:cray_ivdep=true \ + -Ofast=ip32 + +SGICFLAGS5 = -DPD -O2 -DSGI + +SGIINCLUDE = -I/../../src + +.c.pd_irix6: + cc $(SGICFLAGS6) $(SGIINCLUDE) -o $*.o -c $*.c + ld -elf -shared -rdata_shared -o $*.pd_irix6 $*.o + rm $*.o + +# ----------------------- LINUX i386 ----------------------- + +pd_linux: comport.pd_linux bird.pd_linux + +.SUFFIXES: .pd_linux + +LINUXCFLAGS = -DPD -O2 -funroll-loops -fomit-frame-pointer \ + -Wall -W -Wshadow -Wstrict-prototypes -Werror \ + -Wno-unused -Wno-parentheses -Wno-switch + +LINUXINCLUDE = -I../../src + +.c.pd_linux: + cc $(LINUXCFLAGS) $(LINUXINCLUDE) -o $*.o -c $*.c + ld -export_dynamic -shared -o $*.pd_linux $*.o -lc -lm + strip --strip-unneeded $*.pd_linux + rm $*.o + + +# ---------- TEST ---------- + +TESTCFLAGS = $(LINUXCFLAGS) +LIBS = -lc -lm + + +test: testser.o bird.o + gcc -o test testser.o bird.o $(LIBS) + +tester.o: testser.c + gcc -c -o testser.o testser.c $(TESTCFLAGS) + +bird.o: bird.c + gcc -c -o bird.o bird.c $(TESTCFLAGS) diff --git a/pd_bird.bat b/pd_bird.bat new file mode 100644 index 0000000..3c95436 --- /dev/null +++ b/pd_bird.bat @@ -0,0 +1,5 @@ +echo Hallo starte nun pd + +C:\data\pd\bin\pd -verbose -nomidi testbird.pd + +echo bye... \ No newline at end of file diff --git a/pd_comport.bat b/pd_comport.bat new file mode 100644 index 0000000..497fbee --- /dev/null +++ b/pd_comport.bat @@ -0,0 +1,5 @@ +echo Hallo starte nun pd + +C:\Programme\pd\bin\pd -verbose -nomidi testcomport.pd + +echo bye... \ No newline at end of file diff --git a/testbird.pd b/testbird.pd new file mode 100644 index 0000000..03b18fb --- /dev/null +++ b/testbird.pd @@ -0,0 +1,96 @@ +#N canvas 231 237 720 492 10; +#X obj 134 195 bird; +#X floatatom 203 248 4 0 0; +#X msg 117 58 set POINT; +#X msg 19 191 bang; +#X obj 188 197 comport 1 9600; +#X msg 28 58 set STREAM; +#X floatatom 51 329 7 0 0; +#X floatatom 71 360 7 0 0; +#X floatatom 92 394 7 0 0; +#X floatatom 113 333 7 0 0; +#X floatatom 133 362 7 0 0; +#X floatatom 155 395 7 0 0; +#X text 406 121 comment; +#X text 63 37 operationg mode; +#X floatatom 177 331 7 0 0; +#X floatatom 197 362 7 0 0; +#X floatatom 218 396 7 0 0; +#X floatatom 239 335 7 0 0; +#X floatatom 259 364 7 0 0; +#X floatatom 281 397 7 0 0; +#X msg 29 90 set RUN; +#X msg 97 92 set SLEEP; +#X text 11 171 data point; +#X obj 349 227 s birdctl; +#X obj 193 130 r birdctl; +#X obj 51 147 s birdctl; +#X obj 51 292 unpack 1 2 3 4 5 6 7 8 9 10 11 12; +#X text 479 38 3 floats; +#X text 479 65 9 floats; +#X text 480 89 3 floats; +#X text 483 115 4 floats; +#X text 481 137 6 floats; +#X text 480 167 12 floats; +#X text 488 192 7 floats; +#X text 353 16 DATA MODES; +#X text 350 254 SETTINGS; +#X msg 418 259 set AngleAlign1 0 0 0 0 0 0; +#X msg 417 288 set AngleAlign2 0 0 0; +#X msg 381 42 set ANGLES; +#X msg 381 64 set MATRIX; +#X msg 381 87 set POSITION; +#X msg 381 110 set QUARTER; +#X msg 384 139 set POSANG; +#X msg 380 165 set POSMAT; +#X msg 382 190 set POSQUARTER; +#X msg 420 314 set Hemisphere 0 0; +#X msg 420 337 set RefFrame1 0 0 0 0 0 0; +#X msg 423 362 set RefFrame2 0 0 0; +#X msg 420 386 set RepRate1; +#X msg 420 407 set RepRate2; +#X msg 420 429 set RepRate8; +#X msg 420 451 set RepRate32; +#X obj 341 451 s birdctl; +#X msg 195 154 verbose 1; +#X msg 196 175 verbose 0; +#X connect 0 0 26 0; +#X connect 0 1 1 0; +#X connect 0 1 4 0; +#X connect 2 0 25 0; +#X connect 3 0 0 0; +#X connect 4 0 0 0; +#X connect 5 0 25 0; +#X connect 20 0 25 0; +#X connect 21 0 25 0; +#X connect 24 0 0 0; +#X connect 26 0 6 0; +#X connect 26 1 7 0; +#X connect 26 2 8 0; +#X connect 26 3 9 0; +#X connect 26 4 10 0; +#X connect 26 5 11 0; +#X connect 26 6 14 0; +#X connect 26 7 15 0; +#X connect 26 8 16 0; +#X connect 26 9 17 0; +#X connect 26 10 18 0; +#X connect 26 11 19 0; +#X connect 36 0 52 0; +#X connect 37 0 52 0; +#X connect 38 0 23 0; +#X connect 39 0 23 0; +#X connect 40 0 23 0; +#X connect 41 0 23 0; +#X connect 42 0 23 0; +#X connect 43 0 23 0; +#X connect 44 0 23 0; +#X connect 45 0 52 0; +#X connect 46 0 52 0; +#X connect 47 0 52 0; +#X connect 48 0 52 0; +#X connect 49 0 52 0; +#X connect 50 0 52 0; +#X connect 51 0 52 0; +#X connect 53 0 0 0; +#X connect 54 0 0 0; diff --git a/testbird.sh b/testbird.sh new file mode 100644 index 0000000..bfc65cf --- /dev/null +++ b/testbird.sh @@ -0,0 +1,2 @@ +#!/bin/sh +pd -alsa -alsadev hw:1,1 -inchannels 8 -outchannels 8 -frags 20 testbird.pd diff --git a/testcomport.pd b/testcomport.pd new file mode 100644 index 0000000..bd3db6d --- /dev/null +++ b/testcomport.pd @@ -0,0 +1,78 @@ +#N canvas 199 244 690 400 10; +#X obj 89 121 comport 1 9600; +#X msg 5 103 66; +#X obj 80 251 print; +#X floatatom 187 80 4 0 0; +#X msg 4 61 64; +#X text 4 81 point; +#X text 3 40 stream; +#X msg 5 153 86; +#X text 5 128 position; +#X msg 8 197 70; +#X msg 6 237 71; +#X text 7 180 run; +#X text 6 215 sleep; +#X floatatom 113 159 4 0 0; +#X obj 82 215 spigot; +#X msg 101 188 1; +#X msg 135 189 0; +#X msg 353 37 bits 8; +#X msg 352 61 stopbit 0; +#X msg 351 89 parity 0; +#X msg 352 118 xonxoff 1; +#X msg 352 144 rtscts 0; +#X text 431 92 parity 1=even \, -1=odd \, 0=off; +#X text 431 63 extra stopbit 1=on \, 0=off; +#X text 433 38 databits 5 \, 6 \, 7 \, 8; +#X text 432 9 use exact or higher baudrate; +#X obj 112 96 r comctl; +#X obj 335 169 s comctl; +#X text 433 117 use handshake xon/off 1=on 0=off; +#X text 431 143 cts/rts hardwarehandshake 1=on 0=off; +#X msg 345 210 pollintervall 1; +#X text 461 211 set pollintervall for read in ms; +#X text 461 225 (default is 1 tick 1ms); +#X msg 246 264 close; +#X msg 251 288 open 1; +#X msg 353 12 baud 10000; +#X text 312 261 Close Serial port; +#X text 315 292 Open seriel board Nr (0=COM1 \, 1=COM2 \, ...); +#X msg 238 342 devicename /dev/ttyS1; +#X text 232 363 Danger !!! you can open every file in your system and +maybe if suid is root damage the system.; +#X text 233 324 set devicename for actuell port \, then close and open +again; +#X obj 240 78 spigot; +#X msg 259 51 1; +#X msg 293 52 0; +#X obj 235 25 key; +#X text 2 22 eg. for flock of bird:; +#X text 235 312 never should be needed except for sys admins (only +unix); +#X msg 269 10 baud 300; +#X connect 0 0 13 0; +#X connect 0 0 14 0; +#X connect 1 0 0 0; +#X connect 3 0 0 0; +#X connect 4 0 0 0; +#X connect 7 0 0 0; +#X connect 9 0 0 0; +#X connect 10 0 0 0; +#X connect 14 0 2 0; +#X connect 15 0 14 1; +#X connect 16 0 14 1; +#X connect 17 0 27 0; +#X connect 18 0 27 0; +#X connect 19 0 27 0; +#X connect 20 0 27 0; +#X connect 21 0 27 0; +#X connect 26 0 0 0; +#X connect 30 0 27 0; +#X connect 33 0 27 0; +#X connect 34 0 27 0; +#X connect 35 0 27 0; +#X connect 41 0 3 0; +#X connect 42 0 41 1; +#X connect 43 0 41 1; +#X connect 44 0 41 0; +#X connect 47 0 27 0; diff --git a/testcomport.sh b/testcomport.sh new file mode 100644 index 0000000..c7ad1e9 --- /dev/null +++ b/testcomport.sh @@ -0,0 +1,2 @@ +#!/bin/sh +pd -alsa -alsadev hw:1,1 -inchannels 8 -outchannels 8 -frags 15 testcomport.pd diff --git a/vcmakefile.dsp b/vcmakefile.dsp new file mode 100644 index 0000000..c3af30f --- /dev/null +++ b/vcmakefile.dsp @@ -0,0 +1,85 @@ +# Microsoft Developer Studio Project File - Name="vcmakefile" - Package Owner=<4> +# Microsoft Developer Studio Generated Build File, Format Version 6.00 +# ** NICHT BEARBEITEN ** + +# TARGTYPE "Win32 (x86) External Target" 0x0106 + +CFG=vcmakefile - Win32 Debug +!MESSAGE Dies ist kein gltiges Makefile. Zum Erstellen dieses Projekts mit NMAKE +!MESSAGE verwenden Sie den Befehl "Makefile exportieren" und fhren Sie den Befehl +!MESSAGE +!MESSAGE NMAKE /f "vcmakefile.mak". +!MESSAGE +!MESSAGE Sie knnen beim Ausfhren von NMAKE eine Konfiguration angeben +!MESSAGE durch Definieren des Makros CFG in der Befehlszeile. Zum Beispiel: +!MESSAGE +!MESSAGE NMAKE /f "vcmakefile.mak" CFG="vcmakefile - Win32 Debug" +!MESSAGE +!MESSAGE Fr die Konfiguration stehen zur Auswahl: +!MESSAGE +!MESSAGE "vcmakefile - Win32 Release" (basierend auf "Win32 (x86) External Target") +!MESSAGE "vcmakefile - Win32 Debug" (basierend auf "Win32 (x86) External Target") +!MESSAGE + +# Begin Project +# PROP AllowPerConfigDependencies 0 +# PROP Scc_ProjName "" +# PROP Scc_LocalPath "" + +!IF "$(CFG)" == "vcmakefile - Win32 Release" + +# PROP BASE Use_Debug_Libraries 0 +# PROP BASE Output_Dir "Release" +# PROP BASE Intermediate_Dir "Release" +# PROP BASE Cmd_Line "NMAKE /f makefile" +# PROP BASE Rebuild_Opt "/a" +# PROP BASE Target_File "makefile.exe" +# PROP BASE Bsc_Name "makefile.bsc" +# PROP BASE Target_Dir "" +# PROP Use_Debug_Libraries 0 +# PROP Output_Dir "Release" +# PROP Intermediate_Dir "Release" +# PROP Cmd_Line "NMAKE /f makefile" +# PROP Rebuild_Opt "/a" +# PROP Target_File "vcmakefile.exe" +# PROP Bsc_Name "vcmakefile.bsc" +# PROP Target_Dir "" + +!ELSEIF "$(CFG)" == "vcmakefile - Win32 Debug" + +# PROP BASE Use_Debug_Libraries 1 +# PROP BASE Output_Dir "Debug" +# PROP BASE Intermediate_Dir "Debug" +# PROP BASE Cmd_Line "NMAKE /f makefile" +# PROP BASE Rebuild_Opt "/a" +# PROP BASE Target_File "makefile.exe" +# PROP BASE Bsc_Name "makefile.bsc" +# PROP BASE Target_Dir "" +# PROP Use_Debug_Libraries 1 +# PROP Output_Dir "Debug" +# PROP Intermediate_Dir "Debug" +# PROP Cmd_Line "NMAKE /f makefile" +# PROP Rebuild_Opt "/a" +# PROP Target_File "vcmakefile.exe" +# PROP Bsc_Name "vcmakefile.bsc" +# PROP Target_Dir "" + +!ENDIF + +# Begin Target + +# Name "vcmakefile - Win32 Release" +# Name "vcmakefile - Win32 Debug" + +!IF "$(CFG)" == "vcmakefile - Win32 Release" + +!ELSEIF "$(CFG)" == "vcmakefile - Win32 Debug" + +!ENDIF + +# Begin Source File + +SOURCE=.\makefile +# End Source File +# End Target +# End Project diff --git a/vcmakefile.dsw b/vcmakefile.dsw new file mode 100644 index 0000000..0a9cda0 --- /dev/null +++ b/vcmakefile.dsw @@ -0,0 +1,29 @@ +Microsoft Developer Studio Workspace File, Format Version 6.00 +# WARNUNG: DIESE ARBEITSBEREICHSDATEI DARF NICHT BEARBEITET ODER GELSCHT WERDEN! + +############################################################################### + +Project: "vcmakefile"=.\vcmakefile.dsp - Package Owner=<4> + +Package=<5> +{{{ +}}} + +Package=<4> +{{{ +}}} + +############################################################################### + +Global: + +Package=<5> +{{{ +}}} + +Package=<3> +{{{ +}}} + +############################################################################### + diff --git a/vcmakefile.ncb b/vcmakefile.ncb new file mode 100644 index 0000000..bde6bd9 Binary files /dev/null and b/vcmakefile.ncb differ diff --git a/vcmakefile.opt b/vcmakefile.opt new file mode 100644 index 0000000..5771755 Binary files /dev/null and b/vcmakefile.opt differ diff --git a/vcmakefile.plg b/vcmakefile.plg new file mode 100644 index 0000000..82ea7aa --- /dev/null +++ b/vcmakefile.plg @@ -0,0 +1,29 @@ + + +
+

Erstellungsprotokoll

+

+--------------------Konfiguration: vcmakefile - Win32 Debug-------------------- +

+ + +Microsoft (R) Program Maintenance-Dienstprogramm: Version 6.00.8168.0 +Copyright (C) Microsoft Corp 1988-1998. Alle Rechte vorbehalten. + + cl /W3 /WX /DNT /DPD /nologo /DWIN2000 /I. /I"C:\Programme\pd"\tcl\include /I"C:\Programme\pd"\src /I"C:\Programme\Microsoft Visual Studio\Vc98"\include /c comport.c +comport.c + link /dll /export:comport_setup comport.obj "C:\Programme\Microsoft Visual Studio\Vc98"\lib\libc.lib "C:\Programme\Microsoft Visual Studio\Vc98"\lib\oldnames.lib "C:\Programme\Microsoft Visual Studio\Vc98"\lib\kernel32.lib "C:\Programme\pd"\bin\pd.lib +Microsoft (R) Incremental Linker Version 6.00.8168 +Copyright (C) Microsoft Corp 1992-1998. All rights reserved. + + Bibliothek comport.lib und Objekt comport.exp wird erstellt + echo make pd_linux, pd_nt, pd_irix5, or pd_irix6 +make pd_linux, pd_nt, pd_irix5, or pd_irix6 + + + +

Ergebnisse

+vcmakefile.exe - 0 Fehler, 0 Warnung(en) +
+ + -- cgit v1.2.1