neděle 21. února 2016

Tlakoměr

Dalším zajímavým senzorem je tlakoměr LPS25HB. Z předchozího příspěvku už víme, jaká je jeho adresa a můžeme si rovnou vyčíst obsah paměti root@AR150:~# i2cdump -y 0 0x5d.

0
1
2
3
4
5
6
7
8
9
a
b
c
d
e
f
0123456789abcdef
00:
00
00
00
00
00
00
00
00
00
00
00
00
00
00
c0
bd
..............??
10:
0f
1b
00
00
08
e6
9e
12
b1
6f
60
00
66
26
58
4a
??..?????o`.f&XJ
20:
00
00
00
00
00
00
00
00
00
80
2f
00
00
00
00
20
.........?/....
30:
00
00
f5
81
fb
26
15
4f
40
00
00
00
00
00
c0
01
..???&?O@.....??
40:
00
00
00
00
00
00
00
00
00
00
00
00
00
00
00
00
................
50:
00
00
00
00
00
00
00
00
00
00
00
00
00
00
00
00
................
60:
00
00
00
00
00
00
00
00
00
00
00
00
00
00
00
00
................
70:
00
00
00
00
00
00
00
00
00
00
00
00
00
00
00
00
................
80:
00
00
00
00
00
00
00
00
00
00
00
00
00
00
c0
bd
..............??
90:
0f
1b
00
00
08
e6
9e
12
b1
6f
60
00
66
26
58
4a
??..?????o`.f&XJ
a0:
00
00
00
00
00
00
00
00
00
80
2f
00
00
00
00
20
.........?/....
b0:
00
00
f5
81
fb
26
15
4f
40
00
00
00
00
00
c0
01
..???&?O@.....??
c0:
00
00
00
00
00
00
00
00
00
00
00
00
00
00
00
00
................
d0:
00
00
00
00
00
00
00
00
00
00
00
00
00
00
00
00
................
e0:
00
00
00
00
00
00
00
00
00
00
00
00
00
00
00
00
................
f0:
00
00
00
00
00
00
00
00
00
00
00
00
00
00
00
00
................

WHO_I_AM         0xbd
bc

PRESSURE          0xF6C7
c7
f6

TEMP                    0x0112
12
01

Zde je reference tříbajtové znaménkové číslo (0x0A představuje MSB a 0x08 obsahuje LSB), po inicializaci je hodnota těchto registrů nulová, nahození bitu AUTOZERO dojde k změření aktuálního tlaku a tento je použit jako referenční tlak.

Žádné komentáře:

Okomentovat