author | frdupin |
Tue, 12 Dec 2006 17:27:48 +0100 | |
changeset 50 | 4a002be78138 |
parent 15 | e930a0e817de |
permissions | -rw-r--r-- |
15
e930a0e817de
Re-orginized led and nvram related code, for generic target.
etisserant
parents:
diff
changeset
|
1 |
/***************************************************************************/ |
e930a0e817de
Re-orginized led and nvram related code, for generic target.
etisserant
parents:
diff
changeset
|
2 |
#include <data.h> |
e930a0e817de
Re-orginized led and nvram related code, for generic target.
etisserant
parents:
diff
changeset
|
3 |
#include <led.h> |
e930a0e817de
Re-orginized led and nvram related code, for generic target.
etisserant
parents:
diff
changeset
|
4 |
|
e930a0e817de
Re-orginized led and nvram related code, for generic target.
etisserant
parents:
diff
changeset
|
5 |
void led_set_redgreen(CO_Data *d, unsigned char state) |
e930a0e817de
Re-orginized led and nvram related code, for generic target.
etisserant
parents:
diff
changeset
|
6 |
{ |
e930a0e817de
Re-orginized led and nvram related code, for generic target.
etisserant
parents:
diff
changeset
|
7 |
if (state & 0x01) |
e930a0e817de
Re-orginized led and nvram related code, for generic target.
etisserant
parents:
diff
changeset
|
8 |
printf("\e[41m ERROR LED ON \e[m "); |
e930a0e817de
Re-orginized led and nvram related code, for generic target.
etisserant
parents:
diff
changeset
|
9 |
else |
e930a0e817de
Re-orginized led and nvram related code, for generic target.
etisserant
parents:
diff
changeset
|
10 |
printf("\e[31m error led off \e[m "); |
e930a0e817de
Re-orginized led and nvram related code, for generic target.
etisserant
parents:
diff
changeset
|
11 |
|
e930a0e817de
Re-orginized led and nvram related code, for generic target.
etisserant
parents:
diff
changeset
|
12 |
if (state & 0x02) |
e930a0e817de
Re-orginized led and nvram related code, for generic target.
etisserant
parents:
diff
changeset
|
13 |
printf("\e[34;42m RUN LED ON \e[m\n"); |
e930a0e817de
Re-orginized led and nvram related code, for generic target.
etisserant
parents:
diff
changeset
|
14 |
else |
e930a0e817de
Re-orginized led and nvram related code, for generic target.
etisserant
parents:
diff
changeset
|
15 |
printf("\e[32m run led off \e[m\n"); |
e930a0e817de
Re-orginized led and nvram related code, for generic target.
etisserant
parents:
diff
changeset
|
16 |
} |
e930a0e817de
Re-orginized led and nvram related code, for generic target.
etisserant
parents:
diff
changeset
|
17 |
|
e930a0e817de
Re-orginized led and nvram related code, for generic target.
etisserant
parents:
diff
changeset
|
18 |