rt/msr_module.c
author Florian Pose <fp@igh-essen.com>
Fri, 06 Jan 2006 16:19:35 +0000
changeset 49 3f8e769ca747
parent 48 7e75772ea28c
child 51 b3beaa00640f
permissions -rw-r--r--
Dirty-TX-Meldung aus 8139too-ecat.c entfernt.
42
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
     1
/******************************************************************************
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
     2
 *
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
     3
 *  msr_module.c
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
     4
 *
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
     5
 *  Kernelmodul für 2.6 Kernel zur Meßdatenerfassung, Steuerung und Regelung.
47
ad5f969f263b Prozessdatentimeout, Buszeit und weniger Klemmen.
Florian Pose <fp@igh-essen.com>
parents: 45
diff changeset
     6
 *
ad5f969f263b Prozessdatentimeout, Buszeit und weniger Klemmen.
Florian Pose <fp@igh-essen.com>
parents: 45
diff changeset
     7
 *  Autor: Wilhelm Hagemeister, Florian Pose
42
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
     8
 *
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
     9
 *  (C) Copyright IgH 2002
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    10
 *  Ingenieurgemeinschaft IgH
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    11
 *  Heinz-Bäcker Str. 34
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    12
 *  D-45356 Essen
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    13
 *  Tel.: +49 201/61 99 31
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    14
 *  Fax.: +49 201/61 98 36
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    15
 *  E-mail: hm@igh-essen.com
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    16
 *
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    17
 *  $Id$
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    18
 *
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    19
 *****************************************************************************/
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    20
45
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
    21
// Linux
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    22
#include <linux/module.h>
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    23
#include <linux/ipipe.h>
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    24
45
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
    25
// RT_lib
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
    26
#include <msr_main.h>
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
    27
#include <msr_utils.h>
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
    28
#include <msr_messages.h>
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
    29
#include <msr_float.h>
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    30
#include <msr_reg.h>
45
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
    31
#include "msr_param.h"
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
    32
#include "msr_jitter.h"
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
    33
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
    34
// EtherCAT
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    35
#include "../drivers/ec_master.h"
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    36
#include "../drivers/ec_device.h"
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    37
#include "../drivers/ec_types.h"
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    38
#include "../drivers/ec_module.h"
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    39
45
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
    40
// Defines/Makros
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
    41
#define TSC2US(T1, T2) ((T2 - T1) * 1000UL / cpu_khz)
47
ad5f969f263b Prozessdatentimeout, Buszeit und weniger Klemmen.
Florian Pose <fp@igh-essen.com>
parents: 45
diff changeset
    42
#define HZREDUCTION (MSR_ABTASTFREQUENZ / HZ)
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    43
45
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
    44
/*****************************************************************************/
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
    45
/* Globale Variablen */
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
    46
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
    47
// RT_lib
42
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    48
extern struct timeval process_time;
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    49
struct timeval msr_time_increment; // Increment per Interrupt
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    50
45
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
    51
// Adeos
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    52
static struct ipipe_domain this_domain;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    53
static struct ipipe_sysinfo sys_info;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    54
45
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
    55
// EtherCAT
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
    56
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    57
static EtherCAT_master_t *ecat_master = NULL;
47
ad5f969f263b Prozessdatentimeout, Buszeit und weniger Klemmen.
Florian Pose <fp@igh-essen.com>
parents: 45
diff changeset
    58
static unsigned int ecat_bus_time = 0;
ad5f969f263b Prozessdatentimeout, Buszeit und weniger Klemmen.
Florian Pose <fp@igh-essen.com>
parents: 45
diff changeset
    59
