Sunday, May 20th 2018, 5:42pm UTC+2

You are not logged in.

  • Login
  • Register

Dear visitor, welcome to SEGGER Forum. If this is your first visit here, please read the Help. It explains how this page works. You must be registered before you can use all the page's features. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.



Date of registration: Apr 21st 2018

Posts: 1


Thursday, April 26th 2018, 12:21pm

Getting Started Embedded Studio & Nucleo STM32F103


currently I'm trying to getting started with the Nucleo board and Embedded Studio. Therefor I installed the J-Link firmware on my Nucleo board. As far as I can tell the board is recognized as J-Link. Then I wrote a small blinky program trying to set Pin PC10 as output:

Source code

void main(void)
  RCC->APB2ENR |= (1 << 4);  //IOPCEN=1
  GPIOC->CRH |= 0x500;     	   	//CONF1=0, CONF0=1, MODE1=0, MODE0=1 	
  GPIOC -> ODR |=  (1<<10);    //Set Pin PC10 high



For starting the program I hit F5.

The pin shows no action, but I can tell that the uC is running because when I set a breakpoint on the koop it get's hit.


Super Moderator

Date of registration: Jan 2nd 2017

Posts: 1,048


Thursday, May 3rd 2018, 9:54am


Thank you for your inquiry.
The source you posted does not result in a blinking LED as your while(1) is empty so there is no toggle of the LED pin.
Which eval board are you using exactly? The NUCLEO-F103RB board does not have any LED connected to PC10.
If you are using an external LED make sure you wire it correctly and use a series resistor to limit the current.

As a starting project for blinky LED we suggest using the Embedded Studio pacakge manager. Download the STM32F1xx support package.
Open Tools-> Show Installed Packages-> STMicroelectronics STM32F1xx CPU Support Package-> STM32F1xx Samples Solution

There you will find a SysTick Interrupt example project.
This example will print a message every second. Instead of printing the message you can replace the printf with the toggle of your LED pin (e.g. using XOR).
Now you should have a quick setup of a timed blinky example.

Best regards,
Please read the forum rules before posting: Forum Rules

Keep in mind, this is not a support forum. Its main purpose is user to user interaction.
Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
Should you be entitled to support contact us per e-mail.
The following contact form can be used for this: