  In data gathering applications which is a typical application paradigm in
wireless sensor networks, sensor nodes may have different traffic demands.
Assigning equal channel access to each node may lead to congestion, inefficient
use of the bandwidth and decrease of the application performance. In this
paper, we prove that the time slot assignment problem is NP-complete when p-hop
nodes are not assigned the same slot, with 1 <= p <= h for any strictly
positive integer h. We propose TRASA, a TRaffic Aware time Slot Assignment
algorithm able to allocate slots to sensors proportionally to their demand. We
evaluate the performance of TRASA for different heuristics and prove that it
provides an optimized spatial reuse and a minimized cycle length.
