doc/code_debug.txt
author Robert Lehmann <robert.lehmann@sitec-systems.de>
Tue, 28 Jul 2015 16:36:55 +0200
changeset 793 72e9e1064432
parent 288 26015ee2c2c9
permissions -rw-r--r--
timers_unix: Fix termination problem of WaitReceiveTaskEnd

The function pthread_kill sends the Signal thread and to the own process.
If you use this construct than the application which calls uses the
canfestival api will terminate at the call of canClose. To avoid that
use pthread_cancel instead of pthread_kill. To use the pthread_cancel call
you need to set the cancel ability in the thread function. That means
you need to call pthread_setcancelstate and pthread_setcanceltype.
For the termination of the thread at any time it is important to set the
cancel type to PTHREAD_CANCEL_ASYNCHRONOUS.
0
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
     1
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
     2
# Debug and warning codes
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
     3
-------------------------
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
     4
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
     5
Errors are managed by the macro 
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
     6
MSG_ERR(nbr, string, value)
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
     7
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
     8
Warnings and Informations  are managed by the macro
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
     9
MSG_WAR(nbr, string, value)
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    10
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    11
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    12
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    13
The format of nbr
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    14
++++++++++++++++++++
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    15
16 bits, writen in hexadecimal: 0xtfxx
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    16
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    17
t   : 1    -> Error
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    18
      2    -> Warning
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    19
      3    -> Information
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    20
288
26015ee2c2c9 Modified codes in MSG_ERR and MSG_WAR in emcy.c
luis
parents: 0
diff changeset
    21
f   : 0    -> In file sync.c, emcy.c
0
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    22
      1    ->         lifegrd.c
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    23
      2    ->         objacces.c
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    24
      3    ->         timer.c
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    25
      4    ->         nmtSlave.c
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    26
      5    ->         nmtMaster.c
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    27
      6    ->         canOpenDriver.c, interrupt.c, variahw.c (errors nb 20 .. 30)
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    28
      7    ->         initObjdict.c
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    29
      8    ->         Maps_module_utilisé.cpp
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    30
      9    ->         pdo.c
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    31
      A    ->         sdo.c
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    32
      B    ->         objacces.c
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    33
      D    ->         user's application
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    34
      E    ->         user's application
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    35
      F    ->         user's application
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    36
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    37
xx  : a number
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    38
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    39
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    40
The format of string
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    41
++++++++++++++++++++
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    42
A string, ended by a space, whithout a newline
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    43
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    44
The format of value
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    45
++++++++++++++++++++
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    46
Unsigned 32 bits or less
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    47
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    48
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    49