ELSEVIER Microelectronics Journal 28 (1997) 683--690 © 1997 Elsevier Science Limited Printed in Great Britain. All fights reserved 0026-2692/97/$17.00 PII:S0026-2692(97)00009-8 A reconfigurable counter controller for digital motion control applications Abdelkrim K. Oudjidal, Youssef I. EI-Haffaf 1 Samir Tagzout 1 I I Issameddine Hamani 2, Brahim Bouzouia 3 and Khaled Kara 3 ICDTA/Microelectronics, I28 Chemin Mohamed Gacem EI-Madania, 16075 Algiers, Algeria 2System A~rhitecture, 128 Chemin Mohamed Gacem EI-Madania, 16075 Algiers, Algeria 3C D T A Robotics, 128 Chemin Mohamed Gacem EI-Madania, 16075 Algiers, Algeria 3O tl) "'1 tl) ~tl} This paper demonstratesthat counter controllers, whatever their functional, performartce and densityrequirements,can be implementcd using the same flexible architecture. As applications, two counter controllers, a quadrature decoder for closed-loop-motion control systems and a moving- objcct counter controller, are implemcnted on Xilinx's FPGA packages. © 1997 ElsevierScience Ltd. 1. Introduction c ounter controllers (CCs) are digital inte- grated circuits specifically dedicated to elec- tromechanical applications [1, 2]. Robotics is one popular domain among many others where CCs are intensively used. They are employed to provide in real-time the exact position of a robotics arm. In fact, CCs serve as interfaces between mechanical encoders and microproces- sors (Fig. 1). The encoder continuously generates streams of pulses which are analyzed by a finite-state- machine (FSM), resulting in subsequent up/ down operations on the counter. To determine the right position, the microprocessor must perform asynchronously a read operation on the counter value. The FSM defines all the possible transitions that can cause the design to go from one state to another. It analyzes all possible operating condi- tions, and so avoids overlooked hang-up states or undesired transitions. In sum, it defines the context of every flip-flop in a design under every circumstance that might arise. Henceforth, it constitutes the intelligent part of the CC. Two functionally different CCs necessarily have two different FSMs. Another part of substantial importance is the counter. Its performance and 683