The Soma puzzle consists of seven pieces, each formed by combining three or four unit cubes. Given an object obtained by combining Soma pieces, the aim is to find out the placement and orientation of the pieces. In this paper, we propose a Boltzmann machine to solve Soma puzzles and its variations with the sets of pieces known as Tricubes, Diabolical and Mikusinski pieces. We have simulated the proposed machine and obtained quite satisfactory results. The Soma puzzle has similarities with NP-complete packing problems that have real industrial applications.