Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
main.cpp
- Committer:
- Alexandre
- Date:
- 2010-11-26
- Revision:
- 0:bd5887ade04e
File content as of revision 0:bd5887ade04e:
//==============================================================
// Programa para testes mbed
//==============================================================
//
// Data: 24/10/2010
// Programador: Alexandre Andrade Souza
//
//==============================================================
#include "mbed.h"
//Definição dos pinos de saída
DigitalOut led(LED1);
DigitalOut led1(LED2);
DigitalOut led2(LED3);
DigitalOut led3(LED4);
///////////////////////////////////////////////////////////////////////////////////
//
// Nome: int main(void)
//
// Descrição: Função Principal (Entry Point)
//
// Parâmetros: void
//
// Retorno: int (-1 Execution Fail - 0 or 1 Execution mode)
//
// Programador: Alexandre Andrade Souza
//
// Data: 24/11/2010
//
//=================================================================================
// REVISÃO DESCRIÇÃO DATA RESPONSÁVEL
//_________________________________________________________________________________
//
// 00 Criação 24/11/201 AAS
//
///////////////////////////////////////////////////////////////////////////////////
int main(void)
{
//Loop Principal
while(1)
{
led = 1; //Saída = 1
wait(0.5); //Aguarda 1/2 segundo
led1 = 1; //Saída = 1
wait(0.5); //Aguarda 1/2 segundo
led2 = 1; //Saída = 1
wait(0.5); //Aguarda 1/2 segundo
led3 = 1; //Saída = 1
wait(0.5); //Aguarda 1/2 segundo
led3 = 0; //Saída = 1
wait(0.5); //Aguarda 1/2 segundo
led2 = 0; //Saída = 0
wait(0.5); //Aguarda 1/2 segundo
led1 = 0; //Saída = 0
wait(0.5); //Aguarda 1/2 segundo
led = 0; //Saída = 0
wait(2); //Aguarda 1/2 segundo
}
}