Skip to main content
LBona.2
Associate II
April 22, 2020
Solved

osalThreadDelayMilliseconds not working in spc584-dis

  • April 22, 2020
  • 2 replies
  • 918 views

hi during the debug of my program with UDE it gets stuck on osalThreadDelayMilliseconds i found in the forum that the problem may be a PIT configuration problem but i don't know how to set it.

    This topic has been closed for replies.
    Best answer by Erwan YVIN

    Hello ,

    Could you send us the PIT configuration ?

    I recommend you to take SPC584Bxx_RLA PIT Test Application for Discovery as example

    Best Regards

    Erwan

    2 replies

    Erwan YVIN
    Erwan YVINBest answer
    ST Technical Moderator
    May 5, 2020

    Hello ,

    Could you send us the PIT configuration ?

    I recommend you to take SPC584Bxx_RLA PIT Test Application for Discovery as example

    Best Regards

    Erwan

    In order to give better visibility on the answered topics, please click on 'Best answer' on the reply which solved your issue or answered your question.
    LBona.2
    LBona.2Author
    Associate II
    May 6, 2020

    i didn't set any particular PIT configuration. I only wanted to put a delay for slower the execution of a function during debugging.

    #include "components.h"
    #include <math.h>
    #include <stdlib.h>
     
     
    float u_alfa = -1000; 
    float u_beta = -10; 
    float Vdc = 600; 
    float fsw = 17000; 
    char gates[6]; 
     
    void spaceVectorMod(float u_alfa,float u_beta, float Vdc, float fsw, char * gates, float tzero);
     
    int main(void) {
     
     /* Initialization of all the imported components in the order specified in
     the application wizard. The function is generated automatically.*/
    	componentsInit();
    	float tzero=0;
    	
     
    	while(true){
    		spaceVectorMod(u_alfa, u_beta, Vdc, fsw, gates, tzero);
    		osalThreadDelayMilliseconds(300);
    	}
    }