PSoC™ 5, 3 & 1 Forum Discussions
Hi.
I'm using the PSoC3 first touch starter kit CY8CKIT-003.
I'm trying to use the VDAC8 to push out a chirp signal (a sine wave of linearly varying frequency from 38kHz to 42kHz). To get the values, I'm using a lookup table similar to the example on the online training video LAB 4 (the working man's oscilloscope)
The lookup table's inside an interrupt handler.
Question 1: The code provided with the training video doesn't work: My PSoC creator says that some of the code is outdated. Even if I update it, the code does not fully work. For some reason the program control shifts to the interrupt handler (I know this because I set a 'happy light' led to light up (and complement itself the next time the interrupt occurs) when an interrupt occurs) BUT it does not retrigger that interrupt some time later, as would be expected.
Question 2: Is there something I'm missing, like clearing an interrupt flag somewhere?
Show LessUsing the CY8C24423A I am trying to use the falling edge of a pulse to wake-up the device, do some ADC, then go back to sleep... wake up on the next falling edge etc and repeat....
I read in the Cypress Datasheet for my part that the system can only wake up from: GPIO Ints, supply mon. int., analog column int, and timer clocked EXTERNALLY or from 32KHz clock.
My timer that I am using is clocked from the incoming pulse train (variable)... I have a hardware reset that causes a GPIO interrupt and I have seen that work by toggling an LED (sleep and non-sleep), but whenever I put the device to sleep and expect to see the LED go high on the falling edges of the incomming pulse it's not there. When I don't put the system to sleep I can see my LED go high as expected...
Is what I am doing possible? I'm not sure if there is some assembly I might have to change to make this work... has anyone else had to do something similar?
I haven’t been real specific in my application, except that I need to do ADC on the low portion of a pulse and then go back to sleep. Maybe there is a better way to do this…
Any help will be appreciated.
Show LessI have an application where I would like to wake the PC from a USBUART device.
i have read a lot about USB communication and found I should be possible to wakeup the PC with a RING signal send to the usbser.sys driver.
I have downloaded non Cypress device and see the PC is ready to wakeup. I have also connected another device (FTDI device) and let this device wakeup the pc. It's all working.
My problem is now to send a ring signal from a CY8C24894. I have used this command:
USBUART_SendStateNotify(USBUART_RING);
but without the wanted result.
Have anybody tried to wakeup the PC from at USBUART?
Best regards
Bent
Show LessCapsense feedback resistor pin is fixed to P1.1 as well, as I2C SCL
Is there a way to detect I2C SCL master presense and somehow switch between capsense ans I2C?
regards
robert
Show LessI'm trying to make use of I2CHW module, i order to modify comparator hyst parameter.
For testing only I put control value in I2cregs.cSTR[4] to see what is going on.
I figured out that code puts the value which is not entered.
I mean that under I2CRegs.cStr[4] appears value 0x70 after I2Cconversation
w 04+ 00+ 10+ 10+ 10+ 10+ 10+ p
r 04+ 00+ 70+ 00+ 00+ 10+ 10+ 00+ p
w 04+ 01+ 10+ 10+ 10+ 10+ 10+ p
r 04+ 10+ 70+ 00+ 00+ 10+ 70+ 00+ p
Please ommit 00 twice after 70. it's from the rest of the code
Below is the code which runs in the loop:
"
volatile unsigned char histCurrent = 0x70;
void I2C(void)
{
BYTE status;
status = I2CHW_bReadI2CStatus();
/* Wait to read data from the master */
if( status & I2CHW_WR_COMPLETE ){
/* Data received - clear the Write status */
I2CHW_ClrWrStatus();
/* Reset the pointer for the next read data */
I2CHW_InitWrite((BYTE*)&I2CRegs,BS);
if(I2CRegs.bCmd == 0x01)
{
switch (I2CRegs.cStr[0])
{
case COMP_REF0_937:
case COMP_REF0_875:
case COMP_REF0_812:
case COMP_REF0_750:
case COMP_REF0_688:
case COMP_REF0_625:
case COMP_REF0_562:
case COMP_REF0_500:
case COMP_REF0_437:
case COMP_REF0_375:
case COMP_REF0_312:
case COMP_REF0_250:
case COMP_REF0_188:
case COMP_REF0_125:
case COMP_REF0_062:
case COMP_REF0_042:
case COMP_REF0_021:
histCurrent = I2CRegs.cStr[0] ;
I2CRegs.cStr[4] = I2CRegs.cStr[0];
break;
default:
histCurrent = COMP_REF0_500;
I2CRegs.cStr[4] = I2CRegs.cStr[0];
break;
}
COMP_SetHyst(histCurrent);
I2CRegs.bCmd = 0x10;
}else I2CRegs.bCmd = 0;
}
if( status & I2CHW_RD_COMPLETE )
{
/* Data echoed - clear the read status */
I2CHW_ClrRdStatus();
/* Reset the pointer for the next data to echo */
I2CHW_InitRamRead((BYTE*)&I2CRegs,BS);
}
}"
I am using a Cy8C28452-24PVXI part, I am using the Del Sig Multi adc. The adc is configured for 2 channels 12 bit operation. and 2 analog blocks per channel.
Now my questions are as follows:-
1> What advantage is there with DB synchronization?
2>If I use the DB sync option I am unable to change the column why? But without the DB sync option I can change the column placement?
I am using PD5.1 beta2
Regards Amit
Show LessHi,
Has anyone used both versions of this part in a Capsense application? I had a working design w/ the 1001 rev, the chip failed, had to replace w/ 1007 (latest, greatest?), now having frequent lockups during Capsense operation, requiring a power reset. Other functions seem OK, i.e. reading analog voltages on GPIO, etc. Just wondering if anything was changed between 1001 and 1007 that could explain this...
Thanks for any feedback, I can provide more info if required, but the only thing that's changed is the chip revision/batch, or whatever the 1001/1007 designate.
Show LessHi,
Is it possible to edit existing components? I would really like to implement an analog multiplexer which takes a clock input, so that it can change channel automatically.
Thanks
Hugo
Show Less