{"id":291,"date":"2012-10-27T10:05:29","date_gmt":"2012-10-27T10:05:29","guid":{"rendered":"http:\/\/www.jontrinder.com\/blog\/?p=291"},"modified":"2012-10-27T10:11:40","modified_gmt":"2012-10-27T10:11:40","slug":"mbed-debug-shell","status":"publish","type":"post","link":"https:\/\/www.jontrinder.com\/blog\/?p=291","title":{"rendered":"MBED Debug Shell"},"content":{"rendered":"<p>Recently I have been using an \u00a0<a href=\"http:\/\/www.mbed.org\">mbed<\/a>\u00a0micro-controllers. These are a great way to rapidly prototype micro-controller projects. \u00a0One of the great features of the boards is that they provide a serial-over-usb port that can be used to communicate with the board.<\/p>\n<p>The boards have a good range of on-board peripherals (a:d d:a,pwm,rtc, counters), and can read\/write to usb, connect to ethernet.<\/p>\n<p>One of the problems I encounter when moving to new dev tools and\u00a0micro-controllers\u00a0is the lack of\u00a0on-board\u00a0debugging. An alternative can be to hook something up to a serial port so that you can &#8220;talk&#8221; to your board, read values from variables and ports.<\/p>\n<p>When working on a new project I like to have the command shell available on the device as well as the program I am working on.<\/p>\n<p><a href=\"http:\/\/mbed.org\/users\/jont\/code\/JonsDebugTerminal\/\">http:\/\/mbed.org\/users\/jont\/code\/JonsDebugTerminal\/<\/a> uses the serial over usb port and provides a very simple command &#8220;shell&#8221;. It can be extended to support the functions you need. As it is, it allows setting of the real time clock,\u00a0interrogation\u00a0the A:D\u00a0converters\u00a0and the control a few port lines on.<\/p>\n<p>The code is not robust, or neat, or K&amp;R, \ud83d\ude42 the code has a *lot* of scope for improvement. Its old code I wrote in the 90&#8217;s for another micro.<\/p>\n<p>But its good enough to allow you to play with the board and can be help when developing a new project.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Recently I have been using an \u00a0mbed\u00a0micro-controllers. These are a great way to rapidly prototype micro-controller projects. \u00a0One of the great features of the boards is that they provide a serial-over-usb port that can be used to communicate with the &hellip; <a href=\"https:\/\/www.jontrinder.com\/blog\/?p=291\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[81,80,38,39],"tags":[18,41,40],"class_list":["post-291","post","type-post","status-publish","format-standard","hentry","category-coding","category-computing","category-mbed","category-raspberry-pi","tag-code","tag-hardware","tag-mbed-2"],"_links":{"self":[{"href":"https:\/\/www.jontrinder.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/291","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.jontrinder.com\/blog\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.jontrinder.com\/blog\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.jontrinder.com\/blog\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.jontrinder.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=291"}],"version-history":[{"count":3,"href":"https:\/\/www.jontrinder.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/291\/revisions"}],"predecessor-version":[{"id":294,"href":"https:\/\/www.jontrinder.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/291\/revisions\/294"}],"wp:attachment":[{"href":"https:\/\/www.jontrinder.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=291"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.jontrinder.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=291"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.jontrinder.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=291"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}