Firmware and Software for Emulator/Controller for generic Switched Power Electronic Systems, based on Xilinx ISE tools and Lattice LM32 softcore cpu ipcore