We review and discuss the results of our granular–dynamics simulations of the time evolution of the microstructure of compact granular beds as found in pouring, in hopper filling and discharge, and in a shear cell. These systems are mainly quasi–static. However, it is also common to encounter localized ‘shear zones’ with significant velocity/voidage fluctuations and high bulk–strain gradients. These narrow–banded zones are separated from near–static regions by sharp, discontinuous changes of bulk stress and voidage. Within these bands the granular assembly undergoes a transition from the quasi–static to the inertial state, where enduring particle contacts are increasingly replaced by collisional ones. We focus on the discrete particle origins of this inhomogeneous yield/flow behaviour. We show the usefulness of analysing the local evolution in terms of relative rotation of the grains which is observed to cause rapid local bulk dilation responsible for setting off avalanches near free–surface boundaries and protracted bulk–failure planes in confined static assemblies. We also present some evidence to suggest that allowing for effective continuous particle–particle interactions could approximate observed effects attributable to particle shape and surface roughness. Wavelet analyses have been applied successfully to generate the variations in periodicity and the relative sequence of evolution of the stress, strain–rate and voidage states in avalanching granular heaps and in the wall region of axially symmetric hopper flows.