MMEx with SPI Slave to allow legacy devices to communicate with modern media such as USB, SD cards, the internet and all of the mbed\'s other interfaces
Dependencies: NetServices MSCUsbHost mbed TMP102 SDFileSystem
mfuncs.h
00001 /* MMEx for MBED - MBED specific command processing 00002 * Copyright (c) 2011 MK 00003 * 00004 * Permission is hereby granted, free of charge, to any person obtaining a copy 00005 * of this software and associated documentation files (the "Software"), to deal 00006 * in the Software without restriction, including without limitation the rights 00007 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 00008 * copies of the Software, and to permit persons to whom the Software is 00009 * furnished to do so, subject to the following conditions: 00010 * 00011 * The above copyright notice and this permission notice shall be included in 00012 * all copies or substantial portions of the Software. 00013 * 00014 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 00015 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 00016 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 00017 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 00018 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 00019 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 00020 * THE SOFTWARE. 00021 */ 00022 00023 /** 00024 \file mfuncs.h 00025 \brief Commands starting with M for MBED features 00026 */ 00027 00028 #ifndef MFUNCS_H 00029 #define MFUNCS_H 00030 00031 #include "mmex.h" 00032 00033 // definition of the M-functions 00034 #define mled 'L' // control LED's 00035 #define mversion 'V' // get version string 00036 #define mwelcome 'W' // get welcome string 00037 #define mstatus 'S' // get MMex status 00038 #define mdebug 'D' // control DEBUG level 00039 #define merror 'E' // get latest error message 00040 #define mbaud 'B' // set console baud rate 00041 #define mcase 'C' // set case of text output 00042 #define mtime 'T' // set/get mbed RTC value 00043 #define mreset 'R' // MBed warm restart 00044 00045 #define ledon '1' // value for LED ON 00046 #define ledoff '0' // value for LED ON 00047 #define ledtog 'T' // value for LED toggle 00048 #define ledread 'R' // value for LED read 00049 00050 #define ucase 'U' // value for Upper Case 00051 #define nocase 'N' // value for no change to case 00052 00053 void parse_M(); 00054 void do_mled(); 00055 void do_mversion(); 00056 void do_mwelcome(); 00057 void do_mstatus(); 00058 void do_mdebug(); 00059 void do_merror(); 00060 void do_mreset(); 00061 void do_mbaud(); 00062 void do_mcase(); 00063 void do_mtime(); 00064 void do_mdefault(); 00065 00066 #endif
Generated on Tue Jul 12 2022 21:35:26 by 1.7.2