080_LED_SOS_UP_Strukturen_UserButton_PWM

main.cpp

Committer:
itbusch
Date:
2022-01-31
Revision:
0:ebd8e92b9d80
Child:
1:2d785f9b9879

File content as of revision 0:ebd8e92b9d80:

/* mbed BuschA
 */

#include "mbed.h"

AnalogOut Boardled(LED1);           //PWM!
DigitalIn CableSwitch(D2); //PullUp auf Board, PA_10

int main()
{

    while (1) 
    {
    if (CableSwitch == false)
        {
        Boardled = 8;
        }
    else
        {
        Boardled = 255;
        }
    }
}