Let $X$ be a smooth manifold, perhaps oriented if necessary. The frame bundle $\pi:P \to X$ carries a canonical trivialization of the pullback of the tangent bundle of $X$ and thus a canonical trivialization of each Stiefel-Whitney class of $TX$. I want to describe these geometrically.

The goal is to describe a $w_n$ structure as a homotopy invariant assignment of signs to framed $(n-1)$-folds such that if we twist the framing in a certain way we get a minus sign. Understanding the canonical structure is enough to understand what this twist should be.

Since there has been some confusion, let me describe the case $w_2$ in detail.

A spin structure is a cocycle on the frame bundle which assigns $-1$ to the nontrivial loop of the fiber $SO$.

Now, $\pi^*TX$ has a tautological framing over $P$, since points of $P$ are pairs $x\in X$ and a frame of $T_x X$. $\pi^*TX$ inherits a canonical spin structure via this framing. That is, given a curve on $P$ with a choice of framing of $\pi^*TX$ restricted to that curve, we can compare this framing to the tautological one which gives us a well-defined sign. This sign clearly depends only on the homotopy class of the framed curve on $P$ and we get a minus sign if we twist the framing by one unit (ie. we add a copy of the nontrivial loop in the fiber).

There is another way of describing spin structures: a spin structure is a 1-cocycle $\eta$ with $\mathbb{Z}/2$ coefficients twisted by $w_2$. We can make this concrete by picking a set-theoretic section $s:SO \to Spin$. This gives us a cocycle representative of $w_2$, and shifting $s$ applied to the transition maps of $P$ by $\eta$, which we think of as $Spin$-valued, gives us transition maps for a $Spin$ frame bundle. That is, to each curve $\gamma$ we get an SO element $T(\gamma)$ describing the transition function of the tangent bundle. Then $$ s(T(\gamma)) + \eta(\gamma) $$ is the transition function for the spin frame bundle.

This bundle is a double cover of the frame bundle, and so should be classified by a 1-cocycle reproducing the previous definition of a spin structure.

To make better sense of this, we should look again at the canonical spin structure on $\pi^*TX$.

The canonical spin structure on $\pi^*TX$ gives us a way of translating between these two descriptions. In one definition, the canonical spin structure defines a 1-cocycle on $P$ with $\mathbb{Z}/2$ coefficients twisted by $\pi^*w_2$. Call this $F$.

Let $\eta$ be a spin structure on $X$. Then $$ \alpha = \pi^*\eta - F $$ is an ordinary 1-cocycle on $P$. I claim that this is a spin structure according to the first definition as long as we can figure out what $F$ is. To show that, we just need to see that $\alpha$ assigns $-1$ to the nontrivial loop in the fiber. $\pi^*\eta$ vanishes on that loop because the loop projects to a point in $X$, so this is the same as $F$ applied to that loop. Thus, $F$ can be anything as long as it assigns $-1$ to this loop. Some more thought needs to go into a concrete definition of $F$. It's just a matter of working through the general discussion above (trivialization to spin structure) in reverse.

I want to similarly describe this canonical trivialization of $w_n$. This will be a $\mathbb{Z}/2$-valued $(n-1)$-cochain on $P$ pulled back from the tautological bundle over $BO$. Its differential is $w_n$.

I want a description that looks like: to every framed $(n-1)$-fold we assign a sign such that if we twist the framing in a certain way we get a minus sign.

For $n=3$, my conjecture is that to a framed tube, the twist looks like we take a framed ring (a slice of the framed tube) and rotate the ring around its center (think smoke rings).

Any help or references is much appreciated.

EDIT: For the more abstract, I offer the following diagram. The class $w_n$ is represented by a map $BO \to B^n\mathbb{Z}/2$. We also have the maps $X \to BO$ classifying the tangent bundle, $X \to B^n\mathbb{Z}/2$ the class $w_n(TX)$, the identity $X\to X$, the maps $\star \to BO$, $\star \to B^n\mathbb{Z}/2$, and finally $\star \to \star$. This gives a map between two diagrams, one of which has as pullback the frame bundle $P$, the other has as pullback the $B^{n-1}\mathbb{Z}/2$ bundle over $X$ sections of which are $(n-1)$-cocycles in the $w_n(TX)$-twisted cohomology of $X$. The induced map (over $X$) from $P$ to this bundle is the canonical trivialization I'm talking about.

classes, not cocycles, so what cochains are you looking for? Accidentally, what linking number are you speaking about in the case $n=2$? To define the linking number, the least you should assume that the curve bounds (or, at worst, lives in the torsion of the homology). – Alex Degtyarev Mar 18 '14 at 20:47