PSoC™ 4 Forum Discussions
We are using the CY8C4248 and having an intermittent, irregular lock-up of the main loop. Interrupts are still able to occur, so our WatchDogTimer still fires. After 60 of not running all the way through the main loop, we print the main stack (__get_MSP) and compare memory addresses to the elf file. The main stack trace appears to read:
InterruptPointer(Same address as _getPSP)
ll_wait_to_enter_dsm (possibly deep sleep mode?)
ll_enter_sm_mode
ll_derive_ce_length_for_s
llft_service_queue
CyBle_SignalBleStackTask
OS_scheduler
enterLowPowerStateIfPossible (where we call CySysPmDeepSleep())
main
1) Is it possible for deep sleep mode to stop waking when our timer is fired?
2) What tools other than the debugger does cypress have to trace the source of lockups? We are using the bootloader, deep sleep mode, and interrupts. All of which aren't happy with attaching a debug tool.
Show LessI had the em_eeprom block working in Creator 3. Now in Creator 4 the block has changed and that code does not work. Surprised by the lack of backward compatibility!
Here is how I have it set. If anyone spots the problem, thanks in advance! - John
EmEEPROM_v2_20 block:
EEPROM Size: 64
Redundant copy: No
Wear Level Factor: 5x
(Actual EEPROM size (bytes): 640
Flash Security:
All blocks W except the last five blocks are U
Build settings; Linker command line:
-Wl.--section-start=.EEPROMDATA=0x00007D80
Code:
#define TAG 0x5a
#define EE_SIZE 3
static const uint8 eepromArray[] __attribute__ ((section (".EEPROMDATA"))) = { ~TAG,0,0};
#define ee_valid_flag (*(volatile uint8 *) &eepromArray[0])
#define ee_control_byte (*(volatile uint8 *) &eepromArray[1])
#define ee_spare (*(volatile uint8 *) &eepromArray[2])
uint8 ram_array[EE_SIZE];
#define valid_flag ram_array[0]
#define control_byte ram_array[1] // ????temp
#define spare ram_array[2]
int main()
{
Em_EEPROM_Init(CY_EM_EEPROM_FLASH_BASE_ADDR);
:
:
Em_EEPROM_Read(0, ram_array, EE_SIZE); //&Em_EEPROM_context);
:
:
Em_EEPROM_Write(0, ram_array, EE_SIZE); //&Em_EEPROM_context);
}
Show LessMy device based on cyble-022001 is supposed to have <<1 uA power consumption when the user (or software) switch is off. Then cyble is in stop mode. I was measuring that and it was taking about 2 uA on my custom board with two sensors and a few 100 nF ceramic caps. When I switched off the small work light I have on my table the consumption dropped to 40 nA! I though this was caused by the sensor, since it measures visible and IR light and for it the standby current is specifically said to be in the dark.
But shadowing different parts with finger or a business card revealed it was definitely the module that changed the current consumption and it was its shielded part.
Is that expected? How much the current will be in direct sunlight? Are deepsleep and hibernate equally affected?
The work light I noticed this with is just a small one with 40 W traditional bulb. And it's about 30 cm from the module not heating it up etc. I also tested with a small LED flashlight, but it had much less effect (~100 nA) although I kept it very close and it was definitely brighter (over the scale of 4000 lx vs. 600 lx according to my sensor).
Show LessHi,
I am working on CY8C4246AZI-L445 controller and I want use 4 Uarts with receive interrupt.
Whenever I try to add more than 2 uart block in creator it's giving me errors like MAX NUMBER OF MACROCELLS EXCEEDED.I don't understand how to figure out this issue.
I am not using SCB uart ,using another one.
Please help on this asap.
Thanks in advance
Show LessHi CUS,
Not sure about specifications on CPU PSOC4/CY8C4147AZI-S475 regarding CAN interface.
On your site @cypress Homepage no. of CAN controllers is set to 0 for CPU mentioned above,
https://www.cypress.com/part/cy8c4147azi-s475
Having said that looking into datasheet no of CAN controllers is set to 1.
https://www.cypress.com/file/396611/download
Which one is true? Actually compiling works with CAN component without test of interface.
Thanks for support.
KR
Show LessBelow, the same sentences are written in English and Japanese.
・English
I want to output 100% Duty from the line terminal with the "Left align" setting of PWM.
As shown below, an error will occur if Period = "9", Compare = "10".
Can not set Duty 100% on the component initial value setting screen?
・Japanese(日本語)
PWMを"Left align"設定で、line端子から100%Dutyを出力したいです。
以下の様に、Period="9",Compare="10"に設定した場合エラーになります。
コンポネント初期値設定画面ではDuty100%設定はできないという認識でよろしいでしょうか?
・English
However, in the program statement (main.c), it is possible to set the Period value to "9" using the API.
※ In the component initial value setting screen, Period = "10", Compare = "10" are set.
Is 100% duty configurable when using the API?
・Japanese(日本語)
しかし、プログラム文(main.c)で、APIを使用しPeriod値を"9"を設定することは可能です。
※コンポネント初期値設定画面では、Period="10",Compare="10"に設定しております。
APIを使用したら、100%Duty設定可能という認識でよろしいでしょうか?
i am working with Psoc4 Ble pioneer kit.
i want to generate a WDT based interrupt after every hour. so to do that i have i have used global signal component.
this is my code
CY_ISR(WDT_ISR_handler)
{
WDT_ISR_ClearPending();
}
int main(void)
{
HW_Init();
/* Starts RTC component */
RTC_Start();
/* Set RTC time update period */
RTC_SetPeriod(1u, SYSTICK_EACH_1_HZ);
RTC_ClearAlarmStatus() ;
RTC_SetAlarmHandler( alarm_handler ) ;
RTC_SetAlarmMask( RTC_ALARM_SEC_MASK ) ;
WDT_ISR_StartEx(WDT_ISR_handler);
for(;;)
{
}
}
please find attached screen shots for WDT2 clock configuration.(currently i am testing it with only 4 seconds)
so my problem is first time interrupt is generated after 4 seconds but then it could not clear and the pending register or something.
please guide me.
Show LessI used PSoc Creator4.2 to create a project with Capsense_ADC module, and a compiler error occurred. The code of the error is as follows. How to solve this problem? Thank you!
Show Less
Hi all,
I'm working on a PSoC 4 BLE with a CY8CKIT-143A PSoC kit.
In order to start the production phase, I configured the Bluetooth Device Address of my board writing the ID inside the Row0 of the SFLASH. As suggested, I used the software tool "PSoC4-BLE-SFLASH-Update" inside the directory "C:\Program Files (x86)\Cypress\Programmer\Examples\Misc\PSoC4-BLE-SFLASH-Update\Executable".
Everything works well and the SFLASH is not reset every time I reprogram the firmware, so the device adrress will never change.
Anyway, now I would like to reset the entire flash because I have to apply the protected mode for the device security.
I tried to use the "PSoC Programmer 3.28.0" inside the directory "C:\Program Files (x86)\Cypress\Programmer": I clicked on "Erase All Flash", then reprogrammed the firmware and checked for the device address but this has not been erased.
So I would like to know what should I do in order to erase my device.
Thank you to everyone.
Show Less