Is it possible to have $\int_0^\infty f(x)\,dx$ convergent and $|f|=1$ everywhere? I came across a problem that asked if it is posible for a function to be Riemann integrable function in $[0,+\infty)$ but also $|f(x)|\geq 1$ for all $x\geq 0$. 
At first I thought it was imposible, but I realized that only holds for continuous functions, because they would have to be either positive or negative, and then they would have to go to 0 at infinity. 
I have an idea of what the function would have to be like, with alternating signs, but whose integral converges, but I haven't been able to find any, so I'm starting to think it is imposible. 
I would like some help finding this function, or disproving it, as I don't know many tools for working with functions without a constant sign.

Here is a more elementary example:
Let $\phi$ be a $1$-periodic function such that $\phi(x)=-1$ for $x \in [0,{1 \over 2})$ and $\phi(x) = 1$ for $x \in [{1 \over 2},1)$.
Note that for an integer $n$ and $x \in [0,1]$, we have $|\int_n^{n+x} \phi(2^kt)dt| \le {1 \over 2^{k+1}}$.
Define $f(x) = \sum_{n=0}^\infty 1_{[n,n+1)} \phi(2^nx)$.
Then $|f(x)| = 1$ for all $x\ge 0$ and
$\int_0^\infty f(x)dx = 0$ (the improper integral).
