<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/">
	<channel>
		<title><![CDATA[phyphox Forums - Experiments and Ideas]]></title>
		<link>https://phyphox.org/forums/</link>
		<description><![CDATA[phyphox Forums - https://phyphox.org/forums]]></description>
		<pubDate>Sun, 01 Nov 2026 15:55:32 +0000</pubDate>
		<generator>MyBB</generator>
		<item>
			<title><![CDATA[Measured IMU position inside the iPhone 17]]></title>
			<link>https://phyphox.org/forums/showthread.php?tid=2419</link>
			<pubDate>Tue, 27 Oct 2026 15:17:22 +0000</pubDate>
			<dc:creator><![CDATA[<a href="https://phyphox.org/forums/member.php?action=profile&uid=7096">Prototype</a>]]></dc:creator>
			<guid isPermaLink="false">https://phyphox.org/forums/showthread.php?tid=2419</guid>
			<description><![CDATA[Hi all,<br />
<br />
I wanted to know where exactly the accelerometer/gyroscope (IMU) sits inside my iPhone 17. <br />
<br />
Apple does not publish this, and the estimates I found online turned out to be wrong. So I measured it with phyphox and a turntable. Sharing the method and result in case it is useful to others.<br />
<br />
<span style="font-weight: bold;" class="mycode_b">Device / software</span><ul class="mycode_list"><li>iPhone 17 (iPhone18,3), iOS 26.6.1<br />
</li>
<li>phyphox 1.2.1, experiment "Acceleration with g" + "Gyroscope", 100 Hz, exported as .xlsx<br />
</li>
</ul>
<br />
<span style="font-weight: bold;" class="mycode_b">Setup</span><br />
The phone lies flat in a pocket made of pins on a wooden turntable, with its housing center about 120 mm from the axis and the long side tangential. Three runs were done in the same pocket:<br />
<ol type="1" class="mycode_list"><li>display up (reference)<br />
</li>
<li>display down, flipped about the long (y) axis<br />
</li>
<li>display down, flipped about the short (x) axis<br />
</li>
</ol>
Each run: spin up by hand, then let it coast down.<br />
(photo of the setup attached)<br />
<br />
<span style="font-weight: bold;" class="mycode_b">Method</span><br />
Rigid-body model in the device frame (Apple/phyphox axes: x right, y up, z out of the display; phyphox accelerometer = specific force, i.e. +9.81 m/s² in z when lying display-up):<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>ax = wz^2 * lx + dwz/dt * ly + bx
ay = wz^2 * ly - dwz/dt * lx + by</code></div></div>(lx, ly) is the vector from the IMU to the rotation axis. bx and by absorb offset and tilt.<ul class="mycode_list"><li>Linear least squares per run, using the same smoothing filter on data and regressors.<br />
</li>
<li>Time shift between gyro and accelerometer estimated by grid search: consistently +7 to +8 ms.<br />
</li>
<li>Confidence intervals from a moving-block bootstrap, because the residuals are autocorrelated.<br />
</li>
<li>The runs are combined via l_k = S_k*c - p, where p is the IMU position relative to the housing center, c the housing center -&gt; axis vector, and S_k the flip of run k. Because the phone is flipped about both axes, p follows from the data without relying on the measured 120 mm or on the alignment angle.<br />
</li>
</ul>
Consistency check: the lever arm from the centripetal term (wz^2) and from the tangential term (dwz/dt) agree to about 1 mm in every run.<br />
<br />
<span style="font-weight: bold;" class="mycode_b">Result</span> (origin = geometric center of the housing 149.6 x 71.5 mm, looking at the display, 95% CI):<ul class="mycode_list"><li>x = -29.0 mm [-30.2, -27.9] (left half, about 7 mm from the left edge)<br />
</li>
<li>y = -0.1 mm [-1.4, +1.0] (practically at mid-height)<br />
</li>
<li>z: not observable with this method<br />
</li>
</ul>
(plot attached)<br />
<br />
<span style="font-weight: bold;" class="mycode_b">Caveats</span><ul class="mycode_list"><li>Single device. I assumed about 1 mm repositioning tolerance in the pocket, and this dominates the CI. The pure statistical error is about 0.1 mm.<br />
</li>
<li>Sensor scale-factor errors are not included. A 1 % gyro scale error would shift the lever arm by about 2 %.<br />
</li>
<li>The data put the axis at about 116 mm from the housing center, not the 120 mm I measured with a ruler. Probably the turntable runs slightly eccentric. The result for p does not depend on this.<br />
</li>
<li>phyphox detail (from the iOS source): the accelerometer is raw CMAccelerometerData x (-9.81), the gyroscope is CMDeviceMotion.rotationRate (bias-corrected), not raw CMGyroData.<br />
</li>
</ul>
<br />
I'd be happy if someone could repeat this with another iPhone 17 or other models. I'll also share my Octave script and my measurement data.<br />
<br />
Best regards,<br />
Prototype<br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>% Estimation of the IMU position (iPhone 17, phyphox) from several turntable runs
%
% Rigid-body model for a rotation about the device z-axis (phone frame, phyphox
% convention: specific force, +x right, +y up, +z out of the display). With
% l = (lx, ly) being the vector from the IMU to the rotation axis:
%   ax = wz²*lx + dwz/dt*ly + bx
%   ay = wz²*ly - dwz/dt*lx + by
% (bx, by: sensor offset + gravity leakage due to tilt)
%
% Combination of the runs: the phone sits in the same pocket in every run, only
% its orientation changes. With c = vector housing center -&gt; rotation axis in the
% phone frame of the reference run (display up, see turntable.png) and p = IMU
% position relative to the housing center:
%   l_k = S_k*c - p
% S_k maps the reference placement into the phone frame of run k:
%   display up   (reference)            S = [ 1 0; 0  1]
%   display down, flipped about y-axis  S = [-1 0; 0  1]
%   display down, flipped about x-axis  S = [ 1 0; 0 -1]
%   display up,   rotated by 180°       S = [-1 0; 0 -1]
% Components of c that the runs cannot resolve are taken from the setup prior
% (R, phi). With the runs 'up' + 'down about y' this applies to the y-direction.

% clean up
clear all;
close all;
clc;

% settings
runs = struct( ...
  'file', {'Translation und Rotation 2026-09-29 16-10-10.xlsx', ...
           'Translation und Rotation 2026-10-26 15-35-40.xlsx', ...
           'Translation und Rotation 2026-10-27 13-36-20.xlsx'}, ...
  'S',    {[1 0; 0 1], [-1 0; 0 1], [1 0; 0 -1]}, ...
  'up',   {true, false, false});  % display up? (checked against az)
R      = 120;    % prior: distance housing center -&gt; rotation axis (mm)
sigR   = 1;      % uncertainty of R (mm, 1 sigma)
phi    = 0;      % prior: angle of the rotation axis seen from the housing center (deg)
sigphi = 2;      % uncertainty of phi (deg, 1 sigma)
sigpos = 1;      % repositioning tolerance of the phone in the pocket (mm, 1 sigma)
Tsm    = 0.10;   % smoothing window (s)
taus   = -0.05 : 0.001 : 0.05;  % search grid for the gyro time shift (s)
Lblk   = 1.0;    % block length for the moving-block bootstrap (s)
B      = 2000;   % number of bootstrap samples
conf   = 0.95;   % confidence level
m2mm   = 1000;
rand('seed', 42);
randn('seed', 42);

% load a phyphox export (cached as .mat next to the .xlsx)
function [ACC, GYRO] = load_run(file)
  [~, name] = fileparts(file);
  cache = [name, '.mat'];
  if exist(cache, 'file')
    load(cache);
  else
    pkg load io;
    pkg load windows;
    ACC  = xlsread(file, 'Accelerometer');  % t (s), ax, ay, az (m/s²)
    GYRO = xlsread(file, 'Gyroscope');      % t (s), wx, wy, wz (rad/s)
    save('-v7', cache, 'ACC', 'GYRO');
  end
end

% build the (smoothed) linear model for a given gyro time shift tau
function [Y, X] = build_model(ta, ax, ay, tw, wz, tau, nsm, keep)
  w  = interp1(tw + tau, wz, ta, 'linear', 'extrap');
  dw = gradient(w, ta);
  % the same linear filter is applied to data and regressors -&gt; model stays exact
  f  = @(v) movmean(v, nsm);
  W2 = f(w.^2)(keep);
  A  = f(dw)(keep);
  ax = f(ax)(keep);
  ay = f(ay)(keep);
  o  = ones(size(W2));
  z  = zeros(size(W2));
  Y  = [ax; ay];
  X  = [W2,  A, o, z;
        -A, W2, z, o];
end

% fit a single run: time shift, least squares, moving-block bootstrap
function r = fit_run(ACC, GYRO, Tsm, taus, Lblk, B)
  ta  = ACC(:, 1) - ACC(1, 1);
  tw  = GYRO(:, 1) - ACC(1, 1);
  dt  = median(diff(ta));
  nsm = max(1, round(Tsm/dt));
  % only use samples covered by the gyro, minus the filter edges
  keep = ta &gt; tw(1) + max(abs(taus)) &amp; ta &lt; tw(end) - max(abs(taus));
  keep(1 : nsm) = false;
  keep(end - nsm + 1 : end) = false;
  n = sum(keep);

  ssr = zeros(size(taus));
  for k = 1 : numel(taus)
    [Y, X] = build_model(ta, ACC(:, 2), ACC(:, 3), tw, GYRO(:, 4), taus(k), nsm, keep);
    ssr(k) = sum((Y - X*(X&#92;Y)).^2);
  end
  [~, kbest] = min(ssr);
  r.tau = taus(kbest);
  r.ssr = ssr;

  [Y, X] = build_model(ta, ACC(:, 2), ACC(:, 3), tw, GYRO(:, 4), r.tau, nsm, keep);
  th = X&#92;Y;
  r.th  = th;
  r.rms = sqrt(mean((Y - X*th).^2));
  r.lx_rad = X(1:n, 1)&#92;(Y(1:n) - th(3) - X(1:n, 2)*th(2));              % ax ~ wz²*lx
  r.lx_tan = X(n+1:end, 1)&#92;(Y(n+1:end) - th(4) - X(n+1:end, 2)*th(2));  % ay ~ -dwz/dt*lx
  r.t = ta(keep);
  r.Y = Y;
  r.Ym = X*th;
  r.n = n;
  r.az = mean(ACC(:, 4));

  % residuals are strongly autocorrelated -&gt; resample blocks
  L   = max(1, round(Lblk/dt));
  nb  = ceil(n/L);
  thb = zeros(B, numel(th));
  for b = 1 : B
    s   = randi(n - L + 1, nb, 1);
    idx = (s + (0 : L - 1))';
    idx = idx(1 : n)';
    thb(b, :) = ([X(idx, :); X(n + idx, :)]&#92;[Y(idx); Y(n + idx)])';
  end
  r.thb = thb;
end

% combine runs: weighted least squares for u = [c; p] incl. setup prior on c
function u = combine(l, S, c0, Wc, sigpos)
  M = [];
  y = [];
  for k = 1 : numel(l)
    M = [M; [S{k}, -eye(2)]/sigpos];
    y = [y; l{k}/sigpos];
  end
  M = [M; [Wc, zeros(2)]];
  y = [y; Wc*c0];
  u = M&#92;y;
end

% 1) fit every run
nr = numel(runs);
for k = 1 : nr
  [ACC, GYRO] = load_run(runs(k).file);
  res(k) = fit_run(ACC, GYRO, Tsm, taus, Lblk, B);
  if (res(k).az &gt; 0) != runs(k).up
    warning('run %d: az = %.2f m/s² does not match up = %d', k, res(k).az, runs(k).up);
  end
end

% 2) combine the runs (nominal + Monte Carlo over bootstrap, prior and repositioning)
c0  = R*[cosd(phi); sind(phi)];
Ec  = [cosd(phi), -sind(phi); sind(phi), cosd(phi)];   % radial/tangential directions
Sc  = Ec*diag([sigR, R*sigphi*pi/180].^2)*Ec';          % prior covariance of c
Wc  = chol(inv(Sc));
S   = {runs.S};
l   = arrayfun(@(r) r.th(1:2)*m2mm, res, 'UniformOutput', false);
u   = combine(l, S, c0, Wc, sigpos);
ub  = zeros(B, 4);
for b = 1 : B
  lb = arrayfun(@(r) r.thb(b, 1:2)'*m2mm + sigpos*randn(2, 1), res, 'UniformOutput', false);
  ub(b, :) = combine(lb, S, c0 + chol(Sc)'*randn(2, 1), Wc, sigpos)';
end
c  = u(1:2);
p  = u(3:4);
pb = ub(:, 3:4);
% how much does each coordinate of p depend on the prior? (1 = only prior, 0 = only data)
J  = zeros(2);
for j = 1 : 2
  dc = zeros(2, 1);
  dc(j) = 1;
  du = combine(l, S, c0 + dc, Wc, sigpos) - u;
  J(:, j) = du(3:4);
end

% report
q  = [(1 - conf)/2, (1 + conf)/2];
ci = @(v) quantile(v, q);
printf('Single runs (vector IMU -&gt; rotation axis in device coordinates, %2.0f%% CI, block bootstrap):&#92;n', conf*100);
for k = 1 : nr
  r = res(k);
  printf('&#92;n  Run %d: %s&#92;n', k, runs(k).file);
  printf('    display %s (az = %+.2f m/s²), tau = %+.0f ms, RMS = %.3f m/s²&#92;n', ...
         {'down', 'up  '}{runs(k).up + 1}, r.az, r.tau*1000, r.rms);
  printf('    lx = %8.2f mm  [%8.2f, %8.2f]   (radial %.2f / tangential %.2f)&#92;n', ...
         r.th(1)*m2mm, ci(r.thb(:, 1)*m2mm), r.lx_rad*m2mm, r.lx_tan*m2mm);
  printf('    ly = %8.2f mm  [%8.2f, %8.2f]&#92;n', r.th(2)*m2mm, ci(r.thb(:, 2)*m2mm));
  printf('    bx = %6.3f m/s², by = %6.3f m/s²&#92;n', r.th(3), r.th(4));
end
printf('&#92;nConsistency: residuals of the combined equations l_k = S_k*c - p (mm):&#92;n');
for k = 1 : nr
  printf('  Run %d: [%+6.2f, %+6.2f]&#92;n', k, S{k}*c - p - l{k});
end
printf('&#92;nRotation axis seen from the housing center (reference placement): c = [%.2f, %.2f] mm&#92;n', c);
printf('  =&gt; R = %.2f mm (prior %.1f +- %.1f), phi = %.2f deg (prior %.1f +- %.1f)&#92;n', ...
       norm(c), R, sigR, atan2d(c(2), c(1)), phi, sigphi);
printf('&#92;nIMU position relative to the housing center (x right, y up, looking at the display):&#92;n');
printf('  x = %7.2f mm   [%7.2f, %7.2f]   share of prior R/phi: %3.0f %%&#92;n', p(1), ci(pb(:, 1)), 100*norm(J(1, :)));
printf('  y = %7.2f mm   [%7.2f, %7.2f]   share of prior R/phi: %3.0f %%&#92;n', p(2), ci(pb(:, 2)), 100*norm(J(2, :)));

% visualization
figure(1);
for k = 1 : nr
  r = res(k);
  subplot(nr, 2, 2*k - 1);
  plot(r.t, r.Y(1:r.n), '-', r.t, r.Ym(1:r.n), '--');
  grid on;
  ylabel(sprintf('run %d: a_x (m/s²)', k));
  subplot(nr, 2, 2*k);
  plot(r.t, r.Y(r.n+1:end), '-', r.t, r.Ym(r.n+1:end), '--');
  grid on;
  ylabel(sprintf('run %d: a_y (m/s²)', k));
end
xlabel('t (s)');
legend('measurement (smoothed)', 'model');

figure(2, 'position', [100 100 800 700]);
hold on;
rectangle('Position', [-71.5/2, -149.6/2, 71.5, 149.6], 'Curvature', 0.15);
plot(pb(:, 1), pb(:, 2), '.', 'Color', [0.7 0.7 0.9]);
plot(p(1), p(2), 'r+', 'MarkerSize', 14, 'LineWidth', 2);
plot(0, 0, 'k+');
axis equal;
axis([-60 60 -80 80]);
grid on;
xlabel('x (mm)');
ylabel('y (mm)');
title('iPhone 17: IMU position (looking at the display)');
legend('housing 71.5 x 149.6 mm', 'bootstrap / Monte Carlo', 'estimate', 'housing center', ...
       'location', 'eastoutside');
text(p(1) + 4, p(2) + 22, sprintf('x = %.1f mm [%.1f, %.1f]&#92;ny = %.1f mm [%.1f, %.1f]&#92;n(%2.0f%% CI)', ...
     p(1), ci(pb(:, 1)), p(2), ci(pb(:, 2)), conf*100));
print(2, 'imu_position_estimate.png', '-dpng', '-r120');</code></div></div><br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://phyphox.org/forums/images/attachtypes/image.png" title="PNG Image" border="0" alt=".png" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=796" target="_blank" title="">turntable.png</a> (Size: 441.58 KB / Downloads: 6)
<!-- end: postbit_attachments_attachment --><br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://phyphox.org/forums/images/attachtypes/image.png" title="PNG Image" border="0" alt=".png" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=797" target="_blank" title="">imu_position_estimate.png</a> (Size: 28.67 KB / Downloads: 5)
<!-- end: postbit_attachments_attachment --><br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://phyphox.org/forums/images/attachtypes/xls.png" title="Microsoft Excel 2007 Document" border="0" alt=".xlsx" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=798" target="_blank" title="">Translation und Rotation 2026-09-29 16-10-10.xlsx</a> (Size: 237.56 KB / Downloads: 4)
<!-- end: postbit_attachments_attachment --><br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://phyphox.org/forums/images/attachtypes/xls.png" title="Microsoft Excel 2007 Document" border="0" alt=".xlsx" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=799" target="_blank" title="">Translation und Rotation 2026-10-26 15-35-40.xlsx</a> (Size: 143.61 KB / Downloads: 5)
<!-- end: postbit_attachments_attachment --><br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://phyphox.org/forums/images/attachtypes/xls.png" title="Microsoft Excel 2007 Document" border="0" alt=".xlsx" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=800" target="_blank" title="">Translation und Rotation 2026-10-27 13-36-20.xlsx</a> (Size: 141.27 KB / Downloads: 7)
<!-- end: postbit_attachments_attachment -->]]></description>
			<content:encoded><![CDATA[Hi all,<br />
<br />
I wanted to know where exactly the accelerometer/gyroscope (IMU) sits inside my iPhone 17. <br />
<br />
Apple does not publish this, and the estimates I found online turned out to be wrong. So I measured it with phyphox and a turntable. Sharing the method and result in case it is useful to others.<br />
<br />
<span style="font-weight: bold;" class="mycode_b">Device / software</span><ul class="mycode_list"><li>iPhone 17 (iPhone18,3), iOS 26.6.1<br />
</li>
<li>phyphox 1.2.1, experiment "Acceleration with g" + "Gyroscope", 100 Hz, exported as .xlsx<br />
</li>
</ul>
<br />
<span style="font-weight: bold;" class="mycode_b">Setup</span><br />
The phone lies flat in a pocket made of pins on a wooden turntable, with its housing center about 120 mm from the axis and the long side tangential. Three runs were done in the same pocket:<br />
<ol type="1" class="mycode_list"><li>display up (reference)<br />
</li>
<li>display down, flipped about the long (y) axis<br />
</li>
<li>display down, flipped about the short (x) axis<br />
</li>
</ol>
Each run: spin up by hand, then let it coast down.<br />
(photo of the setup attached)<br />
<br />
<span style="font-weight: bold;" class="mycode_b">Method</span><br />
Rigid-body model in the device frame (Apple/phyphox axes: x right, y up, z out of the display; phyphox accelerometer = specific force, i.e. +9.81 m/s² in z when lying display-up):<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>ax = wz^2 * lx + dwz/dt * ly + bx
ay = wz^2 * ly - dwz/dt * lx + by</code></div></div>(lx, ly) is the vector from the IMU to the rotation axis. bx and by absorb offset and tilt.<ul class="mycode_list"><li>Linear least squares per run, using the same smoothing filter on data and regressors.<br />
</li>
<li>Time shift between gyro and accelerometer estimated by grid search: consistently +7 to +8 ms.<br />
</li>
<li>Confidence intervals from a moving-block bootstrap, because the residuals are autocorrelated.<br />
</li>
<li>The runs are combined via l_k = S_k*c - p, where p is the IMU position relative to the housing center, c the housing center -&gt; axis vector, and S_k the flip of run k. Because the phone is flipped about both axes, p follows from the data without relying on the measured 120 mm or on the alignment angle.<br />
</li>
</ul>
Consistency check: the lever arm from the centripetal term (wz^2) and from the tangential term (dwz/dt) agree to about 1 mm in every run.<br />
<br />
<span style="font-weight: bold;" class="mycode_b">Result</span> (origin = geometric center of the housing 149.6 x 71.5 mm, looking at the display, 95% CI):<ul class="mycode_list"><li>x = -29.0 mm [-30.2, -27.9] (left half, about 7 mm from the left edge)<br />
</li>
<li>y = -0.1 mm [-1.4, +1.0] (practically at mid-height)<br />
</li>
<li>z: not observable with this method<br />
</li>
</ul>
(plot attached)<br />
<br />
<span style="font-weight: bold;" class="mycode_b">Caveats</span><ul class="mycode_list"><li>Single device. I assumed about 1 mm repositioning tolerance in the pocket, and this dominates the CI. The pure statistical error is about 0.1 mm.<br />
</li>
<li>Sensor scale-factor errors are not included. A 1 % gyro scale error would shift the lever arm by about 2 %.<br />
</li>
<li>The data put the axis at about 116 mm from the housing center, not the 120 mm I measured with a ruler. Probably the turntable runs slightly eccentric. The result for p does not depend on this.<br />
</li>
<li>phyphox detail (from the iOS source): the accelerometer is raw CMAccelerometerData x (-9.81), the gyroscope is CMDeviceMotion.rotationRate (bias-corrected), not raw CMGyroData.<br />
</li>
</ul>
<br />
I'd be happy if someone could repeat this with another iPhone 17 or other models. I'll also share my Octave script and my measurement data.<br />
<br />
Best regards,<br />
Prototype<br />
<br />
<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>% Estimation of the IMU position (iPhone 17, phyphox) from several turntable runs
%
% Rigid-body model for a rotation about the device z-axis (phone frame, phyphox
% convention: specific force, +x right, +y up, +z out of the display). With
% l = (lx, ly) being the vector from the IMU to the rotation axis:
%   ax = wz²*lx + dwz/dt*ly + bx
%   ay = wz²*ly - dwz/dt*lx + by
% (bx, by: sensor offset + gravity leakage due to tilt)
%
% Combination of the runs: the phone sits in the same pocket in every run, only
% its orientation changes. With c = vector housing center -&gt; rotation axis in the
% phone frame of the reference run (display up, see turntable.png) and p = IMU
% position relative to the housing center:
%   l_k = S_k*c - p
% S_k maps the reference placement into the phone frame of run k:
%   display up   (reference)            S = [ 1 0; 0  1]
%   display down, flipped about y-axis  S = [-1 0; 0  1]
%   display down, flipped about x-axis  S = [ 1 0; 0 -1]
%   display up,   rotated by 180°       S = [-1 0; 0 -1]
% Components of c that the runs cannot resolve are taken from the setup prior
% (R, phi). With the runs 'up' + 'down about y' this applies to the y-direction.

% clean up
clear all;
close all;
clc;

% settings
runs = struct( ...
  'file', {'Translation und Rotation 2026-09-29 16-10-10.xlsx', ...
           'Translation und Rotation 2026-10-26 15-35-40.xlsx', ...
           'Translation und Rotation 2026-10-27 13-36-20.xlsx'}, ...
  'S',    {[1 0; 0 1], [-1 0; 0 1], [1 0; 0 -1]}, ...
  'up',   {true, false, false});  % display up? (checked against az)
R      = 120;    % prior: distance housing center -&gt; rotation axis (mm)
sigR   = 1;      % uncertainty of R (mm, 1 sigma)
phi    = 0;      % prior: angle of the rotation axis seen from the housing center (deg)
sigphi = 2;      % uncertainty of phi (deg, 1 sigma)
sigpos = 1;      % repositioning tolerance of the phone in the pocket (mm, 1 sigma)
Tsm    = 0.10;   % smoothing window (s)
taus   = -0.05 : 0.001 : 0.05;  % search grid for the gyro time shift (s)
Lblk   = 1.0;    % block length for the moving-block bootstrap (s)
B      = 2000;   % number of bootstrap samples
conf   = 0.95;   % confidence level
m2mm   = 1000;
rand('seed', 42);
randn('seed', 42);

% load a phyphox export (cached as .mat next to the .xlsx)
function [ACC, GYRO] = load_run(file)
  [~, name] = fileparts(file);
  cache = [name, '.mat'];
  if exist(cache, 'file')
    load(cache);
  else
    pkg load io;
    pkg load windows;
    ACC  = xlsread(file, 'Accelerometer');  % t (s), ax, ay, az (m/s²)
    GYRO = xlsread(file, 'Gyroscope');      % t (s), wx, wy, wz (rad/s)
    save('-v7', cache, 'ACC', 'GYRO');
  end
end

% build the (smoothed) linear model for a given gyro time shift tau
function [Y, X] = build_model(ta, ax, ay, tw, wz, tau, nsm, keep)
  w  = interp1(tw + tau, wz, ta, 'linear', 'extrap');
  dw = gradient(w, ta);
  % the same linear filter is applied to data and regressors -&gt; model stays exact
  f  = @(v) movmean(v, nsm);
  W2 = f(w.^2)(keep);
  A  = f(dw)(keep);
  ax = f(ax)(keep);
  ay = f(ay)(keep);
  o  = ones(size(W2));
  z  = zeros(size(W2));
  Y  = [ax; ay];
  X  = [W2,  A, o, z;
        -A, W2, z, o];
end

% fit a single run: time shift, least squares, moving-block bootstrap
function r = fit_run(ACC, GYRO, Tsm, taus, Lblk, B)
  ta  = ACC(:, 1) - ACC(1, 1);
  tw  = GYRO(:, 1) - ACC(1, 1);
  dt  = median(diff(ta));
  nsm = max(1, round(Tsm/dt));
  % only use samples covered by the gyro, minus the filter edges
  keep = ta &gt; tw(1) + max(abs(taus)) &amp; ta &lt; tw(end) - max(abs(taus));
  keep(1 : nsm) = false;
  keep(end - nsm + 1 : end) = false;
  n = sum(keep);

  ssr = zeros(size(taus));
  for k = 1 : numel(taus)
    [Y, X] = build_model(ta, ACC(:, 2), ACC(:, 3), tw, GYRO(:, 4), taus(k), nsm, keep);
    ssr(k) = sum((Y - X*(X&#92;Y)).^2);
  end
  [~, kbest] = min(ssr);
  r.tau = taus(kbest);
  r.ssr = ssr;

  [Y, X] = build_model(ta, ACC(:, 2), ACC(:, 3), tw, GYRO(:, 4), r.tau, nsm, keep);
  th = X&#92;Y;
  r.th  = th;
  r.rms = sqrt(mean((Y - X*th).^2));
  r.lx_rad = X(1:n, 1)&#92;(Y(1:n) - th(3) - X(1:n, 2)*th(2));              % ax ~ wz²*lx
  r.lx_tan = X(n+1:end, 1)&#92;(Y(n+1:end) - th(4) - X(n+1:end, 2)*th(2));  % ay ~ -dwz/dt*lx
  r.t = ta(keep);
  r.Y = Y;
  r.Ym = X*th;
  r.n = n;
  r.az = mean(ACC(:, 4));

  % residuals are strongly autocorrelated -&gt; resample blocks
  L   = max(1, round(Lblk/dt));
  nb  = ceil(n/L);
  thb = zeros(B, numel(th));
  for b = 1 : B
    s   = randi(n - L + 1, nb, 1);
    idx = (s + (0 : L - 1))';
    idx = idx(1 : n)';
    thb(b, :) = ([X(idx, :); X(n + idx, :)]&#92;[Y(idx); Y(n + idx)])';
  end
  r.thb = thb;
end

% combine runs: weighted least squares for u = [c; p] incl. setup prior on c
function u = combine(l, S, c0, Wc, sigpos)
  M = [];
  y = [];
  for k = 1 : numel(l)
    M = [M; [S{k}, -eye(2)]/sigpos];
    y = [y; l{k}/sigpos];
  end
  M = [M; [Wc, zeros(2)]];
  y = [y; Wc*c0];
  u = M&#92;y;
end

% 1) fit every run
nr = numel(runs);
for k = 1 : nr
  [ACC, GYRO] = load_run(runs(k).file);
  res(k) = fit_run(ACC, GYRO, Tsm, taus, Lblk, B);
  if (res(k).az &gt; 0) != runs(k).up
    warning('run %d: az = %.2f m/s² does not match up = %d', k, res(k).az, runs(k).up);
  end
end

% 2) combine the runs (nominal + Monte Carlo over bootstrap, prior and repositioning)
c0  = R*[cosd(phi); sind(phi)];
Ec  = [cosd(phi), -sind(phi); sind(phi), cosd(phi)];   % radial/tangential directions
Sc  = Ec*diag([sigR, R*sigphi*pi/180].^2)*Ec';          % prior covariance of c
Wc  = chol(inv(Sc));
S   = {runs.S};
l   = arrayfun(@(r) r.th(1:2)*m2mm, res, 'UniformOutput', false);
u   = combine(l, S, c0, Wc, sigpos);
ub  = zeros(B, 4);
for b = 1 : B
  lb = arrayfun(@(r) r.thb(b, 1:2)'*m2mm + sigpos*randn(2, 1), res, 'UniformOutput', false);
  ub(b, :) = combine(lb, S, c0 + chol(Sc)'*randn(2, 1), Wc, sigpos)';
end
c  = u(1:2);
p  = u(3:4);
pb = ub(:, 3:4);
% how much does each coordinate of p depend on the prior? (1 = only prior, 0 = only data)
J  = zeros(2);
for j = 1 : 2
  dc = zeros(2, 1);
  dc(j) = 1;
  du = combine(l, S, c0 + dc, Wc, sigpos) - u;
  J(:, j) = du(3:4);
end

% report
q  = [(1 - conf)/2, (1 + conf)/2];
ci = @(v) quantile(v, q);
printf('Single runs (vector IMU -&gt; rotation axis in device coordinates, %2.0f%% CI, block bootstrap):&#92;n', conf*100);
for k = 1 : nr
  r = res(k);
  printf('&#92;n  Run %d: %s&#92;n', k, runs(k).file);
  printf('    display %s (az = %+.2f m/s²), tau = %+.0f ms, RMS = %.3f m/s²&#92;n', ...
         {'down', 'up  '}{runs(k).up + 1}, r.az, r.tau*1000, r.rms);
  printf('    lx = %8.2f mm  [%8.2f, %8.2f]   (radial %.2f / tangential %.2f)&#92;n', ...
         r.th(1)*m2mm, ci(r.thb(:, 1)*m2mm), r.lx_rad*m2mm, r.lx_tan*m2mm);
  printf('    ly = %8.2f mm  [%8.2f, %8.2f]&#92;n', r.th(2)*m2mm, ci(r.thb(:, 2)*m2mm));
  printf('    bx = %6.3f m/s², by = %6.3f m/s²&#92;n', r.th(3), r.th(4));
end
printf('&#92;nConsistency: residuals of the combined equations l_k = S_k*c - p (mm):&#92;n');
for k = 1 : nr
  printf('  Run %d: [%+6.2f, %+6.2f]&#92;n', k, S{k}*c - p - l{k});
end
printf('&#92;nRotation axis seen from the housing center (reference placement): c = [%.2f, %.2f] mm&#92;n', c);
printf('  =&gt; R = %.2f mm (prior %.1f +- %.1f), phi = %.2f deg (prior %.1f +- %.1f)&#92;n', ...
       norm(c), R, sigR, atan2d(c(2), c(1)), phi, sigphi);
printf('&#92;nIMU position relative to the housing center (x right, y up, looking at the display):&#92;n');
printf('  x = %7.2f mm   [%7.2f, %7.2f]   share of prior R/phi: %3.0f %%&#92;n', p(1), ci(pb(:, 1)), 100*norm(J(1, :)));
printf('  y = %7.2f mm   [%7.2f, %7.2f]   share of prior R/phi: %3.0f %%&#92;n', p(2), ci(pb(:, 2)), 100*norm(J(2, :)));

% visualization
figure(1);
for k = 1 : nr
  r = res(k);
  subplot(nr, 2, 2*k - 1);
  plot(r.t, r.Y(1:r.n), '-', r.t, r.Ym(1:r.n), '--');
  grid on;
  ylabel(sprintf('run %d: a_x (m/s²)', k));
  subplot(nr, 2, 2*k);
  plot(r.t, r.Y(r.n+1:end), '-', r.t, r.Ym(r.n+1:end), '--');
  grid on;
  ylabel(sprintf('run %d: a_y (m/s²)', k));
end
xlabel('t (s)');
legend('measurement (smoothed)', 'model');

figure(2, 'position', [100 100 800 700]);
hold on;
rectangle('Position', [-71.5/2, -149.6/2, 71.5, 149.6], 'Curvature', 0.15);
plot(pb(:, 1), pb(:, 2), '.', 'Color', [0.7 0.7 0.9]);
plot(p(1), p(2), 'r+', 'MarkerSize', 14, 'LineWidth', 2);
plot(0, 0, 'k+');
axis equal;
axis([-60 60 -80 80]);
grid on;
xlabel('x (mm)');
ylabel('y (mm)');
title('iPhone 17: IMU position (looking at the display)');
legend('housing 71.5 x 149.6 mm', 'bootstrap / Monte Carlo', 'estimate', 'housing center', ...
       'location', 'eastoutside');
text(p(1) + 4, p(2) + 22, sprintf('x = %.1f mm [%.1f, %.1f]&#92;ny = %.1f mm [%.1f, %.1f]&#92;n(%2.0f%% CI)', ...
     p(1), ci(pb(:, 1)), p(2), ci(pb(:, 2)), conf*100));
print(2, 'imu_position_estimate.png', '-dpng', '-r120');</code></div></div><br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://phyphox.org/forums/images/attachtypes/image.png" title="PNG Image" border="0" alt=".png" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=796" target="_blank" title="">turntable.png</a> (Size: 441.58 KB / Downloads: 6)
<!-- end: postbit_attachments_attachment --><br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://phyphox.org/forums/images/attachtypes/image.png" title="PNG Image" border="0" alt=".png" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=797" target="_blank" title="">imu_position_estimate.png</a> (Size: 28.67 KB / Downloads: 5)
<!-- end: postbit_attachments_attachment --><br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://phyphox.org/forums/images/attachtypes/xls.png" title="Microsoft Excel 2007 Document" border="0" alt=".xlsx" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=798" target="_blank" title="">Translation und Rotation 2026-09-29 16-10-10.xlsx</a> (Size: 237.56 KB / Downloads: 4)
<!-- end: postbit_attachments_attachment --><br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://phyphox.org/forums/images/attachtypes/xls.png" title="Microsoft Excel 2007 Document" border="0" alt=".xlsx" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=799" target="_blank" title="">Translation und Rotation 2026-10-26 15-35-40.xlsx</a> (Size: 143.61 KB / Downloads: 5)
<!-- end: postbit_attachments_attachment --><br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://phyphox.org/forums/images/attachtypes/xls.png" title="Microsoft Excel 2007 Document" border="0" alt=".xlsx" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=800" target="_blank" title="">Translation und Rotation 2026-10-27 13-36-20.xlsx</a> (Size: 141.27 KB / Downloads: 7)
<!-- end: postbit_attachments_attachment -->]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[Data transfer without WiFi]]></title>
			<link>https://phyphox.org/forums/showthread.php?tid=2396</link>
			<pubDate>Fri, 25 Sep 2026 10:54:22 +0000</pubDate>
			<dc:creator><![CDATA[<a href="https://phyphox.org/forums/member.php?action=profile&uid=229">Physikator</a>]]></dc:creator>
			<guid isPermaLink="false">https://phyphox.org/forums/showthread.php?tid=2396</guid>
			<description><![CDATA[I wanted to measure the pressure in a closed metal lunch box, so WiFi did not work. I managed to create an experiment to generate a sine wave with a frequency corresponding to the air pressure, 1hPa=1Hz. With a second phone I was able do receive the sound and show the frequency=pressure over time. However, this is not very reliable, other sounds disturb the measurement. So I thought of using the vibration alarm as a signal source and a magnetometer as a receiver.<br />
Does anyone know if the vibration generates (enough of) a magnetic field for this to work? And might there be a way to activate the vibration via phyphox?<br />
Thanks a lot!]]></description>
			<content:encoded><![CDATA[I wanted to measure the pressure in a closed metal lunch box, so WiFi did not work. I managed to create an experiment to generate a sine wave with a frequency corresponding to the air pressure, 1hPa=1Hz. With a second phone I was able do receive the sound and show the frequency=pressure over time. However, this is not very reliable, other sounds disturb the measurement. So I thought of using the vibration alarm as a signal source and a magnetometer as a receiver.<br />
Does anyone know if the vibration generates (enough of) a magnetic field for this to work? And might there be a way to activate the vibration via phyphox?<br />
Thanks a lot!]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[Light Frequency with ESP32 and Phyphox]]></title>
			<link>https://phyphox.org/forums/showthread.php?tid=2239</link>
			<pubDate>Fri, 27 Feb 2026 16:28:11 +0000</pubDate>
			<dc:creator><![CDATA[<a href="https://phyphox.org/forums/member.php?action=profile&uid=6537">Explliure</a>]]></dc:creator>
			<guid isPermaLink="false">https://phyphox.org/forums/showthread.php?tid=2239</guid>
			<description><![CDATA[<div style="text-align: justify;" class="mycode_align">I'm new to the forum, so greetings to everyone. I'm a high school teacher who has been using Phyphox and its ability to connect sensors via Bluetooth for some time, so I'm very grateful to Sebastian Staacks and his colleagues at RWTH Aachen University, and to everyone who contributes to the forum.</div>
 <br />
I'd like to share an experiment that might be of interest to students studying the altern current.<br />
With a lot of help (I don't know how to program in XML), I managed to get the code to display the brightness variations of light bulbs in Phyphox as a result of being connected to a 50 Hz altern current. The attached screenshot shows the brightness variations and how the time between 10 peaks is 0.10 s, which corresponds to a frequency of 100 Hz, as expected.<br />
 <br />
I'm using a phototransistor (for example, the TEMT6000) and an ESP32 board that sends data via Bluetooth. I've attached the sketch for the ESP32 and the XML file for uploading to Phyphox.<br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://phyphox.org/forums/images/attachtypes/phyphox.png" title="phyphox experiment configuration" border="0" alt=".phyphox" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=777" target="_blank" title="">luz_frecuencia_alta.phyphox</a> (Size: 3.36 KB / Downloads: 240)
<!-- end: postbit_attachments_attachment --><br />
<div style="text-align: justify;" class="mycode_align"> <!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://phyphox.org/forums/images/attachtypes/image.png" title="JPG Image" border="0" alt=".jpg" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=775" target="_blank" title="">Luz_frcuencia_alta_phyphox_pantalla.jpg</a> (Size: 212.71 KB / Downloads: 251)
<!-- end: postbit_attachments_attachment --><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://phyphox.org/forums/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=776" target="_blank" title="">sketch_luz_frecuencia_alta.zip</a> (Size: 2.11 KB / Downloads: 215)
<!-- end: postbit_attachments_attachment --></div>]]></description>
			<content:encoded><![CDATA[<div style="text-align: justify;" class="mycode_align">I'm new to the forum, so greetings to everyone. I'm a high school teacher who has been using Phyphox and its ability to connect sensors via Bluetooth for some time, so I'm very grateful to Sebastian Staacks and his colleagues at RWTH Aachen University, and to everyone who contributes to the forum.</div>
 <br />
I'd like to share an experiment that might be of interest to students studying the altern current.<br />
With a lot of help (I don't know how to program in XML), I managed to get the code to display the brightness variations of light bulbs in Phyphox as a result of being connected to a 50 Hz altern current. The attached screenshot shows the brightness variations and how the time between 10 peaks is 0.10 s, which corresponds to a frequency of 100 Hz, as expected.<br />
 <br />
I'm using a phototransistor (for example, the TEMT6000) and an ESP32 board that sends data via Bluetooth. I've attached the sketch for the ESP32 and the XML file for uploading to Phyphox.<br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://phyphox.org/forums/images/attachtypes/phyphox.png" title="phyphox experiment configuration" border="0" alt=".phyphox" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=777" target="_blank" title="">luz_frecuencia_alta.phyphox</a> (Size: 3.36 KB / Downloads: 240)
<!-- end: postbit_attachments_attachment --><br />
<div style="text-align: justify;" class="mycode_align"> <!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://phyphox.org/forums/images/attachtypes/image.png" title="JPG Image" border="0" alt=".jpg" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=775" target="_blank" title="">Luz_frcuencia_alta_phyphox_pantalla.jpg</a> (Size: 212.71 KB / Downloads: 251)
<!-- end: postbit_attachments_attachment --><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://phyphox.org/forums/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=776" target="_blank" title="">sketch_luz_frecuencia_alta.zip</a> (Size: 2.11 KB / Downloads: 215)
<!-- end: postbit_attachments_attachment --></div>]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[Is there an Existing Program "Jogger GPS&POLAR"]]></title>
			<link>https://phyphox.org/forums/showthread.php?tid=2236</link>
			<pubDate>Wed, 04 Feb 2026 13:06:19 +0000</pubDate>
			<dc:creator><![CDATA[<a href="https://phyphox.org/forums/member.php?action=profile&uid=6516">Gribor</a>]]></dc:creator>
			<guid isPermaLink="false">https://phyphox.org/forums/showthread.php?tid=2236</guid>
			<description><![CDATA[Hi - I am on the search of a Program for Joggers that records the heart rate from Polar H10 E85C192F and adds the Standort (GPS) data. I guess that this exists? If yes, send me the QR Code? If no, how to realize this? My XML level is poor. I did not find a basic description (for real dummies) on how to realize the first "Program"  <img src="https://phyphox.org/forums/images/smilies/smile.png" alt="Smile" title="Smile" class="smilie smilie_1" />. Thanks and let us know.]]></description>
			<content:encoded><![CDATA[Hi - I am on the search of a Program for Joggers that records the heart rate from Polar H10 E85C192F and adds the Standort (GPS) data. I guess that this exists? If yes, send me the QR Code? If no, how to realize this? My XML level is poor. I did not find a basic description (for real dummies) on how to realize the first "Program"  <img src="https://phyphox.org/forums/images/smilies/smile.png" alt="Smile" title="Smile" class="smilie smilie_1" />. Thanks and let us know.]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[Recording sound/screen capture while measuring decibel levels]]></title>
			<link>https://phyphox.org/forums/showthread.php?tid=2233</link>
			<pubDate>Sun, 01 Feb 2026 17:42:02 +0000</pubDate>
			<dc:creator><![CDATA[<a href="https://phyphox.org/forums/member.php?action=profile&uid=6510">Further</a>]]></dc:creator>
			<guid isPermaLink="false">https://phyphox.org/forums/showthread.php?tid=2233</guid>
			<description><![CDATA[Iphone built in screen recording does not include ambient sound. For now i’ve had to film the phone with another phone next to a audio level meter used to calibrate to provide sound to the readings, this is a hazzle. I would love a feature where the decibel measurement was able to record a sound file simultaneously, or even better; that a screen recording included the sounds measured. Also, in expanded view the graph could show the number reading and calibration status, even in small type.<br />
<br />
Thanx]]></description>
			<content:encoded><![CDATA[Iphone built in screen recording does not include ambient sound. For now i’ve had to film the phone with another phone next to a audio level meter used to calibrate to provide sound to the readings, this is a hazzle. I would love a feature where the decibel measurement was able to record a sound file simultaneously, or even better; that a screen recording included the sounds measured. Also, in expanded view the graph could show the number reading and calibration status, even in small type.<br />
<br />
Thanx]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[Heart rate monitor]]></title>
			<link>https://phyphox.org/forums/showthread.php?tid=2224</link>
			<pubDate>Thu, 08 Jan 2026 15:12:54 +0000</pubDate>
			<dc:creator><![CDATA[<a href="https://phyphox.org/forums/member.php?action=profile&uid=6362">dirkmayer</a>]]></dc:creator>
			<guid isPermaLink="false">https://phyphox.org/forums/showthread.php?tid=2224</guid>
			<description><![CDATA[Hi, <br />
<br />
I was wondering whether the newly integrated camera based sensors could be of use to improvise a heart rate monitor (similar to the google fit app). <br />
<br />
Is there a means to set up a custom experiment using the camera? Currently I can't find it in the list of sensors when designing a simple experiment. <br />
<br />
This would enable a data fusion of sensors, e.g. the IMU, to enhance the quality of the results.<br />
<br />
Cheers,<br />
<br />
Dirk]]></description>
			<content:encoded><![CDATA[Hi, <br />
<br />
I was wondering whether the newly integrated camera based sensors could be of use to improvise a heart rate monitor (similar to the google fit app). <br />
<br />
Is there a means to set up a custom experiment using the camera? Currently I can't find it in the list of sensors when designing a simple experiment. <br />
<br />
This would enable a data fusion of sensors, e.g. the IMU, to enhance the quality of the results.<br />
<br />
Cheers,<br />
<br />
Dirk]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[Optical tachometer?]]></title>
			<link>https://phyphox.org/forums/showthread.php?tid=2216</link>
			<pubDate>Fri, 12 Dec 2025 23:20:52 +0000</pubDate>
			<dc:creator><![CDATA[<a href="https://phyphox.org/forums/member.php?action=profile&uid=6328">Lathechuck</a>]]></dc:creator>
			<guid isPermaLink="false">https://phyphox.org/forums/showthread.php?tid=2216</guid>
			<description><![CDATA[Is it possible to use fluctuations in the light sensor to measure the rate of a flashing light, or periodically masked light source?]]></description>
			<content:encoded><![CDATA[Is it possible to use fluctuations in the light sensor to measure the rate of a flashing light, or periodically masked light source?]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[Floor navigation]]></title>
			<link>https://phyphox.org/forums/showthread.php?tid=2205</link>
			<pubDate>Tue, 02 Dec 2025 19:11:17 +0000</pubDate>
			<dc:creator><![CDATA[<a href="https://phyphox.org/forums/member.php?action=profile&uid=6311">NES088</a>]]></dc:creator>
			<guid isPermaLink="false">https://phyphox.org/forums/showthread.php?tid=2205</guid>
			<description><![CDATA[I have to race leaks sometimes, and sometimes I can see it leaking through the ceiling from the floor above, but in a large building and different floor plan, that can be difficult, it would be nice to use phone to plot a starting point (where the ceiling is leaking), and use the sensors (I assume gps?) to track movement away and back to that starting point on the x and y axis, so I can go to the floor above and navigate back to that same spot, monitoring the z axis would be a plus.]]></description>
			<content:encoded><![CDATA[I have to race leaks sometimes, and sometimes I can see it leaking through the ceiling from the floor above, but in a large building and different floor plan, that can be difficult, it would be nice to use phone to plot a starting point (where the ceiling is leaking), and use the sensors (I assume gps?) to track movement away and back to that starting point on the x and y axis, so I can go to the floor above and navigate back to that same spot, monitoring the z axis would be a plus.]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[I’ve noticed that your resources only list experiments for junior high school.]]></title>
			<link>https://phyphox.org/forums/showthread.php?tid=2204</link>
			<pubDate>Sat, 29 Nov 2025 08:46:39 +0000</pubDate>
			<dc:creator><![CDATA[<a href="https://phyphox.org/forums/member.php?action=profile&uid=5645">zzzz</a>]]></dc:creator>
			<guid isPermaLink="false">https://phyphox.org/forums/showthread.php?tid=2204</guid>
			<description><![CDATA[“Hello, I’ve noticed that your resources only list experiments for junior high school. Do you have any content available for high school physics? As a native Chinese speaker, I might have some difficulty finding certain items in the listings.” <a href="https://phyphox.org/pool-en/" target="_blank" rel="noopener" class="mycode_url">Resources Pool – phyphox 资源池 - phyphox</a>]]></description>
			<content:encoded><![CDATA[“Hello, I’ve noticed that your resources only list experiments for junior high school. Do you have any content available for high school physics? As a native Chinese speaker, I might have some difficulty finding certain items in the listings.” <a href="https://phyphox.org/pool-en/" target="_blank" rel="noopener" class="mycode_url">Resources Pool – phyphox 资源池 - phyphox</a>]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[I was wondering if it’s possible to successfully port your phyphox BLE code to the Ke]]></title>
			<link>https://phyphox.org/forums/showthread.php?tid=2193</link>
			<pubDate>Wed, 29 Oct 2025 22:55:16 +0000</pubDate>
			<dc:creator><![CDATA[<a href="https://phyphox.org/forums/member.php?action=profile&uid=5645">zzzz</a>]]></dc:creator>
			<guid isPermaLink="false">https://phyphox.org/forums/showthread.php?tid=2193</guid>
			<description><![CDATA[“To reduce costs, I’m using some less common microcontrollers (MCUs) to read data, and these MCUs must be developed using the Keil IDE. I was wondering if it’s possible to successfully port your phyphox BLE code to the Keil platform.”]]></description>
			<content:encoded><![CDATA[“To reduce costs, I’m using some less common microcontrollers (MCUs) to read data, and these MCUs must be developed using the Keil IDE. I was wondering if it’s possible to successfully port your phyphox BLE code to the Keil platform.”]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[The experiment generated by the phyphox editor fails to download to the app.]]></title>
			<link>https://phyphox.org/forums/showthread.php?tid=2185</link>
			<pubDate>Tue, 07 Oct 2025 00:37:41 +0000</pubDate>
			<dc:creator><![CDATA[<a href="https://phyphox.org/forums/member.php?action=profile&uid=5645">zzzz</a>]]></dc:creator>
			<guid isPermaLink="false">https://phyphox.org/forums/showthread.php?tid=2185</guid>
			<description><![CDATA[The experiment generated by the phyphox editor fails to download to the app. It says the app needs to be updated to the latest version, but I’m already on the latest version, 1.20. What’s going on?]]></description>
			<content:encoded><![CDATA[The experiment generated by the phyphox editor fails to download to the app. It says the app needs to be updated to the latest version, but I’m already on the latest version, 1.20. What’s going on?]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[Inclination tool - Option to display in Percent rather than degree]]></title>
			<link>https://phyphox.org/forums/showthread.php?tid=2172</link>
			<pubDate>Sun, 27 Jul 2025 20:24:51 +0000</pubDate>
			<dc:creator><![CDATA[<a href="https://phyphox.org/forums/member.php?action=profile&uid=4286">B. Douille</a>]]></dc:creator>
			<guid isPermaLink="false">https://phyphox.org/forums/showthread.php?tid=2172</guid>
			<description><![CDATA[Hello, can we add this suggestion for a future release ?<br />
<br />
In some cases people used to use percentage of a slope rather than degree. Unfortunately, the Inclination experiment only offer a live display in degree. <br />
An inclination in % is equivalent to a deviation of x meter in vertical / y meter in horizontal. For example, 45° is 100%. So far the workaround is to export in a spreadsheet and convert each values using formula =TAN(RADIANS(B2)) but it's not real-time. <br />
<div style="text-align: center;" class="mycode_align"><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://phyphox.org/forums/images/attachtypes/image.png" title="PNG Image" border="0" alt=".png" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=750" target="_blank" title="">Capture d'écran 2025-07-27 221829.png</a> (Size: 58.62 KB / Downloads: 545)
<!-- end: postbit_attachments_attachment --></div>
<br />
An option in the experiment would be helpful. Thanks in advance.]]></description>
			<content:encoded><![CDATA[Hello, can we add this suggestion for a future release ?<br />
<br />
In some cases people used to use percentage of a slope rather than degree. Unfortunately, the Inclination experiment only offer a live display in degree. <br />
An inclination in % is equivalent to a deviation of x meter in vertical / y meter in horizontal. For example, 45° is 100%. So far the workaround is to export in a spreadsheet and convert each values using formula =TAN(RADIANS(B2)) but it's not real-time. <br />
<div style="text-align: center;" class="mycode_align"><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://phyphox.org/forums/images/attachtypes/image.png" title="PNG Image" border="0" alt=".png" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=750" target="_blank" title="">Capture d'écran 2025-07-27 221829.png</a> (Size: 58.62 KB / Downloads: 545)
<!-- end: postbit_attachments_attachment --></div>
<br />
An option in the experiment would be helpful. Thanks in advance.]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[Bringing Phyphox to VR/AR Platforms]]></title>
			<link>https://phyphox.org/forums/showthread.php?tid=2158</link>
			<pubDate>Wed, 25 Jun 2025 13:18:52 +0000</pubDate>
			<dc:creator><![CDATA[<a href="https://phyphox.org/forums/member.php?action=profile&uid=6099">Bingkun</a>]]></dc:creator>
			<guid isPermaLink="false">https://phyphox.org/forums/showthread.php?tid=2158</guid>
			<description><![CDATA[Hi developers,<br />
<br />
I'm reaching out to ask if you have considered to bring this amazing app to VR platforms such as Apple Vision Pro. I have tried to install it on Vision Pro and it is possible, because Vision OS is based on iPad OS, and the apps that running on the iPad OS and also run on Vision OS. However, Access to most types of data are not available. And I have found that the APIs in Vision OS is not completely same as iPad OS.<br />
<br />
Is this something already being explored? Or are there any technical or design challenges holding back such a migration? <br />
<br />
Looking forward to hearing your thoughts!]]></description>
			<content:encoded><![CDATA[Hi developers,<br />
<br />
I'm reaching out to ask if you have considered to bring this amazing app to VR platforms such as Apple Vision Pro. I have tried to install it on Vision Pro and it is possible, because Vision OS is based on iPad OS, and the apps that running on the iPad OS and also run on Vision OS. However, Access to most types of data are not available. And I have found that the APIs in Vision OS is not completely same as iPad OS.<br />
<br />
Is this something already being explored? Or are there any technical or design challenges holding back such a migration? <br />
<br />
Looking forward to hearing your thoughts!]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[Accelerator Experiment Help]]></title>
			<link>https://phyphox.org/forums/showthread.php?tid=2149</link>
			<pubDate>Wed, 28 May 2025 21:13:42 +0000</pubDate>
			<dc:creator><![CDATA[<a href="https://phyphox.org/forums/member.php?action=profile&uid=6051">Jess2</a>]]></dc:creator>
			<guid isPermaLink="false">https://phyphox.org/forums/showthread.php?tid=2149</guid>
			<description><![CDATA[Hello, My name is Jess, I am working for a company who makes hammers. We are doing quality testing on our line, and are wanting something that accurately counts the strikes, with visible numbers.<br />
<br />
I discovered this app because of the accelerator feature. Which shows accurate spikes from each hammer strike, however does not count them.<br />
<br />
I am wondering if someone who is a frequent user of the app (and much smarter) could perhaps create the experiment I am looking for?]]></description>
			<content:encoded><![CDATA[Hello, My name is Jess, I am working for a company who makes hammers. We are doing quality testing on our line, and are wanting something that accurately counts the strikes, with visible numbers.<br />
<br />
I discovered this app because of the accelerator feature. Which shows accurate spikes from each hammer strike, however does not count them.<br />
<br />
I am wondering if someone who is a frequent user of the app (and much smarter) could perhaps create the experiment I am looking for?]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[Collaborative experiment: Magnetic inclination and declination.]]></title>
			<link>https://phyphox.org/forums/showthread.php?tid=2143</link>
			<pubDate>Thu, 08 May 2025 09:06:12 +0000</pubDate>
			<dc:creator><![CDATA[<a href="https://phyphox.org/forums/member.php?action=profile&uid=5885">jonas.persson</a>]]></dc:creator>
			<guid isPermaLink="false">https://phyphox.org/forums/showthread.php?tid=2143</guid>
			<description><![CDATA[I have tasked students with finding the magnetic inclination and declination as a project at my university. The students are not allowed to use any compasses or compass apps, as these are corrected for this effect. I hoped that someone would use the sun as a way to find the directions, the sun being in the local south around noon. Not many did that.<br />
However, the problem may be rephrased so that you use the sun and find the inclination and declination, as you need the time and the sun's position in the sky, similar to the Suntrace project using phyphox. <br />
So, using a straw or the shadow, and align the phone with the sun, then send the position and time(UTC) to a server together with the readout of the magnetometer and it will be possible to calculate the inclination/declination, from the sun's position in the sky (calculated), post it on the server and send the result to the user in phyphox. In this way, it will be possible to build a map of variations and give users local values.<br />
<br />
On paper, this seems doable, but I might have missed some issues. Is this possible, and is it worth doing, and who would be interested in collaborating?<br />
<br />
There exists a project mapping the horizontal and vertical magnetic components (<a href="https://www.ncei.noaa.gov/products/crowdmag-magnetic-data" target="_blank" rel="noopener" class="mycode_url">https://www.ncei.noaa.gov/products/crowd...netic-data</a>), but as far as I know, nothing on the inclination and declination.]]></description>
			<content:encoded><![CDATA[I have tasked students with finding the magnetic inclination and declination as a project at my university. The students are not allowed to use any compasses or compass apps, as these are corrected for this effect. I hoped that someone would use the sun as a way to find the directions, the sun being in the local south around noon. Not many did that.<br />
However, the problem may be rephrased so that you use the sun and find the inclination and declination, as you need the time and the sun's position in the sky, similar to the Suntrace project using phyphox. <br />
So, using a straw or the shadow, and align the phone with the sun, then send the position and time(UTC) to a server together with the readout of the magnetometer and it will be possible to calculate the inclination/declination, from the sun's position in the sky (calculated), post it on the server and send the result to the user in phyphox. In this way, it will be possible to build a map of variations and give users local values.<br />
<br />
On paper, this seems doable, but I might have missed some issues. Is this possible, and is it worth doing, and who would be interested in collaborating?<br />
<br />
There exists a project mapping the horizontal and vertical magnetic components (<a href="https://www.ncei.noaa.gov/products/crowdmag-magnetic-data" target="_blank" rel="noopener" class="mycode_url">https://www.ncei.noaa.gov/products/crowd...netic-data</a>), but as far as I know, nothing on the inclination and declination.]]></content:encoded>
		</item>
	</channel>
</rss>