<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://devzone.nordicsemi.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>PPK cancelling &amp;#39;start logging&amp;#39;</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/23762/ppk-cancelling-start-logging</link><description>Hi.
Great that you have added logging capability to the PPK desktop app. This was exactly what I needed. 
 I noticed one minor issue with the logging: When starting logging, it asks for a file to save the log to. If you cancel this dialog, it will still</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 01 Aug 2017 07:21:18 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/23762/ppk-cancelling-start-logging" /><item><title>RE: PPK cancelling 'start logging'</title><link>https://devzone.nordicsemi.com/thread/93468?ContentTypeID=1</link><pubDate>Tue, 01 Aug 2017 07:21:18 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:82c5d3f5-0ea9-4c6f-8d81-074fcd7e31f2</guid><dc:creator>wlgrd</dc:creator><description>&lt;p&gt;Hi, good to hear it is coming to good use, and thank you for the bug report!&lt;/p&gt;
&lt;p&gt;If you want it fixed right now, replace &lt;code&gt;startLog()&lt;/code&gt; with this&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;def startLog(self):
    self.stopLog()
    self.stopLogAction.setDisabled(False)
    filename = QtGui.QFileDialog.getSaveFileName(None, &amp;#39;Dialog Title&amp;#39;)
    if(len(filename[0]) is 0):
        print(&amp;quot;No log file selected&amp;quot;)
    else:
        try:
            self.plot_window.logfile_name = filename[0]
            self.plot_window.enable_log = True
            self.plot_window.log_stopped = False
            print(&amp;quot;Started logging to %s&amp;quot; % filename[0])
            self.loggingAction.setDisabled(True)
            ret = QtGui.QMessageBox.information(None,
                                                &amp;quot;Logging started!&amp;quot;,
                                                &amp;quot;Logging average data to %s started&amp;quot; % filename[0],
                                                QtGui.QMessageBox.NoButton)
        except Exception as e:
            print(str(e))
            if (&amp;quot;Errno 13&amp;quot; in str(e)):
                print((&amp;quot;Unable to write to logfile &amp;#39;&amp;quot; + filename[0] + &amp;quot;&amp;#39;, write protected?&amp;quot;))
                ret = QtGui.QMessageBox.warning(None,
                                                &amp;quot;Unable to write to logfile!&amp;quot;,
                                                &amp;quot;Seems like %s is write protected.\
                                                \r\nMS Excel does this, but notepad++ does not, so make sure \
                                                \r\nto close any program that may have locked the file.&amp;quot; % filename[0],
                                                QtGui.QMessageBox.Ok,
                                                QtGui.QMessageBox.NoButton)
&lt;/code&gt;&lt;/pre&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>