PSoC™ 5, 3 & 1 Forum Discussions
I would like to use EMIF in a multiprocessor system. For this, the address and data bus should be set to a high-impedance state from time to time. Possible? I can't find where the EMIF bus is connected in the drawing? Directly to PIN or Drive Logic block? Or something else?
Is there a diagram or more detailed description for the EMIF UDB signals (Xmem_wr, Xmem_rd, Udb_Ready)?
Show LessHello,
Hope you all are doing good.
I am stuck how can I send the adc converted data to any variable of data type uint8 assigned in the code.
I am using following dma configuration but i am not receiving data in uint8 value2 variable. purpose is to receive data in value2 via DMA then process it and send it to pwm via DMA , so basically i need to know how to get data in any variable and send data from any variable to peripheral via DMA .
please guide me.
for ADC (8 bits) to variable, I have connected EOC of delsig ADC to drq of DMA and left nrq pin of DMA unattached.
thanks
following is the definition and configuration i am using
#include <project.h>
#include <math.h>
#include <stdio.h>
#include <stdbool.h>
#include <time.h>
#include <cydevice.h>
#include <cytypes.h>
#define DMA_BYTES_PER_BURST 1
#define DMA_REQUEST_PER_BURST 1
#define DMA_SRC_BASE (CYDEV_PERIPH_BASE)
#define DMA_DST_BASE (CYDEV_SRAM_BASE)
void DMA_Config(){
/* Variable declarations for DMA */
/* Move these variable declarations to the top of the function */
uint8 DMA_Chan;
uint8 DMA_TD[1];
/* DMA Configuration for DMA */
DMA_Chan = DMA_DmaInitialize(DMA_BYTES_PER_BURST,DMA_REQUEST_PER_BURST,HI16(DMA_SRC_BASE),HI16(DMA_DST_BASE));
DMA_TD[0] = CyDmaTdAllocate();
CyDmaTdSetConfiguration(DMA_TD[0], 1, DMA_TD[0], DMA__TD_TERMOUT_EN );
CyDmaTdSetAddress(DMA_TD[0], LO16((uint8)ADC_DEC_SAMP_PTR), LO16((uint8)&value2));
CyDmaChSetInitialTd(DMA_Chan, DMA_TD[0]);
CyDmaChEnable(DMA_Chan, 1);
}
Hi I can not programming with psoc programmer and minoprog 3???
Hello Everyone,
hope you all are doing good.
I need your suggestions and help on my following tasks:
"note: a long question"
I have psoc5 lp , a mosfet (bsl802sn) and drain resistor 2.2 ohms and at source shunt resistor of 100m ohms .
My 1st-task is to maintain desired dc voltage at shunt resistor.
For this what i am doing is taking a reference volts from across shunt resistor connects it to DELSIG ADC (differential mode) in psoc 5 converts it in samples , setting a desired voltage(in between 20 to 50mv dc),implementing pid controller, calculating controlled output and send to VDAC and vdac is connected to gate of mosfet and it control the gate and maintains desired dc voltage at shunt resistor even though if I change vdd of mosfet with in a range of 2 to 4 volts , and this is working fine with some errors.
I am not sure whether this approach is good or there are some other ways for my 1st task.
my 2nd task is :
it is a continuation of 1st task in which i have to shape the output dc voltage at shunt in a rectangular wave for this i am thinking that setting two desired voltage in PID and one is zero and one is, again in between(20mv to 50mv) and oscillate between two desired voltage with frequency between 1 Hz to 2KHz hence will get rectangular wave with a high level voltage equal to our desired voltage. and here also if my vdd will change for any reason between 2 to 4 volts my desired voltage should not be change.
and for this task i am confused if this is a applicable solution to my task 2 or there are some other ways?
and 3rd task is to generate a sine wave just like a square wave. and setting a peak to peak voltage by changing desired voltage in pid in a sine wave manner.
i am not sure for all my tasks the approach i am thinking is the practical and applicable approach or there are other ways to do these tasks. let me know I will share more details if anyone does not get my point
thanks for your time to read my long query.
thank you.
Hello community, to express my gratitude towards the competent assistance I received in a recent thread (see full thread here) here are a couple of learnings.
I could not post this in the original thread as it is locked for some reason now - maybe because I marked it as solved.
- Signal Level shifting problems can be addressed via the component configurator (pin properties input threshold) e.g., CMOS or LVTTL or via the CTL registers of the ports. In case you use the emFile component set the threshold of the MISO pin to LVTTL via the control register of the corresponding port. This is particularly handy when you work with microSD breakouts that have mixed signal levels e.g. inputs are level shifted but outputs are not.
- Some pins in the KIT for PSoC 5LP have hard wired capacitors which can "distort" the signals to a point where logical levels are not reached anymore. So for the SCLK signal pay attention not to use 0.2 0.3 0.4 pins as these have the bespoke capacitors.
- I did test the emFile with the above modifications and I got to read the label of the disk. Unfortunately, the result was not stable/repeatable and I did not manage to read a file or dir on the card. Pls check the original post where BiBi did a successful test. So this solution for emFile should principally work. I just don't have the time to look deeper into the situation with an oscilloscope and will work with fatFs instead.
- fatFs is slightly more flexible than emFile in that all SPI wiring is openly accessible and you can configure the pins with the IDE
- fatFS for long file names has some issues unless you use a recent version. I did deploy the latest version with my current project. It did not work out of the box so I had to apply a number of changes to the source files to make it compile and work.
- both emFile and fatFs seem to work with a 32GB microSD (sandisk) in the case of fatFs full function is quasi tested.
Thanks again to BiBi and Leo for your kind assistance.
Cheers,
Stefan
My links to the reference manuals are all old (Cypress) and broken.
When I search either Infineon or the community all that comes up are PSoC 4, PSoc 6, etc. , or links that don't work.
Where can I go to read/download them?
Thanks,
Show Less
I have a question about the CY8C36 family.
1. When using ADC, internal Vref can be set to 6x, but is it structurally 6x using PGA?
2. I think it is suppressed to less than headroom (about 4.75V) at full scale, but I would like to know why Vref=1.024→6.144V can be calculated when converting ADC code to actual measured value.
3. In this case, can we consider Vref accuracy as 0.3% x 6?
Thank you in advance.
Show LessHello Community,
there are several differing statements about the limits of the emFile component. Does anyone have an up to date
definitive answer what the maximum card size is for the current emFile component and libraries (as downloaded from the component website) ?
And second question: has anyone lately succeeded in using a micro SD breakout SPI board with emFile or any other solution ? If yes, pls send me a link to the product that you used. I am having trouble in particular with the breakouts from China.
Thanks
Stefan
Show Less