Quantcast
Channel: Microcontrollers
Viewing all articles
Browse latest Browse all 230763

Forum Post: CCS/TMS320F28379D: drv8301

$
0
0
Part Number: TMS320F28379D Tool/software: Code Composer Studio I am working with mono_servo motor control example which is available in control suite,some of the code is not very clear. Thanks for helping explain them void InitMotor1_DRV_Gpio(void) { // Configure as Output : Motor 1 - EN-GATE GPIO_WritePin(MOTOR1_EN_GATE_GPIO, 0); // Disable EN_GATE GPIO_SetupPinOptions(MOTOR1_EN_GATE_GPIO, GPIO_OUTPUT, GPIO_ASYNC); GPIO_SetupPinMux(MOTOR1_EN_GATE_GPIO, 0, MOTOR1_EN_GATE_MUX); #if (DRV_MOTOR1 == DRV8301 ) // Configure as Output : Motor 1 - DC-CAL for DRV8301 GPIO_WritePin(MOTOR1_DC_CAL_GPIO, 1); // Set DC-CAL to 1 to disable amplifiers GPIO_SetupPinOptions(MOTOR1_DC_CAL_GPIO, GPIO_OUTPUT, GPIO_ASYNC); GPIO_SetupPinMux(MOTOR1_DC_CAL_GPIO, 0, MOTOR1_DC_CAL_MUX); #else // Configure as Output : Motor 1 - WAKE for DRV8305 GPIO_WritePin(MOTOR1_WAKE_GPIO, 0); // Set WAKE to 0 (default state) GPIO_SetupPinOptions(MOTOR1_WAKE_GPIO, GPIO_OUTPUT, GPIO_ASYNC); GPIO_SetupPinMux(MOTOR1_WAKE_GPIO, 0, MOTOR1_WAKE_MUX); #endif } why disable the EN_GATE and Set DC-CAL to 1 to disable amplifiers?

Viewing all articles
Browse latest Browse all 230763

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>