static unsigned int ecat_timeouts = 0;
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    60
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    61
static EtherCAT_slave_t ecat_slaves[] =
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    62
{
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    63
    // Block 1
42
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    64
    ECAT_INIT_SLAVE(Beckhoff_EK1100, 0),
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    65
    ECAT_INIT_SLAVE(Beckhoff_EL4102, 0),
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    66
    ECAT_INIT_SLAVE(Beckhoff_EL1014, 0),
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    67
    ECAT_INIT_SLAVE(Beckhoff_EL3162, 0),
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    68
    ECAT_INIT_SLAVE(Beckhoff_EL2004, 0),
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    69
    ECAT_INIT_SLAVE(Beckhoff_EL3102, 0),
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    70
    ECAT_INIT_SLAVE(Beckhoff_EL2004, 0),
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    71
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    72
    // Block 2
42
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    73
    ECAT_INIT_SLAVE(Beckhoff_EK1100, 1),
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    74
    ECAT_INIT_SLAVE(Beckhoff_EL1014, 1),
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    75
    ECAT_INIT_SLAVE(Beckhoff_EL1014, 1),
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    76
    ECAT_INIT_SLAVE(Beckhoff_EL1014, 1),
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    77
    ECAT_INIT_SLAVE(Beckhoff_EL1014, 1),
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    78
    ECAT_INIT_SLAVE(Beckhoff_EL1014, 1),
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    79
    ECAT_INIT_SLAVE(Beckhoff_EL2004, 1),
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    80
    ECAT_INIT_SLAVE(Beckhoff_EL2004, 1),
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    81
    ECAT_INIT_SLAVE(Beckhoff_EL2004, 1),
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    82
    ECAT_INIT_SLAVE(Beckhoff_EL2004, 1),
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    83
    ECAT_INIT_SLAVE(Beckhoff_EL1014, 1),
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    84
    ECAT_INIT_SLAVE(Beckhoff_EL1014, 1),
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
    85
    ECAT_INIT_SLAVE(Beckhoff_EL1014, 1)
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    86
};
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    87
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    88
#define ECAT_SLAVES_COUNT (sizeof(ecat_slaves) / sizeof(EtherCAT_slave_t))
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    89
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    90
#define USE_MSR_LIB
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    91
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    92
#ifdef USE_MSR_LIB
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    93
double value;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    94
int dig1;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    95
#endif
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    96
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    97
/******************************************************************************
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    98
 *
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
    99
 * Function: next2004
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   100
 *
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   101
 *****************************************************************************/
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   102
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   103
static int next2004(int *wrap)
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   104
{
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   105
    static int i = 0;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   106
    unsigned int j = 0;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   107
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   108
    *wrap = 0;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   109
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   110
    for (j = 0; j < ECAT_SLAVES_COUNT; j++)
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   111
    {
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   112
        i++;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   113
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   114
        i %= ECAT_SLAVES_COUNT;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   115
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   116
        if (i == 0) *wrap = 1;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   117
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   118
        if (ecat_slaves[i].desc == Beckhoff_EL2004)
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   119
        {
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   120
            return i;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   121
        }
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   122
    }
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   123
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   124
    return -1;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   125
}
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   126
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   127
/******************************************************************************
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   128
 *
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   129
 * Function: msr_controller_run()
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   130
 *
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   131
 *****************************************************************************/
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   132
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   133
static void msr_controller_run(void)
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   134
{
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   135
    static int ms = 0;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   136
    static int cnt = 0;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   137
    static int firstrun = 1;
48
7e75772ea28c Sinnvolle Meldung verlorener Frames, Zustand antwortender Slaves.
Florian Pose <fp@igh-essen.com>
parents: 47
diff changeset
   138
    static unsigned int debug_counter = 0;
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   139
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   140
    static int klemme = 0;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   141
    static int kanal = 0;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   142
    static int up_down = 0;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   143
    int wrap = 0;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   144
48
7e75772ea28c Sinnvolle Meldung verlorener Frames, Zustand antwortender Slaves.
Florian Pose <fp@igh-essen.com>
parents: 47
diff changeset
   145
    unsigned long t_bus_start, t_bus_end;
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   146
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   147
    // Prozessdaten lesen
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   148
    msr_jitter_run(MSR_ABTASTFREQUENZ);
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   149
48
7e75772ea28c Sinnvolle Meldung verlorener Frames, Zustand antwortender Slaves.
Florian Pose <fp@igh-essen.com>
parents: 47
diff changeset
   150
    if (firstrun) {
7e75772ea28c Sinnvolle Meldung verlorener Frames, Zustand antwortender Slaves.
Florian Pose <fp@igh-essen.com>
parents: 47
diff changeset
   151
        klemme = next2004(&wrap);
7e75772ea28c Sinnvolle Meldung verlorener Frames, Zustand antwortender Slaves.
Florian Pose <fp@igh-essen.com>
parents: 47
diff changeset
   152
        firstrun = 0;
7e75772ea28c Sinnvolle Meldung verlorener Frames, Zustand antwortender Slaves.
Florian Pose <fp@igh-essen.com>
parents: 47
diff changeset
   153
    }
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   154
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   155
    ms++;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   156
    ms %= 1000;
40
d07ebafe62dd 20kHz, Wilhelm
Florian Pose <fp@igh-essen.com>
parents: 38
diff changeset
   157
    if (cnt++ > 200)
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   158
    {
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   159
        cnt = 0;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   160
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   161
        if (++kanal > 3)
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   162
        {
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   163
            kanal = 0;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   164
            klemme = next2004(&wrap);
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   165
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   166
            if (wrap == 1)
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   167
            {
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   168
                if (up_down == 1) up_down = 0;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   169
                else up_down = 1;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   170
            }
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   171
        }
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   172
    }
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   173
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   174
    if (klemme >= 0) {
42
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   175
        EtherCAT_write_value(&ecat_slaves[klemme], kanal, up_down);
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   176
    }
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   177
48
7e75772ea28c Sinnvolle Meldung verlorener Frames, Zustand antwortender Slaves.
Florian Pose <fp@igh-essen.com>
parents: 47
diff changeset
   178
    if (debug_counter == 0) {
7e75772ea28c Sinnvolle Meldung verlorener Frames, Zustand antwortender Slaves.
Florian Pose <fp@igh-essen.com>
parents: 47
diff changeset
   179
        ecat_master->debug_level = 0;
7e75772ea28c Sinnvolle Meldung verlorener Frames, Zustand antwortender Slaves.
Florian Pose <fp@igh-essen.com>
parents: 47
diff changeset
   180
    }
7e75772ea28c Sinnvolle Meldung verlorener Frames, Zustand antwortender Slaves.
Florian Pose <fp@igh-essen.com>
parents: 47
diff changeset
   181
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   182
    // Prozessdaten schreiben
47
ad5f969f263b Prozessdatentimeout, Buszeit und weniger Klemmen.
Florian Pose <fp@igh-essen.com>
parents: 45
diff changeset
   183
48
7e75772ea28c Sinnvolle Meldung verlorener Frames, Zustand antwortender Slaves.
Florian Pose <fp@igh-essen.com>
parents: 47
diff changeset
   184
    rdtscl(t_bus_start);
42
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   185
47
ad5f969f263b Prozessdatentimeout, Buszeit und weniger Klemmen.
Florian Pose <fp@igh-essen.com>
parents: 45
diff changeset
   186
    if (EtherCAT_process_data_cycle(ecat_master, 0, 40) < 0)
ad5f969f263b Prozessdatentimeout, Buszeit und weniger Klemmen.
Florian Pose <fp@igh-essen.com>
parents: 45
diff changeset
   187
        ecat_timeouts++;
ad5f969f263b Prozessdatentimeout, Buszeit und weniger Klemmen.
Florian Pose <fp@igh-essen.com>
parents: 45
diff changeset
   188
ad5f969f263b Prozessdatentimeout, Buszeit und weniger Klemmen.
Florian Pose <fp@igh-essen.com>
parents: 45
diff changeset
   189
    if (EtherCAT_process_data_cycle(ecat_master, 1, 40) < 0)
ad5f969f263b Prozessdatentimeout, Buszeit und weniger Klemmen.
Florian Pose <fp@igh-essen.com>
parents: 45
diff changeset
   190
        ecat_timeouts++;
48
7e75772ea28c Sinnvolle Meldung verlorener Frames, Zustand antwortender Slaves.
Florian Pose <fp@igh-essen.com>
parents: 47
diff changeset
   191
7e75772ea28c Sinnvolle Meldung verlorener Frames, Zustand antwortender Slaves.
Florian Pose <fp@igh-essen.com>
parents: 47
diff changeset
   192
    rdtscl(t_bus_end);
7e75772ea28c Sinnvolle Meldung verlorener Frames, Zustand antwortender Slaves.
Florian Pose <fp@igh-essen.com>
parents: 47
diff changeset
   193
    ecat_bus_time = TSC2US(t_bus_start, t_bus_end);
7e75772ea28c Sinnvolle Meldung verlorener Frames, Zustand antwortender Slaves.
Florian Pose <fp@igh-essen.com>
parents: 47
diff changeset
   194
7e75772ea28c Sinnvolle Meldung verlorener Frames, Zustand antwortender Slaves.
Florian Pose <fp@igh-essen.com>
parents: 47
diff changeset
   195
    if (debug_counter == 0) {
7e75772ea28c Sinnvolle Meldung verlorener Frames, Zustand antwortender Slaves.
Florian Pose <fp@igh-essen.com>
parents: 47
diff changeset
   196
        ecat_master->debug_level = 0;
7e75772ea28c Sinnvolle Meldung verlorener Frames, Zustand antwortender Slaves.
Florian Pose <fp@igh-essen.com>
parents: 47
diff changeset
   197
    }
45
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
   198
42
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   199
    // Daten lesen und skalieren
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   200
#ifdef USE_MSR_LIB
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   201
    value = EtherCAT_read_value(&ecat_slaves[5], 0) / 3276.0;
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   202
    dig1 = EtherCAT_read_value(&ecat_slaves[2], 0);
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   203
#endif
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   204
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   205
    debug_counter++;
48
7e75772ea28c Sinnvolle Meldung verlorener Frames, Zustand antwortender Slaves.
Florian Pose <fp@igh-essen.com>
parents: 47
diff changeset
   206
    if (debug_counter >= MSR_ABTASTFREQUENZ * 5) debug_counter = 0;
42
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   207
}
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   208
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   209
/******************************************************************************
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   210
 *
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   211
 *  Function: msr_run(_interrupt)
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   212
 *
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   213
 *  Beschreibung: Routine wird zyklisch im Timerinterrupt ausgeführt
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   214
 *                (hier muß alles rein, was Echtzeit ist ...)
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   215
 *
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   216
 *  Parameter: Zeiger auf msr_data
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   217
 *
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   218
 *  Rückgabe:
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   219
 *
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   220
 *  Status: exp
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   221
 *
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   222
 *****************************************************************************/
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   223
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   224
void msr_run(unsigned irq)
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   225
{
45
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
   226
    static int counter = 0;
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
   227
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
   228
#ifdef USE_MSR_LIB
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
   229
    timeval_add(&process_time, &process_time, &msr_time_increment);
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
   230
    MSR_ADEOS_INTERRUPT_CODE(msr_controller_run(); msr_write_kanal_list(););
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   231
#else
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   232
    msr_controller_run();
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   233
#endif
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   234
40
d07ebafe62dd 20kHz, Wilhelm
Florian Pose <fp@igh-essen.com>
parents: 38
diff changeset
   235
    ipipe_control_irq(irq,0,IPIPE_ENABLE_MASK);  //Interrupt bestŽätigen
45
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
   236
    if (counter++ > HZREDUCTION) {
40
d07ebafe62dd 20kHz, Wilhelm
Florian Pose <fp@igh-essen.com>
parents: 38
diff changeset
   237
	ipipe_propagate_irq(irq);  //und weiterreichen
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   238
	counter = 0;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   239
    }
42
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   240
}
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   241
45
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
   242
