<?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 Changing ADC Channel &amp; Enabling PGA in Processor Expert Software</title>
    <link>https://community.nxp.com/t5/Processor-Expert-Software/Changing-ADC-Channel-Enabling-PGA/m-p/341017#M2603</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Everyone,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm using a MK10DX256 and have two questions related to enabling the PGA.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1) The Reference Manual states that to use the PGA, you must be on ADC channel DAD2 (ADCH = 00010). I've been hunting through processor expert and I have been unable to find where I can specify the actual channel used by the ADC component. When I dig through the generated code, the value I need changed exists in the AdcLdd1.c file in the ChannelToPin table. By default, it sets the ADCH to 0. I can manually change this to 2 (DAD2) but of course this gets overwritten every time I re-generate my code. Does anyone know how to set this value through PE?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I've tried setting it programmatically after the ADC is initialized, however the generated ISR always re-sets the value after every ISR call.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2. How do I enable the PGA through processor expert? From my looking, it doesn't look like PE supports this yet. I've been able to manually enable it, so it's not a huge issue problem (besides getting the channel set correctly).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 04 Sep 2014 20:03:27 GMT</pubDate>
    <dc:creator>mnelson</dc:creator>
    <dc:date>2014-09-04T20:03:27Z</dc:date>
    <item>
      <title>Changing ADC Channel &amp; Enabling PGA</title>
      <link>https://community.nxp.com/t5/Processor-Expert-Software/Changing-ADC-Channel-Enabling-PGA/m-p/341017#M2603</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Everyone,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm using a MK10DX256 and have two questions related to enabling the PGA.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1) The Reference Manual states that to use the PGA, you must be on ADC channel DAD2 (ADCH = 00010). I've been hunting through processor expert and I have been unable to find where I can specify the actual channel used by the ADC component. When I dig through the generated code, the value I need changed exists in the AdcLdd1.c file in the ChannelToPin table. By default, it sets the ADCH to 0. I can manually change this to 2 (DAD2) but of course this gets overwritten every time I re-generate my code. Does anyone know how to set this value through PE?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I've tried setting it programmatically after the ADC is initialized, however the generated ISR always re-sets the value after every ISR call.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2. How do I enable the PGA through processor expert? From my looking, it doesn't look like PE supports this yet. I've been able to manually enable it, so it's not a huge issue problem (besides getting the channel set correctly).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Sep 2014 20:03:27 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Processor-Expert-Software/Changing-ADC-Channel-Enabling-PGA/m-p/341017#M2603</guid>
      <dc:creator>mnelson</dc:creator>
      <dc:date>2014-09-04T20:03:27Z</dc:date>
    </item>
    <item>
      <title>Re: Changing ADC Channel &amp; Enabling PGA</title>
      <link>https://community.nxp.com/t5/Processor-Expert-Software/Changing-ADC-Channel-Enabling-PGA/m-p/341018#M2604</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi mnelson,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I answer the 2) question first cause it is necessary to initialized the PGA before the ADC starts measure. So to initialize the PGA please add to the project Init_PGA component and place it before ADC_LDD component to be sure that PGA will be initialize before ADC.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For 1) To select appropriate channel you have to use the CreateSampleGroup() or SelectSampleGroup() method. You can find more info on right click of the component-&amp;gt; Help on component -&amp;gt; &lt;EM&gt;Typical Usage page.&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;CreateSampleGroup() - is used for the runtime preparation of the sample group, while SelectSampleGroup() is used to select sample group from prepared in the Property tab -&amp;gt;Static sample group.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;After that you can call one of the Start...Measurement() method e.g.: StartSingleMeasurement() method.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Good Luck&lt;/P&gt;&lt;P&gt;Jiri&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 15 Sep 2014 14:31:17 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Processor-Expert-Software/Changing-ADC-Channel-Enabling-PGA/m-p/341018#M2604</guid>
      <dc:creator>jch</dc:creator>
      <dc:date>2014-09-15T14:31:17Z</dc:date>
    </item>
  </channel>
</rss>

