Proportional-Integral-Derivative (PID) control is the most common method applied in the industry due to its simplicity. On the other hand, due to its difficulties, parameter tuning of the PID controllers are usually performed poorly. Generally, the design objectives are obtained by adjusting the controller parameters repetitively until the desired closed-loop system performance is achieved. This allows researchers to use more advanced and even some heuristic methods to achieve the optimal PID parameters. This paper focuses on application of the chaos embedded particle swarm optimization algorithm (CPSO) for PID controller tuning, and demonstrates how to employ the CPSO method to find optimal PID parameters in details. The method is applied to optimal PID parameter tuning for three typical systems with various ordered, and comparisons with the conventional PSO and the Ziegler-Nichols methods are performed. The numerical results from the simulations verify the performance of the proposed scheme.