<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic About operator |= in LPCXpresso IDE</title>
    <link>https://community.nxp.com/t5/LPCXpresso-IDE/About-operator/m-p/583235#M25779</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by hilite on Wed Nov 09 08:14:17 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;It is a question about ARM Cortex-M3 (LPC1434) of NXP. &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;For example, in order to start AD converter, the 24th bit of register AD0CR is set, but it is a code. &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;LPC_ADC-&amp;gt;CR |= (1&amp;lt;&amp;lt;24);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;It is writing. &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Operator "|=" currently used in code When operation of is "READ MODIFY WRITE", there is a vague feeling of anxiety. &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;It has written on the manual that the 28..31 bits of this register (AD0CR) is a reservation bit, and saying must not set 1. &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;And it is written that a value is not defined when the 28..31 bits is read . &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;That is,if operation of is "READ MODIFY WRITE", "1" may be written in 28..31 bits.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Is this my mistake? &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;(I'm japanese.It is pardon with strange English.):)&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 15 Jun 2016 22:46:22 GMT</pubDate>
    <dc:creator>lpcware</dc:creator>
    <dc:date>2016-06-15T22:46:22Z</dc:date>
    <item>
      <title>About operator |=</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE/About-operator/m-p/583235#M25779</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by hilite on Wed Nov 09 08:14:17 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;It is a question about ARM Cortex-M3 (LPC1434) of NXP. &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;For example, in order to start AD converter, the 24th bit of register AD0CR is set, but it is a code. &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;LPC_ADC-&amp;gt;CR |= (1&amp;lt;&amp;lt;24);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;It is writing. &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Operator "|=" currently used in code When operation of is "READ MODIFY WRITE", there is a vague feeling of anxiety. &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;It has written on the manual that the 28..31 bits of this register (AD0CR) is a reservation bit, and saying must not set 1. &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;And it is written that a value is not defined when the 28..31 bits is read . &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;That is,if operation of is "READ MODIFY WRITE", "1" may be written in 28..31 bits.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Is this my mistake? &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;(I'm japanese.It is pardon with strange English.):)&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 22:46:22 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE/About-operator/m-p/583235#M25779</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T22:46:22Z</dc:date>
    </item>
    <item>
      <title>Re: About operator |=</title>
      <link>https://community.nxp.com/t5/LPCXpresso-IDE/About-operator/m-p/583236#M25780</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;Content originally posted in LPCWare by Ex-Zero on Wed Nov 09 08:36:06 MST 2011&lt;/STRONG&gt;&lt;BR /&gt;&lt;HR /&gt;&lt;SPAN style="color: #0000ff;"&gt;&lt;STRONG&gt;Quote: hilite&lt;/STRONG&gt;&lt;BR /&gt;Is this my mistake? &lt;/SPAN&gt;&lt;HR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;No &lt;SPAN class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;&lt;LI-EMOJI id="lia_slightly-smiling-face" title=":slightly_smiling_face:"&gt;&lt;/LI-EMOJI&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;You could read, reset, modify and write instead:&lt;/SPAN&gt;&lt;BR /&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD bgcolor="#cacaca"&gt; &lt;PRE&gt;
LPC_ADC-&amp;gt;CR = (LPC_ADC-&amp;gt;CR &amp;amp; ~(0x0F&amp;lt;&amp;lt;28))|(1&amp;lt;&amp;lt;24);
&lt;/PRE&gt; &lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jun 2016 22:46:22 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPCXpresso-IDE/About-operator/m-p/583236#M25780</guid>
      <dc:creator>lpcware</dc:creator>
      <dc:date>2016-06-15T22:46:22Z</dc:date>
    </item>
  </channel>
</rss>

