Skip to main content
sav gas
Associate II
June 17, 2017
Question

STM32F030 PROGRAMMING

  • June 17, 2017
  • 2 replies
  • 1736 views
Posted on June 17, 2017 at 18:12

Hi all,

with uvision5 I'd make a project that works in debug, but when I program the flash of STM32 the adc peripheral doesn't works. I use Nucleo-64 board.

Any suggestion?

Thanks 

    This topic has been closed for replies.

    2 replies

    Tesla DeLorean
    Guru
    June 17, 2017
    Posted on June 17, 2017 at 20:34

    >>Any suggestion?

    Make sure you enable all the clocks you need, and are not reliant on ones the debugger enables. Ditto pins

    Make sure BOOT0 is low.

    Add instrumentation to your code so you can understand what's happening via USART/VCP without the debugger running.

    Tips, Buy me a coffee, or three.. PayPal VenmoUp vote any posts that you find helpful, it shows what's working..
    sav gas
    sav gasAuthor
    Associate II
    June 18, 2017
    Posted on June 18, 2017 at 12:43

    Hi Clive one,

    the clock and the Boot0 seems correct. The rest of project works, exception for ADC. I noted with oscilloscope, in debug, that there is a periodic signal outgoing from adc pin. I don't understand why. 

    Tesla DeLorean
    Guru
    June 18, 2017
    Posted on June 18, 2017 at 15:17

    >>I don't understand why. 

    Hard for me too, not seeing any code.

    Instrument your code so you have some clue about what's happening, if it is not running at all, or stuck in a loop somewhere.

    Tips, Buy me a coffee, or three.. PayPal VenmoUp vote any posts that you find helpful, it shows what's working..
    Luca Sevà
    Associate
    June 17, 2017
    Posted on June 17, 2017 at 22:50

    I suggest you (if you haven't done it yet) to use the cubeMX software to generate the 'base' code that you will modify. this will ensure that the clock needed are already setted as supposed. Othe than that tou can use the gui to configure the gpio pins that you want to use as you desire and set options like interrupts....

    You can also implement a sort of testing function that send diagnostic data that are relevant for the correct functionality of your particular project.

    I hope I've helped you.

    sav gas
    sav gasAuthor
    Associate II
    June 18, 2017
    Posted on June 18, 2017 at 17:13

    I'd made, but with no results.

    Thanks anyway.