Audio/Variodyn

From eqqon

(Difference between revisions)
Jump to: navigation, search
(PA Protocol)
Line 95: Line 95:
   pa_delete_message(m);
   pa_delete_message(m);
   }
   }
 +
 +
;simple receiver example -
 +
: coming soon
<div style="clear:both;"></div>
<div style="clear:both;"></div>
==PA Protocol notes and examples==
==PA Protocol notes and examples==
===Example - activate and deactivate a audio route===
===Example - activate and deactivate a audio route===
-
<div style="float:right; border-left:dotted 1px; margin-left:2em; padding:1em;">
 
{| style="border-collapse:collapse; padding:0px; border-spacing:0px;"
{| style="border-collapse:collapse; padding:0px; border-spacing:0px;"
|+'''sequence diagram'''
|+'''sequence diagram'''
Line 124: Line 126:
|| ||[[Image:arrow_rl.png]] RESPONSE destination busy info ||
|| ||[[Image:arrow_rl.png]] RESPONSE destination busy info ||
|}
|}
-
</div>
 
<div style="clear:both;"></div>
<div style="clear:both;"></div>

Revision as of 23:44, 30 October 2007

Variodyn is the name of a paging system. the name itself an artificial word constructed from the word variable and dynamic - representing the properties of a new generation of paging systems - was introduced about 1975 at germany for the analog paging system developed by siemens.

Contents

history of the variodyn system

Variodyn
the first system was an fully analog system, consisting of several components pre amplifiers, mixers and power amplifiers. the paging behavior of an installation was made by wiring contacts and relays. line relays were installed to get better control where the signal is distributed and get a better cost effort due power amplifiers are expensive. with the line relays it was possible to drive more lines, not using all the lines at the same time. we have no more information about the components.
status: not in production
Variodyn 2000, developed 1985 by siemens
this was also an analog system. the new innovation was to design all the components mechanical and electrical compatible, so that the components could be combined in thousands of variations by wiring at the rack. the components also had the necessary paging switches on board and used electronic switches instead of relays to switch audio. there was also a small audio matrix (4x4) supported by each component, and the audio switches were easy controllable by external contacts. the main behavior of the system had to be implemented by relays which were supported by some components implementing often used behavior.
status: not in production
Variodyn 2030, developed 1987 by siemens
this is an extension for the variodyn 2000 devices. all the devices were designed to plug on a interface for digital control. with this interface the audio switches of the devices were controllable by a microprocessor. new components were developed to get user interaction from keys and switches and show the system's operating states via lights to the user. the software was then controlling the behavior of the audio switches and allowed then more complex behavior to implement than it was possible using only relays.
status: not in production
Variodyn 3000, developed 1991 by siemens
this is an analog system digitally controlled. the innovation was to replace the expensive parallel control bus used by the Variodyn 2000 system by a serial bus. this reduced also rack wiring complexity and allowed to build up larger systems. all the components use relays to switch audio and allows to control digitally the audio volume at each device. a more powerful processor controlling the behavior was also developed. then the software was enabled with a lot of features for paging systems. a configuration phase was introduced defining the behavior and devices installed at the system.
status: not in production
Variodyn D1, developed 2004 by av digital
this is a fully digital distributed system. only 10 different components allow to build small installations and grow up to very large installations. the benefits are detailed described at several websites. the system has overridden the features older one. over hundred installations are running worldwide.
status: in production
links: av digital, manufacturer | german | belgium | netherlands | design by gp


Variodyn is a resistered trademark by av digital gmbh.

thanks to harry for helping

PA Protocol

the Variodyn D1 system can be controlled via commands transmitted via ethernet. the protocol used was designed around 1993 to handle new communication requirements. as initially designed for serial communication the protocol has a robust resynchronisation ability, and a weak checksum algorithm to implement easy at small microcontrollers. with the Variodyn D1 system, the protocol is now used inside a TCP channel to communicate with a controlling computer via ethernet. the TCP channel provides a session layer and also provides error correction and retransmission, so the weak checksum algorithm of the protocol itself is no longer a drawback.


Version 7 (german only)

This is the latest version used by Variodyn 3000 and early versions of the Variodyn D1 Software.


Version 8 (german only)

Several extensions used by the Variodyn D1 System since Version 1.8 are added.

supported by DOM V1.8, V1.9, V2.0, V2.1

Version 9 (english only)
First there are some helper macros to keep the protocol layer simple for programming. All messages are created at the heap, with maximal message size. The read and write functions automatically convert to/from network byte order.
/* helper macros to write pa protocol messages */
#define PAMSG_MAXSIZE 10000
typedef struct { unsigned char b[PAMSG_MAXSIZE], cs; int i; } pamsg_t;

#define pa_new_message(m, mid, d1,d2,d3,d4, s1,s2,s3,s4) \
  pamsg_t *(m) = (pamsg_t*)malloc(sizeof(pamsg_t));\
  (m)->i=0; (m)->cs=0;\
  (m)->b[(m)->i++]=0xfe;\
  pa_wr8(m,d1),pa_wr8(m,d2),pa_wr8(m,d3),pa_wr8(m,d4);\
  pa_wr8(m,s1),pa_wr8(m,s2),pa_wr8(m,s3),pa_wr8(m,s4);\
  pa_wr8(m,mid);\
  (m)->i=12;

#define pa_wr8(m,d) ((m)->b[(m)->i++]=(unsigned char)(d)>=0xf9?(m)->b[(m)->i++]=0xff,~(unsigned char)(d):(unsigned char)(d),(m)->cs+=(unsigned char)(d))
#define pa_wr16(m,d) (pa_wr8(m,(d)>>8),pa_wr8(m,(d)))
#define pa_wr32(m,d) (pa_wr8(m,(d)>>24),pa_wr8(m,(d)>>16),pa_wr8(m,(d)>>8),pa_wr8(m,(d)))

#define pa_finish_message(m) do{\
                        int j=(m)->i;\
                        if((j-12)%256>0xf9) memmove(&((m)->b[13]),&((m)->b[12]),j-12);\
                        (m)->i=10; pa_wr16(m,j-12);\
                        (m)->i=j;\
                        pa_wr8(m,0x100-(m)->cs);\
                        (m)->b[(m)->i++]=0xfd;\
                        }while(0)

#define pa_message_length(m) ((m)->i)

#define pa_delete_message(m) do { if(m) free(m); (m)=0; } while(0)


simple receiver example -
coming soon
simple transmitter example - communication check
This example code creates a message from DOM 33 to DOM32 with message id 0x0b. There is one data byte (0x00) at the data body.
void main (void)
 {
 int i;
 pa_new_message(m, 0x0b, 0,33,1,0, 0,0x20,1,0);
 pa_wr8(m,0);
 pa_finish_message(m);
 
 /* send the message(m,pa_message_length(m)); */
 
 printf ("%10s [%d] bytes:","message",pa_message_length(m));
 for (i=0;i<pa_message_length(m);i++) printf (" %02x",m->b[i]); }
 printf("\n");
 pa_delete_message(m);
 }
simple receiver example -
coming soon

PA Protocol notes and examples

Example - activate and deactivate a audio route

sequence diagram
client server
Arrow lr.png COMMAND activate route
Arrow rl.png RESPONSE activate route
Arrow rl.png RESPONSE destination busy info
if everything is well configured, the audio route is avtivated now
Arrow lr.png COMMAND deactivate route
Arrow rl.png RESPONSE deactivate route
Arrow rl.png RESPONSE destination busy info

Example - receiving system messages

Example - receiving audio route busy information