Skip to main content
manishbaing2789
Associate III
Jul 22, 2013 9:49 AM UTC
Question

st-link for stm32f3discovery

Posted on July 22, 2013 at 11:49

Hello I am facing problem to download st-link/v2 for stm32f3 discovery for linux.plz guide me or give me some links realted to that.

    This topic has been closed for replies.

    5 replies

    crt2
    Visitor II
    Jul 22, 2013 12:39 PM UTC
    Posted on July 22, 2013 at 14:39

    What kind of problem and why would you need st-link for? If you're on linux openocd+gdb+gcc should be something to consider...

    manishbaing2789
    Associate III
    Jul 24, 2013 8:37 AM UTC
    Posted on July 24, 2013 at 10:37

    thanks for reply but now i have download it from

    https://github.com/texane/stlink

    crt2
    Visitor II
    Jul 24, 2013 8:50 AM UTC
    Posted on July 24, 2013 at 10:50

    Dont open multiple threads - you will create confusion.

    I do not think there is indication that program is halted at all. Now I wonder why would you think so, and I wonder what is in line 39 in main.c

    Maybe send ''monitor reset init'' instead of just ''monitor reset''

    manishbaing2789
    Associate III
    Jul 24, 2013 9:08 AM UTC
    Posted on July 24, 2013 at 11:08

    Sorry for Creating multiple threads.Fact is that  I am new to this forum and I didn't get how to post and post is posted correctly or not.but now I got it and I will take care of now-onwards.

    manishbaing2789
    Associate III
    Jul 24, 2013 9:18 AM UTC
    Posted on July 24, 2013 at 11:18

    I have send ''monitor reset init'' instead of  ''monitor reset'' but till same problem.

    I am trying to debug software timer using freeRTOS. main.c mentioned below .

    But I feel  that it  may not problem of any source file.beacause I have check with LED blink code also but same problem so.

    main.c

    /*! header files */

    #include ''stm32f4xx.h''

    #include ''FreeRTOS.h''

    #include ''timers.h''

    #include <math.h>

    #include <stdio.h>

    #include <stdlib.h>

    typedef void * xTimerHandle;

      /*! Timer Expirecounter   */

      long lExpireCounters = 0 ;          

       /*!  Handle to xtimerAPIs  */

       xTimerHandle xTimer;

     

      /*!

       * callback function

       *  count the number of times the

       * associated timer expires, and stop the timer once the timer has expired

       * 10 times.

       */

      void vTimerCallback( xTimerHandle pxTimer )

      {

        

          const long MaxExpiryCount = 10 ;               /*! Maximum Expiry ount */

          

     

              /*! Increment the number of times that Timer has expired. */

              lExpireCounters += 1;

     

              /*! If the timer has expired 10 times then stop it from running.*/

              if( lExpireCounters == MaxExpiryCount )

              {

              xTimerStop( pxTimer, 0 );                     /*! Timer Stop if Condition satisfied */

              }

      }

     

         int main( void )

        {

                long x=1;

    // line no 39

               /*! Create timer */

               xTimer = xTimerCreate(  ''Timer''      ,         /*! Name for timer */

                                       (100)        ,            /*! The timer period in ticks.(1 ticks = 1ms) */

                                        pdTRUE      ,         /*! The timers will auto-reload themselves when they expire. */

                                        (void *) x   ,        /*! timer a unique id */

                                        vTimerCallback        /*! callback fuction ,called when Timer get expires */

                                    );

     

               if( xTimer == NULL )

               {

                 printf(''Timer not created'');

                   /*!  The timer was not created. */

               }

               else

               {

                   /*! Start the timer. */

                   if( xTimerStart ( xTimer, 0 ) != pdPASS )

                   {

                       /* The timer could not be set into the Active state.*/

                   }

     

                  else

                   {

                      printf(''Timer start sucessfully\n'');

                   }

               }

          

            /*! Task scheduling started */    

            vTaskStartScheduler();

          

           while (1);

     }