필터 지우기
필터 지우기

Error in 'StepperMotor_fout/PWM Generator/Carrier counter': Failed to evaluate mask initialization commands. Caused by: Operands to the logical AND (&&) and OR (||) operator

조회 수: 2 (최근 30일)
I'm building a closed loop PID controlled stepper motor for speed control in simulink. While execution the following error shows up.
"Error in 'StepperMotor_fout/PWM Generator/Carrier counter': Failed to evaluate mask initialization commands.
Caused by:
Operands to the logical AND (&&) and OR (||) operators must be convertible to logical scalar values. Use the ANY or ALL functions to reduce operands to logical scalar values."
Kindly give ur comments.
  댓글 수: 2
madhan ravi
madhan ravi 2024년 1월 5일
편집: madhan ravi 2024년 1월 5일
Without seeing your code nor the model, it’s hard to do any black magic
Walter Roberson
Walter Roberson 2024년 1월 5일
Most likely, something that is being used in mask initialization is empty instead of being a scalar.

댓글을 달려면 로그인하십시오.

답변 (1개)

Sabin
Sabin 2024년 1월 23일
The error message indicates that there is an issue with the mask initialization commands for this block, specifically involving the use of logical AND (&&) or OR (||) operators. The error suggests that the operands used with these logical operators are not scalar values, which is required for these operations.
  댓글 수: 1
madhan ravi
madhan ravi 2024년 1월 24일
편집: madhan ravi 2024년 1월 24일
+1, and if it"s a boolean vector signal using any() or all() operation should be used as suggested.

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 PID Controller Tuning에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by