mbed-classic on Bluepill

Dependencies:   mbed-STM32F103C8T6 mbed

Fork of Testato-mbed-dev-Bluepill by Testato Testato

main.cpp

Committer:
testato
Date:
2016-09-17
Revision:
13:2bfcb5dc142a
Parent:
12:3ddf4333812e
Child:
15:db1bed031739

File content as of revision 13:2bfcb5dc142a:

#include "stm32f103c8t6.h"
#include "mbed.h"
 
 
//Serial      pc(PA_2, PA_3);
DigitalOut  myled(PC_13);
 
 
 
 
int main() 
{
    confSysClock();     //Configure system clock (72MHz HSE clock, 48MHz USB clock)

    while(1) 
    {
        // The on-board LED is connected, via a resistor, to +3.3V (not to GND). 
        // So to turn the LED on or off we have to set it to 0 or 1 respectively
        myled = 0;      // turn the LED on
        wait_ms(100);      // 200 ms
        myled = 1;      // turn the LED off
        wait_ms(100);      // 1 sec
        //pc.printf("Blink\r\n");
    }
}