cancel
Showing results for 
Search instead for 
Did you mean: 

PSoC™ 5, 3 & 1

Len_CONSULTRON
Honored Contributor II

Hi,

I'm a seasoned PSoC application designer.  I'm using a PSoC 5LP.  I have an application that uses the OpAmp v1.90.

Most of the time I need to configure the OpAmp with a mode = OpAmp.  The '-' input is routed to an external pin of a current sense resistor.  However due to the < 1Meg ohm input impedance (observed but not specified in the datasheet), I cannot resolve to < 30uA of current due to the extra draw and resultant noise.

If I "hard" configure the mode = Follower, I can resolve very low currents to ~ 1uA with much lower noise.

I want to configure the OpAmp to mode = OpAmp in the TopDesign and switch to mode=Follower in the code at run0time when needing to resolve to 1uA.  I can operate at the register level if needed but it would be nice if there were some API calls to provide this.

Note:  I tried using a analog mux external to the OpAmp to perform this desired function.  I noticed many problems doing this successfully and had to abandon the attempt.

Thanks for the help in advance.

Len

Len
"Engineering is an Art. The Art of Compromise."
0 Likes
1 Solution
EmHo_296241
Contributor II

Hi,

In CYWDR you can see the switch address which enables the follower mode if you hover over the switch. Try writing this register run time.

pastedImage_0.png

View solution in original post

0 Likes
8 Replies
odissey1
Honored Contributor II

Len,

can you explain how you measure 1uA current in Follower mode?

/odissey1

0 Likes
Len_CONSULTRON
Honored Contributor II

odissey1,

The Opamp is being used as the power stimulus for the current sense circuit.  When the stimulus is used in one mode (full scale range 0 to 20mA), I need +/- 100uA accuracy (Mode:OpAmp with an external pin connected to the '-' input).  In another mode (Mode: Follower with NO external pin connection to '-' input), I need +/-1uA accuracy (full scale range 0 to 1.4mA).  I can get this 1uA accuracy if I force this mode to Mode: Follower.  I'm looking for a means to switch this Opamp mode setting on-the-fly at run-time to improve performance in the needed mode.

Len

Len
"Engineering is an Art. The Art of Compromise."
0 Likes
odissey1
Honored Contributor II

Len, I was hoping for a schematic, I can only guess about arrangement. Can you add a follower in front of "-" input of the opamp to serve as high-impedance input buffer?

Regarding the register access. I would file a case with Cypress support. But i wouldn't be much optimistic about their answer.

/odissey1

0 Likes
Len_CONSULTRON
Honored Contributor II

Here's two configurations I'm writing about.  Each works to the accuracy I need if I 'hard' compile the schematic.

pastedImage_1.png

Len

Len
"Engineering is an Art. The Art of Compromise."
0 Likes
odissey1
Honored Contributor II

Len,

I would try to add a buffer in the feedback path, which should eliminate effect of low input impedance of the Opamp_1.

CurrentMeter_01.png

0 Likes
Len_CONSULTRON
Honored Contributor II

user_342122993,

If I use the buffer (OpAmp_2) suggestion I run into the same issue since the input impedance of Opamp_1 '-' terminal is the same as the impedance of Opamp_2 '+' terminal (Note: The input impedance of these terminals are not specified by Cypress.  They spec line exists but no value is stated).  Additionally if I use another buffer between port P_2, it is prone to potential error due to gain and input offset errors.  Therefore the output of Opamp_2 would be less accurate.

It comes to the idea that need a minimum of 4Meg input impedance in the mode when I want to measure 1uA resolution.  Removing the internal connection to P_2 and configuring Opamp_1 to mode=Follower works because the P_2 has more than 4Meg isolation to the '-' terminal of Opamp_1 in this configuration.

Len

Len
"Engineering is an Art. The Art of Compromise."
0 Likes
EmHo_296241
Contributor II

Hi,

In CYWDR you can see the switch address which enables the follower mode if you hover over the switch. Try writing this register run time.

pastedImage_0.png

View solution in original post

0 Likes
Len_CONSULTRON
Honored Contributor II

user_411084576,

Thank you.  I've done what you suggested.  In addition, I needed to disconnect a switch previously connected to the '-' terminal as well otherwise the terminal is connected to two analog sources.

Len

Len
"Engineering is an Art. The Art of Compromise."
0 Likes