blob: bbf1541a26d2cbb8a71556275ab18a030529064d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
|
#include <sys/ioctl.h>
#include <fcntl.h>
#include <stdio.h>
#include "zaurusstuff.h"
#include "sharp_char.h"
ZaurusStuff::ZaurusStuff() : QObject()
{
}
void ZaurusStuff::blinkLedOn()
{
sharp_led_status st;
st.which = SHARP_LED_COLLIE_1;
st.status = LED_COLLIE_1_FLASHON;
ioctl(open("/dev/sharp_led", O_WRONLY), SHARP_LED_SETSTATUS, &st);
}
void ZaurusStuff::blinkLedOff()
{
sharp_led_status st;
st.which = SHARP_LED_COLLIE_1;
st.status = LED_COLLIE_1_DEFAULT;
ioctl(open("/dev/sharp_led", O_WRONLY), SHARP_LED_SETSTATUS, &st);
}
void ZaurusStuff::buzzerOn()
{
ioctl(open("/dev/sharp_buz", O_WRONLY), SHARP_BUZZER_MAKESOUND, 4);
}
void ZaurusStuff::buzzerOff()
{
}
|