A 4bit counter that goes up and down
Here's the state transitions:

$$\begin{array}{c|c|c|c|c}
\text{State} &amp; \text{U=1 Next} &amp; \text{U=1 Excite} &amp; \text{U=0 Next} &amp; \text{U=0 Excite}\\\\
  {\begin{smallmatrix}\begin{array}{cccc}
  Q_D &amp; Q_C &amp; Q_B &amp; Q_A\\\\
  0&amp;0&amp;0&amp;0\\
  0&amp;0&amp;1&amp;1\\
  0&amp;1&amp;1&amp;0\\
  1&amp;0&amp;0&amp;1\\
  1&amp;1&amp;0&amp;0\\
  1&amp;1&amp;1&amp;1\\\\
  0&amp;0&amp;0&amp;1\\
  0&amp;0&amp;1&amp;0\\
  0&amp;1&amp;0&amp;0\\
  0&amp;1&amp;0&amp;1\\
  0&amp;1&amp;1&amp;1\\
  1&amp;0&amp;0&amp;0\\
  1&amp;0&amp;1&amp;0\\
  1&amp;0&amp;1&amp;1\\
  1&amp;1&amp;0&amp;1\\
  1&amp;1&amp;1&amp;0\\
  \end{array}\end{smallmatrix}} &amp;
  {\begin{smallmatrix}\begin{array}{cccc}
  Q_D &amp; Q_C &amp; Q_B &amp; Q_A\\\\
  0&amp;0&amp;1&amp;1\\
  0&amp;1&amp;1&amp;0\\
  1&amp;0&amp;0&amp;1\\
  1&amp;1&amp;0&amp;0\\
  1&amp;1&amp;1&amp;1\\
  0&amp;0&amp;0&amp;0\\\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  \end{array}\end{smallmatrix}} &amp;
  {\begin{smallmatrix}\begin{array}{cccc}
  T_D &amp; T_C &amp; T_B &amp; T_A\\\\
  0&amp;0&amp;1&amp;1\\
  0&amp;1&amp;0&amp;1\\
  1&amp;1&amp;1&amp;1\\
  0&amp;1&amp;0&amp;1\\
  0&amp;0&amp;1&amp;1\\
  1&amp;1&amp;1&amp;1\\\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  \end{array}\end{smallmatrix}} &amp;
  {\begin{smallmatrix}\begin{array}{cccc}
  Q_D &amp; Q_C &amp; Q_B &amp; Q_A\\\\
  1&amp;1&amp;1&amp;1\\
  0&amp;0&amp;0&amp;0\\
  0&amp;0&amp;1&amp;1\\
  0&amp;1&amp;1&amp;0\\
  1&amp;0&amp;0&amp;1\\
  1&amp;1&amp;0&amp;0\\\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  \end{array}\end{smallmatrix}} &amp;
  {\begin{smallmatrix}\begin{array}{cccc}
  T_D &amp; T_C &amp; T_B &amp; T_A\\\\
  1&amp;1&amp;1&amp;1\\
  0&amp;0&amp;1&amp;1\\
  0&amp;1&amp;0&amp;1\\
  1&amp;1&amp;1&amp;1\\
  0&amp;1&amp;0&amp;1\\
  0&amp;0&amp;1&amp;1\\\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  x&amp;x&amp;x&amp;x\\
  \end{array}\end{smallmatrix}}
\end{array}$$



Once you have that much, all you need to do is to lay out four K-map tables for each condition of \$U\$.

For \$U=1\$ (count up):

$$\begin{array}{rl}
\begin{smallmatrix}\begin{array}{r|cccc}
T_D&amp;\overline{Q_B}\:\overline{Q_A}&amp;\overline{Q_B}\: Q_A&amp;Q_B \:Q_A&amp;Q_B \:\overline{Q_A}\\
\hline
\overline{Q_D}\:\overline{Q_C}&amp;0&amp;x&amp;0&amp;x\\
\overline{Q_D}\:Q_C&amp;x&amp;x&amp;x&amp;1\\
Q_D\: Q_C&amp;0&amp;x&amp;1&amp;x\\
Q_D\:\overline{Q_C}&amp;x&amp;0&amp;x&amp;x
\end{array}\end{smallmatrix}
&amp;
\begin{smallmatrix}\begin{array}{r|cccc}
T_C&amp;\overline{Q_B}\:\overline{Q_A}&amp;\overline{Q_B}\: Q_A&amp;Q_B \:Q_A&amp;Q_B \:\overline{Q_A}\\
\hline
\overline{Q_D}\:\overline{Q_C}&amp;0&amp;x&amp;1&amp;x\\
\overline{Q_D}\:Q_C&amp;x&amp;x&amp;x&amp;1\\
Q_D\: Q_C&amp;0&amp;x&amp;1&amp;x\\
Q_D\:\overline{Q_C}&amp;x&amp;1&amp;x&amp;x
\end{array}\end{smallmatrix}\\\\
\begin{smallmatrix}\begin{array}{r|cccc}
T_B&amp;\overline{Q_B}\:\overline{Q_A}&amp;\overline{Q_B}\: Q_A&amp;Q_B \:Q_A&amp;Q_B \:\overline{Q_A}\\
\hline
\overline{Q_D}\:\overline{Q_C}&amp;1&amp;x&amp;0&amp;x\\
\overline{Q_D}\:Q_C&amp;x&amp;x&amp;x&amp;1\\
Q_D\: Q_C&amp;1&amp;x&amp;1&amp;x\\
Q_D\:\overline{Q_C}&amp;x&amp;0&amp;x&amp;x
\end{array}\end{smallmatrix}
&amp;
\begin{smallmatrix}\begin{array}{r|cccc}
T_A&amp;\overline{Q_B}\:\overline{Q_A}&amp;\overline{Q_B}\: Q_A&amp;Q_B \:Q_A&amp;Q_B \:\overline{Q_A}\\
\hline
\overline{Q_D}\:\overline{Q_C}&amp;1&amp;x&amp;1&amp;x\\
\overline{Q_D}\:Q_C&amp;x&amp;x&amp;x&amp;1\\
Q_D\: Q_C&amp;1&amp;x&amp;1&amp;x\\
Q_D\:\overline{Q_C}&amp;x&amp;1&amp;x&amp;x
\end{array}\end{smallmatrix}
\end{array}$$

