<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body dir="auto"><div>This is my first patch submission. &nbsp;Please let me know if I did int right.<br><br><div><span style="font-size: 13pt;">-- wireless &lt;<a href="mailto:Joseph.P.Scanlan@n7xsd.us">Joseph.P.Scanlan@n7xsd.us</a>&gt; +1-702-896-0507</span></div>-- work &lt;<a href="mailto:Joseph.P.Scanlan@clarkcountynv.gov">Joseph.P.Scanlan@ClarkCountyNV.gov</a>&gt; +1-702-455-3679<br><div>--&nbsp;</div><div>These mechanics</div><div>and mathematics</div><div>they give me comfort</div><div>when I'm afraid.</div><div>&nbsp; â€”Venus Hum</div></div><div><br>On Dec 10, 2015, at 10:13 AM, Joseph.P.Scanlan--- via chirp_devel &lt;<a href="mailto:chirp_devel@intrepid.danplanet.com">chirp_devel@intrepid.danplanet.com</a>&gt; wrote:<br><br></div><blockquote type="cite"><div><span></span><br><span># HG changeset patch</span><br><span># User &lt;<a href="mailto:Joseph.P.Scanlan@n7xsd.us">Joseph.P.Scanlan@n7xsd.us</a>&gt;</span><br><span># Date 1449768806 28800</span><br><span># &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Thu Dec 10 09:33:26 2015 -0800</span><br><span># Node ID 5041a82f811b692759ce75b4520ad34b553cc572</span><br><span># Parent &nbsp;95684405e6c32047c1d9e61a0e152cb198cbaf27</span><br><span>[ic7000]Digital Code Squelch for IC-7000 channels. &nbsp;Fixes bug #3047</span><br><span>Corrected reading of DCS from memory.</span><br><span>Added writing of DCS to memory.</span><br><span>Added reading and writing DCS polarity to memory.</span><br><span></span><br><span>diff -r 95684405e6c3 -r 5041a82f811b chirp/drivers/icomciv.py</span><br><span>--- a/chirp/drivers/icomciv.py &nbsp;Mon Nov 30 10:15:59 2015 -0800</span><br><span>+++ b/chirp/drivers/icomciv.py &nbsp;Thu Dec 10 09:33:26 2015 -0800</span><br><span>@@ -30,8 +30,8 @@</span><br><span> bbcd rtone[2];</span><br><span> u8 &nbsp;&nbsp;unknown5;</span><br><span> bbcd ctone[2];</span><br><span>-u8 &nbsp;&nbsp;unknown6[2];</span><br><span>-bbcd dtcs;</span><br><span>+u8 &nbsp;&nbsp;dtcs_polarity;</span><br><span>+bbcd dtcs[2];</span><br><span> u8 &nbsp;&nbsp;unknown[17];</span><br><span> char name[9];</span><br><span> """</span><br><span>@@ -50,8 +50,8 @@</span><br><span> bbcd rtone[2];</span><br><span> u8 &nbsp;&nbsp;unknown5;</span><br><span> bbcd ctone[2];</span><br><span>-u8 &nbsp;&nbsp;unknown6[2];</span><br><span>-bbcd dtcs;</span><br><span>+u8 &nbsp;&nbsp;dtcs_polarity;</span><br><span>+bbcd dtcs[2];</span><br><span> u8 &nbsp;&nbsp;unknown[11];</span><br><span> char name[9];</span><br><span> """</span><br><span>@@ -265,9 +265,18 @@</span><br><span> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if self._rf.valid_tmodes:</span><br><span> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;mem.tmode = self._rf.valid_tmodes[memobj.tmode]</span><br><span></span><br><span>+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if self._rf.has_dtcs_polarity:</span><br><span>+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if memobj.dtcs_polarity == 0x11:</span><br><span>+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;mem.dtcs_polarity = "RR"</span><br><span>+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;elif memobj.dtcs_polarity == 0x10:</span><br><span>+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;mem.dtcs_polarity = "RN"</span><br><span>+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;elif memobj.dtcs_polarity == 0x01:</span><br><span>+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;mem.dtcs_polarity = "NR"</span><br><span>+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;else:</span><br><span>+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;mem.dtcs_polarity = "NN"</span><br><span>+</span><br><span> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if self._rf.has_dtcs:</span><br><span>- &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;# FIXME</span><br><span>- &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;mem.dtcs = bitwise.bcd_to_int([memobj.dtcs])</span><br><span>+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;mem.dtcs = bitwise.bcd_to_int(memobj.dtcs)</span><br><span></span><br><span> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if "Tone" in self._rf.valid_tmodes:</span><br><span> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;mem.rtone = int(memobj.rtone) / 10.0</span><br><span>@@ -308,6 +317,19 @@</span><br><span> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;memobj.ctone = int(mem.ctone * 10)</span><br><span> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;memobj.rtone = int(mem.rtone * 10)</span><br><span></span><br><span>+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if self._rf.has_dtcs_polarity:</span><br><span>+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if mem.dtcs_polarity == "RR":</span><br><span>+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;memobj.dtcs_polarity = 0x11</span><br><span>+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;elif mem.dtcs_polarity == "RN":</span><br><span>+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;memobj.dtcs_polarity = 0x10</span><br><span>+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;elif mem.dtcs_polarity == "NR":</span><br><span>+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;memobj.dtcs_polarity = 0x01</span><br><span>+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;else:</span><br><span>+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;memobj.dtcs_polarity = 0x00</span><br><span>+</span><br><span>+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if self._rf.has_dtcs:</span><br><span>+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;bitwise.int_to_bcd(memobj.dtcs, mem.dtcs)</span><br><span>+</span><br><span> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;LOG.debug(repr(memobj))</span><br><span> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;self._send_frame(f)</span><br><span>_______________________________________________</span><br><span>chirp_devel mailing list</span><br><span><a href="mailto:chirp_devel@intrepid.danplanet.com">chirp_devel@intrepid.danplanet.com</a></span><br><span><a href="http://intrepid.danplanet.com/mailman/listinfo/chirp_devel">http://intrepid.danplanet.com/mailman/listinfo/chirp_devel</a></span><br><span>Developer docs: <a href="http://chirp.danplanet.com/projects/chirp/wiki/Developers">http://chirp.danplanet.com/projects/chirp/wiki/Developers</a></span><br></div></blockquote></body></html>