drivers/can_virtual/led_virtual.c
author etisserant
Wed, 10 May 2006 21:05:57 +0200
changeset 1 b3dc740b4b04
parent 0 4472ee7c6c3e
child 3 d9cf34cd6823
permissions -rw-r--r--
Commit some Fix from Francis on sdo.c and abjacces.c. Fix endianisation problems while accessing OD. Also fix SDO abord handling bug.
0
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
     1
/***************************************************************************/
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
     2
#include <led.h>
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
     3
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
     4
void led_set_redgreen(CO_Data *d, int state)
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
     5
{
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
     6
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
     7
        printf("LEDS %d\n",bits);
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
     8
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
     9
        if (bits & 0x01)
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    10
                printf("\e[41m ERROR LED ON \e[m\n");
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    11
        else
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    12
                printf("error led off\n");
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    13
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    14
        if (bits & 0x02)
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    15
                printf("\e[34;42m RUN LED ON \e[m\n");
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    16
        else
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    17
                printf("run led off\n");
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    18
}
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    19
4472ee7c6c3e Commit a new cvs repo.
etisserant
parents:
diff changeset
    20