IBM HDAPS, I need a tip.
Hi Guys,
I hope you all aren't sick about the topic. I have a quick question...
Thanks to development of the driver from some nice guys, we are able to get data from the accelerometer. There is one problem. How do we calibrate the values that are outputed from the userspace? All PC's get a different value, and we can't really find the best solution. What is the scientific and smartest way to do this?
i.e. of the driver output from the userspace.
abonilla@debian:~/hdaps/hdaps-dave-0.02
$ ./ibm_hdaps_userspace /dev/ibm_hdaps x_accel: 409 y_accel: 528 temp: 47 temp2: 47 unknown: 7
If I move the PC 45 deg right.(Looking from front the left side is higher)
km_activity (keybd) = 0km_activity (mouse) = 0x_accel: 396y_accel: 579
temp: 47
temp2: 47
unknown: 7
The thing is, people have different values, and I think they are also different depending on where they are.
Another question for this kernel inclusion (heh) Should we use Sysfs or should we use the userspace that outputs this data, else what is recomended?
Thanks in advance,
.Alejandro
Second Try... ;-)
Anyone?
.Alejandro
Quoted 41 lines · Alejandro Bonilla Beeche
Hi Guys,
I hope you all aren't sick about the topic. I have a quick question...
Thanks to development of the driver from some nice guys, we are able to get data from the accelerometer. There is one problem. How do we calibrate the values that are outputed from the userspace? All PC's get a different value, and we can't really find the best solution. What is the scientific and smartest way to do this?
i.e. of the driver output from the userspace.
abonilla@debian:~/hdaps/hdaps-dave-0.02$ ./ibm_hdaps_userspace /dev/ibm_hdaps x_accel: 409 y_accel: 528 temp: 47 temp2: 47 unknown: 7If I move the PC 45 deg right.(Looking from front the left side is higher)
km_activity(keybd) = 0km_activity(mouse) = 0x_accel: 396y_accel: 579
temp: 47
temp2: 47
unknown: 7The thing is, people have different values, and I think they are also different depending on where they are.
Another question for this kernel inclusion (heh) Should we use Sysfs or should we use the userspace that outputs this data, else what is recomended?
Thanks in advance,
.Alejandro
Quoted 3 lines · Alejandro Bonilla Beeche
Second Try... ;-)
Anyone?
You're obviously getting different values because "moving the laptop left to right" will produce a different acceleration every time.
So in order to calibrate it you need a readily available source of constant acceleration, preferably with a known value.
Hint: -9.8 m/sec^2.
Lee
Quoted 5 lines
So in order to calibrate it you need a readily available source of constant acceleration, preferably with a known value.
Hint: -9.8 m/sec^2.
Drop it out of the window? :)
Jan Engelhardt
Well don't forget there is a bios 'calibration' routine that you will see on start up (especially if you are on a moving vehicle/train). What is this calibration used for, and does it provide calibration information to the windows driver? Could we use it somehow to help solve this problem?
Yani
Quoted 13 lines · Jan Engelhardt
Quoted 5 lines
So in order to calibrate it you need a readily available source of constant acceleration, preferably with a known value.
Hint: -9.8 m/sec^2.
Drop it out of the window? :)
Jan Engelhardt
--
Quoted 2 lines · Yani Ioannou
Well don't forget there is a bios 'calibration' routine that you will see on start up (especially if you are on a moving vehicle/train).
I've never seen that. Could you please elaborate on what you see, and when?
-- Dave
Quoted 7 lines · Dave Hansen
Quoted 2 lines · Yani Ioannou
Well don't forget there is a bios 'calibration' routine that you will see on start up (especially if you are on a moving vehicle/train).
I've never seen that. Could you please elaborate on what you see, and when?
Sorry it says diagnostics, not calibration, but the way it behaves leads me to believe its doing some sort of calibration. If you boot up your thinkpad, get rid of your bios splash screen (esc), and tilt the thinkpad back and forth you will see something about IBM Active Protection diagnostics running and a spinner. If you keep tilting the notebook back and forth you can actually prevent the machine from booting because this will fail after a while. Normally you won't see it, I mainly notice it while in a train or car.
Yani
Quoted 6 lines · Jan Engelhardt
Quoted 4 lines
So in order to calibrate it you need a readily available source of constant acceleration, preferably with a known value.
Hint: -9.8 m/sec^2.
Drop it out of the window? :)
No, no. Constant gravity (like having the laptop sitting on the desk) "feels like" constant acceleration.
Dropping it out of the window should measure 0 m/sec^2, because the accelerometer is not working on an inertial referential (I hope this is the correct term in english...). For the accelerometer, this is just like the feeling of free falling inside an elevator: no gravity :)
Signature · 5 lines
Paulo Marques - www.grupopie.com It is a mistake to think you can solve any major problems just with potatoes. Douglas Adams
Quoted 11 lines · Paulo Marques
Quoted 6 lines · Jan Engelhardt
Quoted 4 lines
So in order to calibrate it you need a readily available source of constant acceleration, preferably with a known value.
Hint: -9.8 m/sec^2.
Drop it out of the window? :)
No, no. Constant gravity (like having the laptop sitting on the desk) "feels like" constant acceleration.
Quoted 7 lines
Dropping it out of the window should measure 0 m/sec^2, because the accelerometer is not working on an inertial referential (I hope this is the correct term in english...). For the accelerometer, this is just like the feeling of free falling inside an elevator: no gravity :)
--
Paulo Marques - www.grupopie.com
You need a centrifuge or something that works like one. You can make one and you can calibrate it using simple techniques. For instance, you can swing the mass (laptop) over your head, round and round with your arm. If the rate is such that the mass "just" falls over the top, the 'G's at that point are zero. At the bottom of the swing, the 'G's will be maximum. If you used a fish-scale (spring-scale) to swing the whole thing, you could measure its static weight, then observe the apparent weight everywhere along the swing arc. If you don't have to go through 0 Gs, you can just swing the whole thing around horizontally and observe the fish-scale. The 'G' load is exactly the indicated weight / static weight.
As a relative measure, a 5.5 lb weight, swung through a 5ft diameter, (2.5 ft radius) arc at such a speed that it "just" falls through the top, exerts about 4 Gs (22 lb) at the bottom. Don't accidentally hit something. Impact Gs may make your experiment expensive.
Cheers,
Dick Johnson
Penguin : Linux version 2.6.12 on an i686 machine (5537.79 BogoMips). Warning : 98.36% of all statistics are fiction.
.
I apologize for the following. I tried to kill it with the above dot :
****************************************************************
The information transmitted in this message is confidential and may be privileged. Any review, retransmission, dissemination, or other use of this information by persons or entities other than the intended recipient is prohibited. If you are not the intended recipient, please notify Analogic Corporation immediately - by replying to this message or by sending an email to [email protected] - and destroy all copies of this information, including any attachments, without reading or disclosing them.
Thank you.
Quoted 16 lines · linux-os (Dick Johnson)
Quoted 16 lines
Quoted 6 lines · Jan Engelhardt
Quoted 4 lines
So in order to calibrate it you need a readily available source of constant acceleration, preferably with a known value.
Hint: -9.8 m/sec^2.
Drop it out of the window? :)
No, no. Constant gravity (like having the laptop sitting on the desk) "feels like" constant acceleration.
Dropping it out of the window should measure 0 m/sec^2, because the accelerometer is not working on an inertial referential (I hope this is the correct term in english...). For the accelerometer, this is just like the feeling of free falling inside an elevator: no gravity :)
Quoted 5 lines
Quoted 2 lines
--
Paulo Marques - www.grupopie.comYou need a centrifuge or something that works like one. You can make one and you can calibrate it using simple techniques.
Not at all. It's enough to let the laptop lie on the table for [0,0]G calibration, then put sequentially it on all the four sides for [-1,0]G, [1,0]G, [0,1]G, [0,-1]G calibration.
Quoted 1 line
From these five measurements you have both the zero point and the
slopes, including a good error estimate.
I've done that before when toying with IMUs.
Signature · 2 lines
Vojtech Pavlik SuSE Labs, SuSE CR
Quoted 21 lines · Vojtech Pavlik
Quoted 19 lines · linux-os (Dick Johnson)
Quoted 18 lines
Quoted 6 lines · Jan Engelhardt
Quoted 4 lines
So in order to calibrate it you need a readily available source of constant acceleration, preferably with a known value.
Hint: -9.8 m/sec^2.
Drop it out of the window? :)
No, no. Constant gravity (like having the laptop sitting on the desk) "feels like" constant acceleration.
Dropping it out of the window should measure 0 m/sec^2, because the accelerometer is not working on an inertial referential (I hope this is the correct term in english...). For the accelerometer, this is just like the feeling of free falling inside an elevator: no gravity :)
--
Paulo Marques - www.grupopie.com
Quoted 7 lines
Quoted 2 lines
You need a centrifuge or something that works like one. You can make one and you can calibrate it using simple techniques.
Not at all. It's enough to let the laptop lie on the table for [0,0]G calibration, then put sequentially it on all the four sides for [-1,0]G, [1,0]G, [0,1]G, [0,-1]G calibration.
Huh? A laptop on the table is subjected to 1G on earth. If turned over, is still subjected to 1G, although the sensor may show -1G. Unless the correct k (calibration factor) is known, for each load direction, it cannot be derived from +/- 1, the only readings you have, because of the 1G bias of the load-cell itself.
A pair of load-cells mounted orthagonally, will show the accelleration in 4 axis. However, you can't assume that if you held the mass at a 45 degree angle, for instance, that both sensors would read 0.707 (cos 45) or that if at 90, one pair would read 0.0
You need to calibrate using real values. With a sping-scale, and some room to swing the device, you can readily obtain some accurate load values.
Quoted 9 lines
Quoted 1 line
From these five measurements you have both the zero point and the
slopes, including a good error estimate.
I've done that before when toying with IMUs.
--
Vojtech Pavlik
SuSE Labs, SuSE CR
Cheers,
Dick Johnson
Penguin : Linux version 2.6.12 on an i686 machine (5537.79 BogoMips). Warning : 98.36% of all statistics are fiction.
.
I apologize for the following. I tried to kill it with the above dot :
****************************************************************
The information transmitted in this message is confidential and may be privileged. Any review, retransmission, dissemination, or other use of this information by persons or entities other than the intended recipient is prohibited. If you are not the intended recipient, please notify Analogic Corporation immediately - by replying to this message or by sending an email to [email protected] - and destroy all copies of this information, including any attachments, without reading or disclosing them.
Thank you.
Quoted 5 lines · linux-os (Dick Johnson)
Huh? A laptop on the table is subjected to 1G on earth. If turned over, is still subjected to 1G, although the sensor may show -1G. Unless the correct k (calibration factor) is known, for each load direction, it cannot be derived from +/- 1, the only readings you have, because of the 1G bias of the load-cell itself.
The MEMS accelerometer measures the projection of the acceleration/gravity vector in two orthogonal directions.
If you place the notebook on a horizontal table, the projection of gravity to both the directions measured will be zero, because the gravity vector is orthogonal to both of the directions.
Thus for each direction you get the value at -1, 0, and +1 G, and that's perfectly enough to get a calibration, as long as the accelerometer is linear, which MEMSes to a reasonable degree are.
Quoted 4 lines
A pair of load-cells mounted orthagonally, will show the accelleration in 4 axis. However, you can't assume that if you held the mass at a 45 degree angle, for instance, that both sensors would read 0.707 (cos 45) or that if at 90, one pair would read 0.0
Well, accelerometers are not load cells with a weight mounted to them, that's the thing.
Quoted 3 lines
You need to calibrate using real values. With a sping-scale, and some room to swing the device, you can readily obtain some accurate load values.
The Earth's gravity is a very well known real value.
Signature · 2 lines
Vojtech Pavlik SuSE Labs, SuSE CR
Quoted 8 lines
Quoted 8 lines
Thanks to development of the driver from some nice guys, we are able to get data from the accelerometer. There is one problem. How do we calibrate the values that are outputed from the userspace? All PC's get a different value, and we can't really find the best solution. What is the scientific and smartest way to do this?
I'm not convinced we need to get so hung up on the calibration. Sure, each laptop has somewhat different resting values - but surely what we're looking for is any rate of change in either the X or Y values thats over a predefined 'safe' threshold? (I would imagine that we're only going to find that safe threshold from some imaginative testing once we've got the head parking sorted....)
Just my 2p worth,
Jon.
______________________________________________________________
Email via Mailtraq4Free from Enstar (www.mailtraqdirect.co.uk)
Quoted 18 lines
Quoted 1 line
Quoted 1 line
Thanks to development of the driver from some nice guys, we
are able to
Quoted 2 lines
Quoted 2 lines
get data from the accelerometer. There is one problem. How do we calibrate the values that are outputed from the userspace?
All PC's get
Quoted 1 line
Quoted 1 line
a different value, and we can't really find the best
solution. What is
Quoted 3 lines
Quoted 3 lines
the scientific and smartest way to do this?
I'm not convinced we need to get so hung up on the calibration. Sure, each laptop has somewhat different resting values - but surely what we're looking for is any rate of change in either the X or Y values thats over a predefined 'safe' threshold? (I would imagine that we're only going to find that safe threshold from some imaginative testing once we've got the head parking sorted....)
Quoted 2 lines
Just my 2p worth,
Jon.
hard drive parking was already sorted out. We have a script that does this and works great parking the heads.
The problem here is that we have 10 different models.
One will have 20 as X and the others will have 500 as x. Some will increment in 20 when you move them 45Deg, and some will increment 50.
How can you determine from an shake, to a fall?
.Alejandro
Quoted 3 lines
hard drive parking was already sorted out. We have a script that does this and works great parking the heads.
Would have to disagree with you here. Jens' ATA7 parking code is a great start but we still have a couple of issues to address before it's usable for this purpose. (1) it only works on a subset of the devices that the Windows driver works for, and (2) we need a way to freeze the device for a short period so that the next I/O request doesn't wake it up before it hits the floor...
Quoted 6 lines
The problem here is that we have 10 different models.
One will have 20 as X and the others will have 500 as x. Some will increment in 20 when you move them 45Deg, and some will increment 50.
How can you determine from an shake, to a fall?
If there really are devices with resting values of 20 then I would agree we have a problem. I've tried on a few different Thinkpads and have always seen resting values of several hundreds. If this is true for all, I would like to think we could estimate a sensible value that works for everyone...
Regards,
Jon.
______________________________________________________________
Email via Mailtraq4Free from Enstar (www.mailtraqdirect.co.uk)