{"id":2238,"date":"2008-06-20T10:12:06","date_gmt":"2008-06-20T15:12:06","guid":{"rendered":"https:\/\/blogs.mathworks.com\/pick\/2008\/06\/20\/alarm-clocks-with-snooze-buttons\/"},"modified":"2016-05-11T10:25:02","modified_gmt":"2016-05-11T14:25:02","slug":"alarm-clocks-with-snooze-buttons","status":"publish","type":"post","link":"https:\/\/blogs.mathworks.com\/pick\/2008\/06\/20\/alarm-clocks-with-snooze-buttons\/","title":{"rendered":"Alarm Clock(s) with Snooze Buttons"},"content":{"rendered":"<div class=\"content\">\r\n<h1>Never miss another appointment!<\/h1>\r\nHow cool! I'm sitting at my desk working, knowing that I have a call in 45 minutes. I can put a reminder in Outlook, of course,\r\nbut I tend to get so many Outlook reminders that they become noise.\r\n\r\nNow I can easily set a reminder from within MATLAB, using Matt Fig's <a title=\"https:\/\/www.mathworks.com\/matlabcentral\/fileexchange\/loadFile.do?objectId=9352&amp;objectType=FILE (link no longer works)\">REMINDME<\/a> utility. And let's face it--I'm a MATLAB geek who would rather see this implemented in MATLAB anyway. REMINDME is trivially\r\neasy to use, and is Brett's selection for this week's Pick of the Week. Just set a time and a reminder message (or use the default 'this is your reminder'),\r\nand continue working. At the specified time, a dialog box will pop up, prompting me to acknowledge the alarm and turn it off\r\nor hit a 10-minute snooze button:\r\n<pre style=\"background: #F9F7F3; padding: 10px; border: 1px solid #c8c8c8;\">imshow(<span style=\"color: #a020f0;\">'remindmeimg.png'<\/span>)<\/pre>\r\n<img decoding=\"async\" src=\"https:\/\/blogs.mathworks.com\/images\/pick\/remindme_potw_01.png\" alt=\"\" hspace=\"5\" vspace=\"5\" \/>\r\n\r\nBy the way, our own Jiro also wrote and posted an <a title=\"https:\/\/www.mathworks.com\/matlabcentral\/fileexchange\/loadFile.do?objectId=9018&amp;objectType=file (link no longer works)\">ALARM<\/a> with more bells and whistles. Jiro's version is much more full-featured; Matt's is easier to use. Grab one or both, and never\r\nbe late again!\r\n\r\n<script>\/\/ <![CDATA[\r\nfunction grabCode_55bc6e41a2b44ab7a79ade192a4a9e6e() {\r\n        \/\/ Remember the title so we can use it in the new page\r\n        title = document.title;\r\n\r\n        \/\/ Break up these strings so that their presence\r\n        \/\/ in the Javascript doesn't mess up the search for\r\n        \/\/ the MATLAB code.\r\n        t1='55bc6e41a2b44ab7a79ade192a4a9e6e ' + '##### ' + 'SOURCE BEGIN' + ' #####';\r\n        t2='##### ' + 'SOURCE END' + ' #####' + ' 55bc6e41a2b44ab7a79ade192a4a9e6e';\r\n    \r\n        b=document.getElementsByTagName('body')[0];\r\n        i1=b.innerHTML.indexOf(t1)+t1.length;\r\n        i2=b.innerHTML.indexOf(t2);\r\n \r\n        code_string = b.innerHTML.substring(i1, i2);\r\n        code_string = code_string.replace(\/REPLACE_WITH_DASH_DASH\/g,'--');\r\n\r\n        \/\/ Use \/x3C\/g instead of the less-than character to avoid errors \r\n        \/\/ in the XML parser.\r\n        \/\/ Use '\\x26#60;' instead of '<' so that the XML parser\r\n        \/\/ doesn't go ahead and substitute the less-than character. \r\n        code_string = code_string.replace(\/\\x3C\/g, '\\x26#60;');\r\n\r\n        author = 'Brett Shoelson';\r\n        copyright = 'Copyright 2008 The MathWorks, Inc.';\r\n\r\n        w = window.open();\r\n        d = w.document;\r\n        d.write('\r\n\r\n<pre>\\n');\r\n        d.write(code_string);\r\n\r\n        \/\/ Add author and copyright lines at the bottom if specified.\r\n        if ((author.length > 0) || (copyright.length > 0)) {\r\n            d.writeln('');\r\n            d.writeln('%%');\r\n            if (author.length > 0) {\r\n                d.writeln('% _' + author + '_');\r\n            }\r\n            if (copyright.length > 0) {\r\n                d.writeln('% _' + copyright + '_');\r\n            }\r\n        }\r\n\r\n        d.write('<\/pre>\r\n\r\n\r\n\\n');\r\n      \r\n      d.title = title + ' (MATLAB code)';\r\n      d.close();\r\n      }\r\n\/\/ ]]><\/script>\r\n<p style=\"text-align: right; font-size: xx-small; font-weight: lighter; font-style: italic; color: gray;\">\r\n<a><span style=\"font-size: x-small; font-style: italic;\">Get\r\nthe MATLAB code\r\n<noscript>(requires JavaScript)<\/noscript><\/span><\/a>\r\n\r\nPublished with MATLAB\u00ae 7.6<\/p>\r\n\r\n<\/div>\r\n<!--\r\n55bc6e41a2b44ab7a79ade192a4a9e6e ##### SOURCE BEGIN #####\r\n%% An alarm clock, with a snooze button!\r\n% How cool! I'm sitting at my desk working, knowing that I have a call in\r\n% 45 minutes. I can put a reminder in Outlook, of course, but I tend to get so\r\n% many Outlook reminders that they become noise.\r\n%\r\n% Now I can easily set a reminder from within MATLAB, using\r\n% <https:\/\/www.mathworks.com\/matlabcentral\/fileexchange\/loadAuthor.do?objectType=author&objectId=1094381 Matt Fig>'s <https:\/\/www.mathworks.com\/matlabcentral\/fileexchange\/loadFile.do?objectId=9352&objectType=FILE REMINDME> utility. And let's\r\n% face itREPLACE_WITH_DASH_DASHI'm a MATLAB geek who would rather see this implemented in\r\n% MATLAB anyway. REMINDME is trivially easy to use, and is <https:\/\/www.mathworks.com\/matlabcentral\/fileexchange\/loadAuthor.do?objectType=author&objectId=1093599 Brett>'s\r\n% selection for this week's Pick of the Week. Just set a time and a\r\n% reminder message (or use the default 'this is your reminder'), and\r\n% continue working. At the specified time, a dialog box will pop up,\r\n% prompting me to acknowledge the alarm and turn it off or hit a 10-minute\r\n% snooze button:\r\nimshow('remindmeimg.png')\r\n\r\n%%\r\n% By the way, our own\r\n% <https:\/\/www.mathworks.com\/matlabcentral\/fileexchange\/loadAuthor.do?objectId=1094142&objectType=author Jiro>\r\n% also wrote and posted an\r\n% <https:\/\/www.mathworks.com\/matlabcentral\/fileexchange\/loadFile.do?objectId=9018&objectType=file ALARM>\r\n% with more bells and whistles. Jiro's version is much more full-featured;\r\n% Matt's is easier to use. Grab one or both, and never be late again!\r\n##### SOURCE END ##### 55bc6e41a2b44ab7a79ade192a4a9e6e\r\n-->","protected":false},"excerpt":{"rendered":"<p>\r\nNever miss another appointment!\r\nHow cool! I'm sitting at my desk working, knowing that I have a call in 45 minutes. I can put a reminder in Outlook, of course,\r\nbut I tend to get so many Outlook... <a class=\"read-more\" href=\"https:\/\/blogs.mathworks.com\/pick\/2008\/06\/20\/alarm-clocks-with-snooze-buttons\/\">read more >><\/a><\/p>","protected":false},"author":34,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[16],"tags":[],"_links":{"self":[{"href":"https:\/\/blogs.mathworks.com\/pick\/wp-json\/wp\/v2\/posts\/2238"}],"collection":[{"href":"https:\/\/blogs.mathworks.com\/pick\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blogs.mathworks.com\/pick\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blogs.mathworks.com\/pick\/wp-json\/wp\/v2\/users\/34"}],"replies":[{"embeddable":true,"href":"https:\/\/blogs.mathworks.com\/pick\/wp-json\/wp\/v2\/comments?post=2238"}],"version-history":[{"count":1,"href":"https:\/\/blogs.mathworks.com\/pick\/wp-json\/wp\/v2\/posts\/2238\/revisions"}],"predecessor-version":[{"id":7155,"href":"https:\/\/blogs.mathworks.com\/pick\/wp-json\/wp\/v2\/posts\/2238\/revisions\/7155"}],"wp:attachment":[{"href":"https:\/\/blogs.mathworks.com\/pick\/wp-json\/wp\/v2\/media?parent=2238"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blogs.mathworks.com\/pick\/wp-json\/wp\/v2\/categories?post=2238"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blogs.mathworks.com\/pick\/wp-json\/wp\/v2\/tags?post=2238"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}