/*****************************************************************************/
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
   243
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
   244
void domain_entry(void)
42
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   245
{
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   246
    printk("Domain %s started.\n", ipipe_current_domain->name);
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   247
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   248
    ipipe_get_sysinfo(&sys_info);
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   249
    ipipe_virtualize_irq(ipipe_current_domain,sys_info.archdep.tmirq,
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   250
			 &msr_run, NULL, IPIPE_HANDLE_MASK);
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   251
42
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   252
    ipipe_tune_timer(1000000000UL/MSR_ABTASTFREQUENZ,0);
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   253
}
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   254
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   255
/******************************************************************************
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   256
 *
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   257
 *  Function: msr_register_channels
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   258
 *
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   259
 *  Beschreibung: KanŽäle registrieren
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   260
 *
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   261
 *  Parameter:
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   262
 *
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   263
 *  RŽückgabe:
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   264
 *
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   265
 *  Status: exp
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   266
 *
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   267
 *****************************************************************************/
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   268
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   269
int msr_globals_register(void)
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   270
{
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   271
#ifdef USE_MSR_LIB
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   272
    msr_reg_kanal("/value", "V", &value, TDBL);
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   273
    msr_reg_kanal("/dig1", "", &dig1, TINT);
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   274
#endif
45
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
   275
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
   276
    msr_reg_kanal("/Taskinfo/EtherCAT/BusTime", "us", &ecat_bus_time, TUINT);
47
ad5f969f263b Prozessdatentimeout, Buszeit und weniger Klemmen.
Florian Pose <fp@igh-essen.com>
parents: 45
diff changeset
   277
    msr_reg_kanal("/Taskinfo/EtherCAT/Timeouts", "", &ecat_timeouts, TUINT);
45
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
   278
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
   279
    return 0;
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   280
}
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   281
42
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   282
/******************************************************************************
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   283
 * the init/clean material
42
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   284
 *****************************************************************************/
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   285
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   286
int __init init_module()
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   287
{
42
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   288
    unsigned int i;
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   289
    struct ipipe_domain_attr attr; //ipipe
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   290
36
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   291
    // Als allererstes die RT-lib initialisieren
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   292
#ifdef USE_MSR_LIB
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   293
    if (msr_rtlib_init(1,MSR_ABTASTFREQUENZ,10,&msr_globals_register) < 0) {
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   294
        msr_print_warn("msr_modul: can't initialize rtlib!");
36
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   295
        goto out_return;
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   296
    }
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   297
#endif
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   298
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   299
    msr_jitter_init();
36
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   300
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   301
    printk(KERN_INFO "=== Starting EtherCAT environment... ===\n");
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   302
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   303
    if ((ecat_master = EtherCAT_request(0)) == NULL) {
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   304
        printk(KERN_ERR "EtherCAT master 0 not available!\n");
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   305
        goto out_msr_cleanup;
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   306
    }
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   307
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   308
    printk("Checking EtherCAT slaves.\n");
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   309
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   310
    if (EtherCAT_check_slaves(ecat_master, ecat_slaves, ECAT_SLAVES_COUNT) != 0) {
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   311
        printk(KERN_ERR "EtherCAT: Could not init slaves!\n");
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   312
        goto out_release_master;
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   313
    }
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   314
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   315
    printk("Activating all EtherCAT slaves.\n");
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   316
42
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   317
    for (i = 0; i < ECAT_SLAVES_COUNT; i++) {
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   318
        if (EtherCAT_activate_slave(ecat_master, ecat_slaves + i) < 0) {
43
35120a61d55e Sch?nheitskorrekturen.
Florian Pose <fp@igh-essen.com>
parents: 42
diff changeset
   319
            printk(KERN_ERR "EtherCAT: Could not activate slave %i!\n", i);
42
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   320
            goto out_release_master;
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   321
        }
36
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   322
    }
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   323
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   324
    do_gettimeofday(&process_time);
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   325
    msr_time_increment.tv_sec=0;
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   326
    msr_time_increment.tv_usec=(unsigned int)(1000000/MSR_ABTASTFREQUENZ);
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   327
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   328
    ipipe_init_attr (&attr);
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   329
    attr.name     = "IPIPE-MSR-MODULE";
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   330
    attr.priority = IPIPE_ROOT_PRIO + 1;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   331
    attr.entry    = &domain_entry;
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   332
    ipipe_register_domain(&this_domain,&attr);
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   333
36
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   334
    return 0;
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   335
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   336
 out_release_master:
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   337
    EtherCAT_release(ecat_master);
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   338
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   339
 out_msr_cleanup:
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   340
    msr_rtlib_cleanup();
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   341
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   342
 out_return:
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   343
    return -1;
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   344
}
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   345
42
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   346
/*****************************************************************************/
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   347
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   348
void __exit cleanup_module()
42
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   349
{
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   350
    unsigned int i;
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   351
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   352
    msr_print_info("msk_modul: unloading...");
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   353
45
f525f7db2d90 Verbesserte Makefiles (MODPOST-Warnungen entfernt).
Florian Pose <fp@igh-essen.com>
parents: 43
diff changeset
   354
    ipipe_tune_timer(1000000000UL / HZ, 0); //alten Timertakt wieder herstellen
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   355
    ipipe_unregister_domain(&this_domain);
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   356
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   357
    if (ecat_master)
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   358
    {
43
35120a61d55e Sch?nheitskorrekturen.
Florian Pose <fp@igh-essen.com>
parents: 42
diff changeset
   359
        printk(KERN_INFO "=== Stopping EtherCAT environment... ===\n");
35120a61d55e Sch?nheitskorrekturen.
Florian Pose <fp@igh-essen.com>
parents: 42
diff changeset
   360
36
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   361
        printk(KERN_INFO "Deactivating slaves.\n");
42
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   362
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   363
        for (i = 0; i < ECAT_SLAVES_COUNT; i++) {
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   364
            if (EtherCAT_deactivate_slave(ecat_master, ecat_slaves + i) < 0) {
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   365
                printk(KERN_WARNING "Warning - Could not deactivate slave!\n");
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   366
            }
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   367
        }
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   368
36
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   369
        EtherCAT_release(ecat_master);
43
35120a61d55e Sch?nheitskorrekturen.
Florian Pose <fp@igh-essen.com>
parents: 42
diff changeset
   370
35120a61d55e Sch?nheitskorrekturen.
Florian Pose <fp@igh-essen.com>
parents: 42
diff changeset
   371
        printk(KERN_INFO "=== EtherCAT environment stopped. ===\n");
35120a61d55e Sch?nheitskorrekturen.
Florian Pose <fp@igh-essen.com>
parents: 42
diff changeset
   372
    }
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   373
36
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   374
#ifdef USE_MSR_LIB
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   375
    msr_rtlib_cleanup();
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   376
#endif
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   377
}
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   378
42
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   379
/*****************************************************************************/
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   380
28
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   381
MODULE_LICENSE("GPL");
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   382
MODULE_AUTHOR ("Wilhelm Hagemeister <hm@igh-essen.com>");
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   383
MODULE_DESCRIPTION ("EtherCAT test environment");
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   384
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   385
module_init(init_module);
801dc7eabf51 IPIPE,floatpoint,rtlib
Wilhelm Hagemeister <hm@igh-essen.com>
parents:
diff changeset
   386
module_exit(cleanup_module);
36
6e9de6fbf74c EtherCAT_release() im Fehlerfall beim Laden von Modulen mini und rt.
Florian Pose <fp@igh-essen.com>
parents: 33
diff changeset
   387
42
a22a202d0f42 Domains, Warten beim Senden, 10kHz.
Florian Pose <fp@igh-essen.com>
parents: 40
diff changeset
   388
/*****************************************************************************/