  We consider the problem of existence of perfect $2$-colorings (equitable
$2$-partitions) of Hamming graphs with given parameters. We start with
conditions on parameters of graphs and colorings that are necessary for their
existence. Next we observe known constructions of perfect colorings and propose
some new ones giving new parameters. At last, we deduce which parameters of
colorings are covered by these constructions and give tables of admissible
parameters of $2$-colorings in Hamming graphs $H(n,q)$ for small $n$ and $q$.
Using the connection with perfect colorings, we construct an orthogonal array
OA(2048,7,4,5).
