Jef Driesen
a568c756a1
Fix the gas mix parsing for the Aladin Tec 2G.
...
Unlike the other models, the Aladin Tec 2G uses only a single byte to
store the oxygen percentage, and there is no need to manually re-map the
deco mix.
Normally, the oxygen percentage is stored using two bytes (little endian
byte order). Thus for a device supporting two gas mixes, four bytes will
be used, and the corresponding gas mix id for each byte is as follows:
ID: 0 0 1 1
After re-mapping the id of the deco mix, this becomes:
ID: 0 0 2 2
Since oxygen percentages are limited to the range 0-100%, the highest
byte (marked with an X) should always be zero and can thus be ignored:
ID: 0 X 2 X
Now, because an oxygen percentage of zero indicates a disabled gas mix,
this is equivalent to a device supporting three (or even four) gas
mixes, each stored using only a single byte:
ID: 0 1 2 3
We can take advantage of this knowledge to avoid having to re-map the
deco mix id.
2016-09-18 07:15:30 -07:00
..
2014-12-21 14:52:12 +01:00
2014-12-21 14:52:12 +01:00
2016-04-26 10:59:02 +02:00
2016-04-26 10:59:02 +02:00
2016-02-27 22:17:36 +01:00
2016-01-05 20:40:21 +01:00
2012-06-21 21:39:24 +02:00
2014-03-19 09:16:07 +01:00
2014-03-19 09:16:07 +01:00
2016-01-05 20:40:21 +01:00
2016-05-10 11:34:57 +02:00
2016-03-23 14:47:09 -07:00
2016-05-10 11:34:57 +02:00
2016-01-05 20:40:21 +01:00
2016-01-05 20:40:21 +01:00
2016-09-17 14:09:37 -07:00
2016-09-17 14:09:37 -07:00
2016-01-05 20:40:21 +01:00
2016-05-10 11:34:57 +02:00
2016-01-05 20:40:21 +01:00
2016-05-10 11:34:57 +02:00
2013-05-23 14:17:41 +02:00
2016-09-17 14:08:32 -07:00
2016-01-05 20:40:21 +01:00
2016-09-18 07:13:27 -07:00
2016-01-05 20:40:21 +01:00
2016-05-10 11:34:57 +02:00
2016-01-05 20:40:21 +01:00
2016-05-10 11:34:57 +02:00
2016-05-10 11:34:57 +02:00
2016-09-18 07:13:55 -07:00
2016-09-17 14:08:32 -07:00
2016-05-10 11:34:57 +02:00
2014-03-14 09:44:10 +01:00
2013-08-22 09:15:55 +02:00
2016-05-10 11:34:57 +02:00
2016-05-10 11:52:32 +02:00
2016-05-10 11:34:57 +02:00
2012-06-21 21:42:37 +02:00
2012-06-21 21:42:37 +02:00
2012-12-27 22:00:35 +01:00
2016-09-17 14:09:37 -07:00
2016-09-17 14:08:32 -07:00
2016-05-10 11:34:57 +02:00
2016-05-10 11:34:57 +02:00
2016-06-12 23:10:37 -07:00
2016-05-10 11:34:57 +02:00
2016-01-05 20:40:21 +01:00
2016-05-10 11:34:57 +02:00
2016-01-05 20:40:21 +01:00
2016-05-10 11:34:57 +02:00
2016-05-10 11:34:57 +02:00
2016-09-17 14:08:32 -07:00
2016-09-18 07:14:23 -07:00
2016-08-08 09:20:55 +02:00
2016-08-08 08:38:23 +02:00
2016-08-12 11:47:41 +02:00
2016-08-21 13:27:06 +02:00
2016-07-11 21:47:29 +02:00
2016-08-21 13:27:06 +02:00
2016-01-05 20:40:21 +01:00
2016-09-17 14:08:32 -07:00
2016-01-05 20:40:21 +01:00
2016-05-10 11:34:57 +02:00
2016-01-05 20:40:21 +01:00
2016-05-10 11:34:57 +02:00
2016-01-05 20:40:21 +01:00
2016-05-10 11:34:57 +02:00
2014-03-19 09:16:07 +01:00
2014-03-19 09:16:07 +01:00
2016-09-17 14:09:37 -07:00
2016-09-17 14:09:37 -07:00
2016-09-17 14:09:37 -07:00
2016-09-18 07:13:13 -07:00
2016-09-18 07:13:13 -07:00
2016-09-18 07:13:13 -07:00
2016-03-23 14:47:09 -07:00
2016-09-18 07:13:13 -07:00
2016-01-05 20:40:21 +01:00
2016-01-05 20:40:21 +01:00
2016-01-05 20:40:21 +01:00
2016-01-05 20:40:21 +01:00
2016-06-12 23:10:48 -07:00
2016-05-10 11:34:57 +02:00
2016-01-05 20:40:21 +01:00
2016-05-10 11:34:57 +02:00
2016-08-29 21:45:33 -07:00
2016-09-17 14:08:32 -07:00
2016-01-05 20:40:21 +01:00
2016-05-10 11:34:57 +02:00
2016-05-10 11:34:57 +02:00
2016-01-05 20:40:21 +01:00
2016-05-10 11:34:57 +02:00
2016-05-10 11:34:57 +02:00
2016-01-05 20:40:21 +01:00
2016-05-10 11:34:57 +02:00
2016-05-10 11:34:57 +02:00
2016-09-18 07:15:30 -07:00
2016-05-10 11:34:57 +02:00
2012-12-27 22:00:35 +01:00
2016-05-10 11:34:57 +02:00