mi mi / Mbed 2 deprecated wave_player_super_lite

Dependencies:   mbed DirectSPI FastPWM

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers main.cpp Source File

main.cpp

00001 #include "sys.h"
00002 #include "sd_card.h"
00003 #include "fat_lib.h"
00004 #include "pwm_lib.h"
00005 #include "wave_player_main.h"
00006 
00007  /* SD card pin
00008  Pin side
00009  --------------\
00010          9     = \    DAT2/NC
00011              1 ===|   CS/DAT3    [CS]
00012              2 ===|   CMD/DI     [DI]
00013              3 ===|   VSS1
00014  Bottom      4 ===|   VDD
00015  View        5 ===|   CLK        [CLK]
00016              6 ===|   VSS2
00017              7 ===|   DO/DAT0    [DO]
00018          8       =|   DAT1/IRQ
00019  -----------------
00020 
00021                                          Arduino      NUCLEO-F411       NUCLEO-F030R8
00022  Logo side
00023  -----------------
00024          8       =|   DAT1/IRQ
00025              7 ===|   DO/DAT0    [DO]     D12           D12/PA_6           D12/PA_6
00026              6 ===|   VSS2
00027  Top         5 ===|   CLK        [CLK]    D13           D13/PA_5           D13/PA_5
00028  View        4 ===|   VDD
00029              3 ===|   VSS1
00030              2 ===|   CMD/DI     [DI]     D11           D11/PA_7           D11/PA_7
00031              1 ===|   CS/DAT3    [CS]     D8            D10/PB_6           D10/PB_6
00032          9     = /    DAT2/NC
00033  --------------/
00034  */
00035 
00036 #if UART_INFO && DEVICE_SERIAL
00037 RawSerial pc(USBTX,USBRX);
00038 #endif
00039 
00040 int main() {
00041 #if UART_INFO && DEVICE_SERIAL
00042     setbuf(stdout,0);
00043     pc.baud(115200);
00044 #endif
00045     wait_us(100*1000); /* wait 100msec */
00046     pwm_init();
00047     sd_init();
00048     FAT_init();
00049     wave_player_main();
00050 }
00051 
00052 
00053 void error(const char* format, ...) { }