Buy - Component - Analog signal to USB UART

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Tranzystomator
Level 1
Level 1
5 questions asked 10 sign-ins 5 replies posted

Hi,

I need component  that on the input take any analog signal, from -3.3V to 3.3V and then will convert it to digital world and  send them via USB Serial Port to computer. The component should allow me to configure input voltage range, time period and resolution of sampling. I can pay for create this component for me.

0 Likes
1 Solution

Prusinowsky,

odissey1 is correct.  You need to state more requirements.

Do you already have a working project meeting these requirements but without the component?

Most component creators first create a project with all the subcomponents wired together in a TopDesign and get it working first.  Then they go through the process of creating the component by converting the TopDesign sheet into a component schematic sheet.

At first glance, the first difficulty in your previously stated requirements is that the input signal is -3.3V to +3.3V.   

The PSoC is a single supply device (usually 0V to 5V).  This means it is incapable to input voltages below 0V.  There are two practical ways to achieve this:

  1. Use a dual- power supply (-5V and 5V) with an external instrumentation amp to level shift and scale the -3.3V to +3.3V input to the 0V to <5V range.  This means you would have at least one external active component as well as some external passive components (resistors).
  2. You might be able to eliminate the dual-supply and external instrumentation amp mentioned in 1.  However, you would still need to scale the -3.3V to +3.3V to  closer to -2.0V to 2.0V using external precision resistors. Additionally you would need to level-shift the scaled input so that the results are 0.5V to 4.5V.  Level-shifting would most likely require the PSoC's VDAC8 output to an external resistor network.
    Here's a pic of a circuit with the precision resistors and the VDAC8 to level-shift.  With this circuit, the VDAC8 would need to be calibrated by adjusting the shift voltage.

    Len_CONSULTRON_1-1655207548437.png

     

    This circuit has the following LTSpice results:
    Len_CONSULTRON_2-1655207605584.png

     

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

View solution in original post

0 Likes
5 Replies
Ekta_N
Moderator
Moderator
Moderator
750 replies posted First like given 250 solutions authored

Hi @Tranzystomator 

Please refer to the points below that will help you to create a component:

1. The following youtube videos should give you an idea of how you can create a custom component: You Tube Link
You Can also refer to the following appnotes: 
> PSoC Creator - Implementing Programmable Logic Designs with Verilog 
Designing PSoC Creator Components with UDB Datapaths

2. You can import  USBUART component and ADC component and modify them to realize the functionality i.e. get the digital data from the ADC component and sent it to the USBUART component which can in turn send it to the PC. The following Knowledge Based Article should give you an idea of how you can import a component and make changes to it: Customizing a Component using PSoC Creator - KBA229139

3. You can also refer to the following code examples that will help you realize the functionality:
> For sending data to the PC using USBUART: USB_UART with PSoC 5LP
> The following example shows Delta Sigma ADC (ADC_DelSig) Component to take samples of an analog input and send those samples to a PC application over RS-232 via the UART Component: Link
This code example needs to be modified a little to replace the UART component in this with the USBUART component in the above example.

Thanks and Regards
Ekta

0 Likes
Tranzystomator
Level 1
Level 1
5 questions asked 10 sign-ins 5 replies posted

Thanks @Ekta_N,

But maybe you know person how can create such component for a fee. 

0 Likes

Prusinowsky,

odissey1 is correct.  You need to state more requirements.

Do you already have a working project meeting these requirements but without the component?

Most component creators first create a project with all the subcomponents wired together in a TopDesign and get it working first.  Then they go through the process of creating the component by converting the TopDesign sheet into a component schematic sheet.

At first glance, the first difficulty in your previously stated requirements is that the input signal is -3.3V to +3.3V.   

The PSoC is a single supply device (usually 0V to 5V).  This means it is incapable to input voltages below 0V.  There are two practical ways to achieve this:

  1. Use a dual- power supply (-5V and 5V) with an external instrumentation amp to level shift and scale the -3.3V to +3.3V input to the 0V to <5V range.  This means you would have at least one external active component as well as some external passive components (resistors).
  2. You might be able to eliminate the dual-supply and external instrumentation amp mentioned in 1.  However, you would still need to scale the -3.3V to +3.3V to  closer to -2.0V to 2.0V using external precision resistors. Additionally you would need to level-shift the scaled input so that the results are 0.5V to 4.5V.  Level-shifting would most likely require the PSoC's VDAC8 output to an external resistor network.
    Here's a pic of a circuit with the precision resistors and the VDAC8 to level-shift.  With this circuit, the VDAC8 would need to be calibrated by adjusting the shift voltage.

    Len_CONSULTRON_1-1655207548437.png

     

    This circuit has the following LTSpice results:
    Len_CONSULTRON_2-1655207605584.png

     

Len
"Engineering is an Art. The Art of Compromise."
0 Likes
If your input can tolerate this circuit, here is a simpler circuit with fewer resistors.
Len_CONSULTRON_0-1655288980228.png

The gain is 1/2 and VDAC8_1 controls the level-shifting.  The output OUTp = 0V to 3.3V

Len_CONSULTRON_1-1655289083280.png

 

Len
"Engineering is an Art. The Art of Compromise."
0 Likes
odissey1
Level 9
Level 9
First comment on KBA 1000 replies posted 750 replies posted

Prusinowsky,

I recommend to put more details, which would help to understand your requirements. For example, why it has to be a single component, what sample rate needed, DelSig or SAR ADC, what communication protocol, UART receiving software, etc.

     Maybe, a simple demo project would suffice?

0 Likes