5. In Rt $\triangle A B C$, $\angle A C B=90^{\circ}, C A=$ $3, C B=4$, a moving point $P$ is inside $\triangle A B C$, and the sum of its distances to the three sides is $\frac{13}{5}$. Then the length of the trajectory of point $P$ is
5. $\frac{\sqrt{5}}{2}$.

As shown in Figure 4, place the right triangle $\triangle ABC$ in the Cartesian coordinate system, where $A(3,0), B(0,4)$.
Figure 4
Let the point $P(x, y)$ satisfy the condition. Then,
$$
x+y+\frac{|4 x+3 y-12|}{5}=\frac{13}{5} \text{. }
$$

Since point $P$ is inside $\triangle ABC$, we have,
$$
4 x+3 y-12<0 \text{. }
$$

Therefore, the equation of the locus of point $P$ is
$$
x+2 y-1=0 \text{. }
$$

Let it intersect the $x$-axis at point $D(1,0)$, and the $y$-axis at point $E\left(0, \frac{1}{2}\right)$.
By the Pythagorean theorem, we know $DE=\frac{\sqrt{5}}{2}$.