For \$U=0\$ (count down):

$$\begin{array}{rl}
\begin{smallmatrix}\begin{array}{r|cccc}
T_D&amp;\overline{Q_B}\:\overline{Q_A}&amp;\overline{Q_B}\: Q_A&amp;Q_B \:Q_A&amp;Q_B \:\overline{Q_A}\\
\hline
\overline{Q_D}\:\overline{Q_C}&amp;1&amp;x&amp;0&amp;x\\
\overline{Q_D}\:Q_C&amp;x&amp;x&amp;x&amp;0\\
Q_D\: Q_C&amp;0&amp;x&amp;0&amp;x\\
Q_D\:\overline{Q_C}&amp;x&amp;1&amp;x&amp;x
\end{array}\end{smallmatrix}
&amp;
\begin{smallmatrix}\begin{array}{r|cccc}
T_C&amp;\overline{Q_B}\:\overline{Q_A}&amp;\overline{Q_B}\: Q_A&amp;Q_B \:Q_A&amp;Q_B \:\overline{Q_A}\\
\hline
\overline{Q_D}\:\overline{Q_C}&amp;1&amp;x&amp;0&amp;x\\
\overline{Q_D}\:Q_C&amp;x&amp;x&amp;x&amp;1\\
Q_D\: Q_C&amp;1&amp;x&amp;0&amp;x\\
Q_D\:\overline{Q_C}&amp;x&amp;1&amp;x&amp;x
\end{array}\end{smallmatrix}\\\\
\begin{smallmatrix}\begin{array}{r|cccc}
T_B&amp;\overline{Q_B}\:\overline{Q_A}&amp;\overline{Q_B}\: Q_A&amp;Q_B \:Q_A&amp;Q_B \:\overline{Q_A}\\
\hline
\overline{Q_D}\:\overline{Q_C}&amp;1&amp;x&amp;1&amp;x\\
\overline{Q_D}\:Q_C&amp;x&amp;x&amp;x&amp;0\\
Q_D\: Q_C&amp;0&amp;x&amp;1&amp;x\\
Q_D\:\overline{Q_C}&amp;x&amp;1&amp;x&amp;x
\end{array}\end{smallmatrix}
&amp;
\begin{smallmatrix}\begin{array}{r|cccc}
T_A&amp;\overline{Q_B}\:\overline{Q_A}&amp;\overline{Q_B}\: Q_A&amp;Q_B \:Q_A&amp;Q_B \:\overline{Q_A}\\
\hline
\overline{Q_D}\:\overline{Q_C}&amp;1&amp;x&amp;1&amp;x\\
\overline{Q_D}\:Q_C&amp;x&amp;x&amp;x&amp;1\\
Q_D\: Q_C&amp;1&amp;x&amp;1&amp;x\\
Q_D\:\overline{Q_C}&amp;x&amp;1&amp;x&amp;x
\end{array}\end{smallmatrix}
\end{array}$$

You can now use those tables (fixed for errors I made above that you may catch) to develop the logic required. 



From the above, I find:

$$\begin{align*}
T_D &amp;= U\cdot Q_B\cdot Q_C  + \overline{U}\cdot \overline{Q_B}\cdot \overline{Q_C}\\
T_C &amp;= U\cdot Q_B  + \overline{U}\cdot \overline{Q_A} + Q_A\cdot \overline{Q_B} \\
T_B &amp;= U\cdot \overline{Q_A} + \overline{U}\cdot \overline{Q_C}  + Q_A\cdot Q_C \\
T_A &amp;= 1
\end{align*}$$



At this point, you should be able to easily develop the logic required when using T-type FF devices.