Movement is one of the essential characteristics of living beings. Despite the diversity of animal species and the apparent differences, standard features exist between their movement systems that follow a particular pattern. The movements can mainly be divided into discrete and rhythmic categories controlled by the central nervous system. Scientists usually consider these two types of motion separately in the control system and use different methods and resources to produce and model them. Proposing a unified and comprehensive model for generating and controlling rhythmic and discrete movement with the same control system is more valuable, albeit challenging. The present study provides a single neuromechanical control model for producing and controlling rhythmic and discrete movements. This model consists of a neural oscillator, the central pattern generator (CPG), coupled with inhibitory and excitatory paths to drive the flexor and extensor muscles. The computational model of this study follows the Hodgkin-Huxley (HH) equations. The structure of the model, the factors involved in creating the motion, and the oscillation were analyzed in great detail. It was found that supraspinal input and motor neuron feedback, as the motor control parameters, play an essential role in the activity and directly impact the production and control of rhythmic and discrete movements. According to these parameters, a neuromechanical model that can create both rhythmic and discrete movement is presented. The model also addresses the switching mechanism between rhythmic and discrete states.