Lazar Dobric
/
7seg-multiplex
gas
main.cpp
- Committer:
- makotolagano
- Date:
- 2021-11-05
- Revision:
- 0:6355912eb7b8
File content as of revision 0:6355912eb7b8:
#include "mbed.h" #define A PA_10 #define B PA_9 #define C PA_8 #define D PB_10 #define E PB_5 #define F PB_4 #define G PB_3 #define SEL_1 PB_6 #define SEL_2 PC_7 //aktivna vrednost 0 const int digit[] = {0b1000000, 0b1111001, 0b0100100, 0b0110000, 0b0011001, 0b0010010, 0b0000010, 0b1111000, 0b0000000, 0b0010000, 0b1111111}; //BusOut display(A,B,C,D,E,F,G,SEL_1,SEL_2); //test //BusOut display(PA_5,PA_6,PA_7,PB_6,PA_9,PA_8,PB_10); //zolin diode zezanje int main(){ // int i = 0; // display = digit[0]; while(true){ //if(i == 9){ // i = -1; // } // display = digit[++i]; // // wait_ms(1000); } }