Hi Thanh-ha<br><br><div>You are correct, you can write a method to check metal error similar to Set/Get button information.</div><div><br></div><div>You can do that in <span class="Apple-style-span" style="border-collapse: collapse; font-family: arial, sans-serif; font-size: 13px; ">igstkAscensionCommandInterpret</span><span class="Apple-style-span" style="border-collapse: collapse; font-family: arial, sans-serif; font-size: 13px; ">er class.</span></div>
<div><font class="Apple-style-span" face="arial, sans-serif"><span class="Apple-style-span" style="border-collapse: collapse;">After that, you need to do the following in the AscensionTracker.cxx</span></font></div><div><font class="Apple-style-span" face="arial, sans-serif"><span class="Apple-style-span" style="border-collapse: collapse;"><br>
</span></font></div><div><font class="Apple-style-span" face="arial, sans-serif"><span class="Apple-style-span" style="border-collapse: collapse;">1. In the following function, add your call to set the MetalError detection </span></font></div>
<div><font class="Apple-style-span" face="arial, sans-serif"><span class="Apple-style-span" style="border-collapse: collapse;"> AscensionTracker::ResultType AscensionTracker::InternalOpen( void )</span></font></div><div>
<font class="Apple-style-span" face="arial, sans-serif"><span class="Apple-style-span" style="border-collapse: collapse;"><br></span></font></div><div><font class="Apple-style-span" face="arial, sans-serif"><span class="Apple-style-span" style="border-collapse: collapse;">2. In the following method:</span></font></div>
<div><span class="Apple-style-span" style="border-collapse: collapse; font-family: arial, sans-serif; "><br></span></div><div><span class="Apple-style-span" style="border-collapse: collapse; font-family: arial, sans-serif; "> AscensionTracker::ResultType </span><span class="Apple-style-span" style="border-collapse: collapse; font-family: arial, sans-serif; ">AscensionTracker::InternalThreadedUpdateStatus( void )</span></div>
<div><font class="Apple-style-span" face="arial, sans-serif"><span class="Apple-style-span" style="border-collapse: collapse;"><div><br></div><div>After the update:</div></span></font></div><div><font class="Apple-style-span" face="arial, sans-serif"><span class="Apple-style-span" style="border-collapse: collapse; "> m_CommandInterpreter->Update();</span></font></div>
<div><font class="Apple-style-span" face="arial, sans-serif"><span class="Apple-style-span" style="border-collapse: collapse; "><br></span></font></div><div><font class="Apple-style-span" face="arial, sans-serif"><span class="Apple-style-span" style="border-collapse: collapse;">Check your metal error, and set it to tracker transform.</span></font></div>
<div><font class="Apple-style-span" face="arial, sans-serif"><span class="Apple-style-span" style="border-collapse: collapse;"><br></span></font></div><div><font class="Apple-style-span" face="arial, sans-serif"><span class="Apple-style-span" style="border-collapse: collapse;">Please refer to line 218 and 221 of the igstkAscensionTracker.cxx file for setting the error values.</span></font></div>
<div><font class="Apple-style-span" face="arial, sans-serif"><span class="Apple-style-span" style="border-collapse: collapse;"><br></span></font></div><div><font class="Apple-style-span" face="arial, sans-serif"><span class="Apple-style-span" style="border-collapse: collapse;">Patrick</span></font></div>
<div><font class="Apple-style-span" face="arial, sans-serif"><span class="Apple-style-span" style="border-collapse: collapse; "><br></span></font><div class="gmail_quote">On Thu, Aug 4, 2011 at 7:38 AM, Thanh-Ha NGUYEN <span dir="ltr"><<a href="mailto:nguyen.than.tu@gmail.com">nguyen.than.tu@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">Hi Patrick,<br>
<br>
I already looked at the 3DG API, but as I am using the serial port
(RS232) to communicate with the tracker, I have no choice but to use the
RS232 Interface (the one which uses Bird files). See the medSAFE Guide
attached, slide 52. Though, one could notice a reference to RS232 in the ATC3DGm.h file. But I chose to follow the
documentation, and thus I used the RS232 Interface. Details about the Metal error can be found in the de slide 248 of the guide. Note that the way this information is given by the tracker is similar to that of the "BUTTON". And this information has its getter (igstkAscensionCommandInterpreter.h : line 402). Now, why couldn't I just replicate the code related to the "BUTTON" and adjust it to the "METAL" ? Because both the "METAL" and the "BUTTON" information can be set on/off independently but are sent in a same data stream. And as the "BUTTON" byte comes first in the data stream, there is a need to locate the "METAL" byte depending on the "BUTTON" information state. I don't know whether I am understandable. Now, I can only advise you to refer to the guide (slide 248) if you want more detail.<br>
<br>I will appreciate any help. Thank you in advance.<br><font color="#888888"><br>Thanh-Ha.<br>
</font></blockquote></div><br></div>