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:
- gcarmonar
- Date:
- 2014-05-09
- Revision:
- 0:5cb778376176
File content as of revision 0:5cb778376176:
#include "mbed.h"
DigitalOut F1(D13);
DigitalOut F2(D12);
DigitalOut F3(D11);
DigitalOut F4(D10);
DigitalIn A(D2);
DigitalIn B(D3);
DigitalIn C(D4);
DigitalIn D(D5);
int main() {
while(1) {
// F1 = A’+BCD + BD’
F1 = !A | B&C&D | B&!D;
// F2 = (A+B)(B’+C)(A+B+C+D)
F2 = (A|B) & (!B|C) & (A|B|C|D);
// F3 = ABCD+A’B’C’D’
F3 = A&B&C&D | !A&!B&!C&!D;
// F4 = (A’+B’+C’+D’)(A+BC)
F4 = (!A|!B|!C|!D) & (A|B&C);
}
}