monitor_01
Keyword: Monitor, RTC, Time, AnalogIn, DigitalIn, CPU informationj
Control Program
Reference
- NXP LPC1768 program ..\software\LPC1700_FatFs_Prj\Main\main.c (follow)
- http://www.nxp.com/#/pip/pip=[pip=LPC1769_68_67_66_65_64_4]|pp=[t=pip,i=LPC1769_68_67_66_65_64_4]
Function
You can see following information.
? - Help
a - Show ADC data
m - Entry Memory Mode -> Show several contents
p - Show Port status
sf - System Clock
sc - System / CPU information
t [<year> <mon> <mday> <hour> <min> <sec>]
/ [a],[p],[t] commands every 1 sec Exit =hit any key (not ENTER key)
q - Quit (back to called routine)
Hardware Configlation
Simple way:
You don't need any additional "Hardware configuration", just connect to your PC and start "USB Serial" as follow.
http://mbed.org/handbook/SerialPC
Additional configuration:
Switch input -> P24,25,26
Analog input -> P15,16,17
Software
Need to setup serial baud -> 115200BPS
Future implementation plan
1. Vector contents
2. I/O area of contents
3. UART and others Configuration
Bug or not?
Following is a function in a part of memory dump.
// Print memory contents void put_dump (const unsigned char *buff, unsigned long ofs, int cnt){ int n; // Works well #if 1 pc.printf("%08lX ", ofs); for(n = 0; n < cnt; n++){ pc.printf(" %02X", buff[n]); } pc.putc(' '); for(n = 0; n < cnt; n++) { if ((buff[n] < 0x20)||(buff[n] >= 0x7F)){ pc.putc('.'); } else { pc.putc(buff[n]); } } put_cr(); #endif // Does NOT work #if 0 printf("%08lX ", ofs); for(n = 0; n < cnt; n++){ printf(" %02X", buff[n]); } pc.putc(' '); for(n = 0; n < cnt; n++) { if ((buff[n] < 0x20)||(buff[n] >= 0x7F)){ pc.putc('.'); } else { pc.putc(buff[n]); } } pc.puts("\r\n"); #endif }
if I combined printf and pc.puts, screeen shot shows follows.
I don't know the reason but I expect that send the strings strem to USB buffer is differ way between printf and pc.puts.
"Don't mix printf & pc.puts!"
Monitor for mbed LPC1768 Ver. on May 15 2010 (23:47:15) [Help:'?' key] >m Entry Memory Mode 1) d [], 2) s, 3) , 4) m> ....!...)...+... 00000000 00 80 00 10 21 02 00 00 29 02 00 00 2B 02 00 000000001 -.../...1....r.. 0 2D 02 00 00 2F 02 00 00 31 02 00 00 FE 72 FF EF00000020 00 0 ............3... 0 00 00 00 00 00 00 00 00 00 00 33 02 00 0000000030 35 02 00 00 5.......7...9... 00 00 00 00 37 02 00 00 39 02 00 0000000040 3B 02 00 00 3B 02 ;...;...;...;... 00 00 3B 02 00 00 3B 02 00 0000000050 3B 02 00 00 3B 02 00 00 3 ;...;...;...;... B 02 00 00 3B 02 00 0000000060 3B 02 00 00 3B 02 00 00 3B 02 00 ;...;...;...;... 00 3B 02 00 0000000070 3B 02 00 00 3B 02 00 00 3B 02 00 00 3B ;...;...;...;... 02 00 0000000080 3B 02 00 00 3B 02 00 00 3B 02 00 00 3B 02 00 0 ;...;...;...;... ;...;...;...;... 000000090 3B 02 00 00 3B 02 00 00 3B 02 00 00 3B 02 00 00000000 ;...;...;...;... A0 3B 02 00 00 3B 02 00 00 3B 02 00 00 3B 02 00 00000000B0 3B ;...;...;...;... 02 00 00 3B 02 00 00 3B 02 00 00 3B 02 00 00000000C0 3B 02 00 0 ;............... 0 00 F0 02 F8 00 F0 A0 F8 0A A0 90 E8000000D0 00 0C 82 44 83 44 ...D.D.....E.... AA F1 01 07 DA 45 01 D1 00 F0000000E0 95 F8 AF F2 09 0E BA E8 ................ 0F 00 13 F0 01 0F 18 BF000000F0 FB 1A 43 F0 01 03 18 47 F8 83 0 ..C....G........ m>0 00 18 84 00 00M
Revision
May 15th, 2010 10:51PM (Japan local time) Create this page
May 16th, 2010 Add Bug issue, change screen shot ( Thanks Igor! )
2 comments
You need to log in to post a comment
Nice!
One recommendation: use GIF or PNG for the screenshots, text looks very bad in JPG.