![](/media/cache/profiles/0f0ee3310223fe38a989b2c818709393.50x50_q85.jpg)
Generate up to 8 different digital waeforms from serial port
jmCommands.c@0:374d47623fab, 2011-02-12 (annotated)
- Committer:
- jm
- Date:
- Sat Feb 12 16:41:07 2011 +0000
- Revision:
- 0:374d47623fab
jmPulse Command Line Interface Module
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
jm | 0:374d47623fab | 1 | /** @file jmCommands.c |
jm | 0:374d47623fab | 2 | * Auto Generated by jmCLIG |
jm | 0:374d47623fab | 3 | * Saturday, February 12, 2011 10:43 AM |
jm | 0:374d47623fab | 4 | * @version 2011.01.05 |
jm | 0:374d47623fab | 5 | */ |
jm | 0:374d47623fab | 6 | |
jm | 0:374d47623fab | 7 | #include "main.h" |
jm | 0:374d47623fab | 8 | #include "jmCommands.h" |
jm | 0:374d47623fab | 9 | #include "jmMessages.h" |
jm | 0:374d47623fab | 10 | #include "jmRingBuffer.h" |
jm | 0:374d47623fab | 11 | #include "jmPulse.h" |
jm | 0:374d47623fab | 12 | |
jm | 0:374d47623fab | 13 | const char jmCLIG[] = {"\njmCLIG Version 2011.01.05 \nInstance Saturday, February 12, 2011 10:43 AM\n"}; |
jm | 0:374d47623fab | 14 | |
jm | 0:374d47623fab | 15 | // Command Name Table |
jm | 0:374d47623fab | 16 | const char cmdNames[]= |
jm | 0:374d47623fab | 17 | { |
jm | 0:374d47623fab | 18 | 'l','i','s','t',0, |
jm | 0:374d47623fab | 19 | 'v','e','r',0, |
jm | 0:374d47623fab | 20 | 'h','e','l','p',0, |
jm | 0:374d47623fab | 21 | 'f','e','e','d','b','a','c','k',0, |
jm | 0:374d47623fab | 22 | 'e','c','h','o',0, |
jm | 0:374d47623fab | 23 | 'p','u','l','s','e',0, |
jm | 0:374d47623fab | 24 | 'p','u','l','s','e','I','n','i','t',0, |
jm | 0:374d47623fab | 25 | 'p','u','l','s','e','S','t','o','p',0, |
jm | 0:374d47623fab | 26 | 'G','P','P','P','0',0, |
jm | 0:374d47623fab | 27 | 'i','n','i','t',0, |
jm | 0:374d47623fab | 28 | 0 |
jm | 0:374d47623fab | 29 | }; |
jm | 0:374d47623fab | 30 | |
jm | 0:374d47623fab | 31 | // Section Definitions |
jm | 0:374d47623fab | 32 | #define list 0 |
jm | 0:374d47623fab | 33 | #define ver 1 |
jm | 0:374d47623fab | 34 | #define help 2 |
jm | 0:374d47623fab | 35 | #define feedback 3 |
jm | 0:374d47623fab | 36 | #define echo 4 |
jm | 0:374d47623fab | 37 | #define pulse 5 |
jm | 0:374d47623fab | 38 | #define pulseInit 6 |
jm | 0:374d47623fab | 39 | #define pulseStop 7 |
jm | 0:374d47623fab | 40 | #define GPPP0 8 |
jm | 0:374d47623fab | 41 | #define init 9 |
jm | 0:374d47623fab | 42 | |
jm | 0:374d47623fab | 43 | |
jm | 0:374d47623fab | 44 | /*********************************************************************** |
jm | 0:374d47623fab | 45 | * @brief Command steering |
jm | 0:374d47623fab | 46 | * Command Associated with Command Number is Executed |
jm | 0:374d47623fab | 47 | * @param[in] cmdNum Command Number |
jm | 0:374d47623fab | 48 | * @return none |
jm | 0:374d47623fab | 49 | **********************************************************************/ |
jm | 0:374d47623fab | 50 | void Action(int cmdNum){ |
jm | 0:374d47623fab | 51 | switch(cmdNum){ |
jm | 0:374d47623fab | 52 | case list : cli_list(); |
jm | 0:374d47623fab | 53 | break; |
jm | 0:374d47623fab | 54 | case ver : cli_version(); |
jm | 0:374d47623fab | 55 | break; |
jm | 0:374d47623fab | 56 | case help : cli_help(); |
jm | 0:374d47623fab | 57 | break; |
jm | 0:374d47623fab | 58 | case feedback : cli_feedback(); |
jm | 0:374d47623fab | 59 | break; |
jm | 0:374d47623fab | 60 | case echo : cli_echo(); |
jm | 0:374d47623fab | 61 | break; |
jm | 0:374d47623fab | 62 | case pulse : cli_Pulse(); |
jm | 0:374d47623fab | 63 | break; |
jm | 0:374d47623fab | 64 | case pulseInit : PulseInit(); |
jm | 0:374d47623fab | 65 | break; |
jm | 0:374d47623fab | 66 | case pulseStop : cli_PulseStop(); |
jm | 0:374d47623fab | 67 | break; |
jm | 0:374d47623fab | 68 | case GPPP0 : cli_GPPP0(); |
jm | 0:374d47623fab | 69 | break; |
jm | 0:374d47623fab | 70 | case init : Inits(); |
jm | 0:374d47623fab | 71 | break; |
jm | 0:374d47623fab | 72 | default : UnknownCommand(); |
jm | 0:374d47623fab | 73 | NextCommand(nl,pLine); |
jm | 0:374d47623fab | 74 | } |
jm | 0:374d47623fab | 75 | } |
jm | 0:374d47623fab | 76 |