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.
Dependencies: ST7032 QEI PS4Serial
Dependents: 2021Arobo_UMAPYOI 2021Arobo_YUMIPYOI
board.h
00001 #include "SB1602E.h" 00002 //#include "QEI.h" 00003 #include "PS4Serial.h" 00004 #include "cerica2.h" 00005 00006 const PinName GPIO[13] = { 00007 PC_9, 00008 PA_5, 00009 PA_6, 00010 PA_7, 00011 PB_6, 00012 PC_7, 00013 PA_8, 00014 PB_10, 00015 PB_13, 00016 PB_14, 00017 PB_15, 00018 PB_1, 00019 PB_2 00020 }; 00021 00022 00023 QEI Enc[2] = {QEI(PC_6, PC_5, PC_8, 360), QEI(PA_11, PB_12, PA_12, 360)}; 00024 I2C i2c(PB_9,PB_8); 00025 SB1602E lcd(i2c,"CERICA2 Hello!"); 00026 PS4Serial PS4(PA_9,PA_10); 00027 CERICA cerica(&i2c,TweLite); 00028 00029 00030 00031 DigitalOut LED[5] = { 00032 PA_15, PB_7, PC_13, PC_2, PC_3 00033 }; 00034 00035 /*DigitalIn SW[4] = { 00036 PC_0, PC_1, PB_0, PA_4 00037 };*/ 00038 DigitalIn SW1(PC_0); 00039 DigitalIn SW2(PC_1); 00040 DigitalIn SW3(PB_0); 00041 DigitalIn SW4(PA_4); 00042 00043 //DigitalOut dReset(PC_12); 00044 00045 //DigitalOut DevRst(PC_12); 00046 00047 void boardInit() 00048 { 00049 printf("Board Initializing...\r"), fflush(stdout); 00050 //for (int i = 0; i < 4; i++) SW[i].mode(PullUp); 00051 SW1.mode(PullUp); 00052 SW2.mode(PullUp); 00053 SW3.mode(PullUp); 00054 SW4.mode(PullUp); 00055 for (int i = 0; i < 5; i++) LED[i] = 1; 00056 //dReset = 1; 00057 wait(0.5); 00058 for (int i = 0; i < 5; i++) LED[i] = 0; 00059 //dReset = 0; 00060 printf("Board Initialized ! \r\n"); 00061 }
Generated on Wed Aug 24 2022 02:04:51 by
1.7.2