PSoC™ 6 Forum Discussions
Hello,
i'm trying to minimize the power usage of our Psoc6 based ble-enabled battery-powered pcb. I made use of the ULP mode and lower CPU Frequency and the use of Sleep mode (with timers still enabled).
But i came across a strange behaviour when measuring the power usage in different scenarious. When running the program normally (without debugger attached) the whole pcb is drawing about 2,3mA (combined of all components and the psoc6 included). but if I attach the debugger and run it without a breakpoint (the program behaves the same way), the power consumption drops significantly (to ~ 1,1mA). It doesn't make any sense to me.
Does anyone know why this is like this ? And how can I get the same effect of this "magic power mode" in my application ?
Regards,
Matthias
Show LessHello community members,
I have been using ModusToolBox 2.4 for the last 6 months, but still trying to solve why indexing is not working in ModusToolBox IDE. I have been working with PSoC 6 development boards and writing firmware for the boards, but the different functions, enums, structures, etc. and not indexed within the IDE. I have to go through different source or header files to look at that functions and enums. This is very frustrating for me.
look at those red errors, they are not going anywhere, the code building correctly every time, but the indexing of every file is not working. Please help me to solve this issue. Do I have to change some settings in the Preference window or what, please help!!
Thanks & Regards,
Vivek Karna
Hi all,
MTB3.0 is ModusToolBox 3.0
I have a custom board that works with MTB2.4 (and MTB3.0). Now I'm using MTB3.0 and I'm programming the board. The code is just a couple of lines to blink two LEDs on the board. The LEDs blink just fine. The project is the Dual core empty app with the modifications to the linker files in this post. I also commented out a line in the makefile as indicated in this other post but that gave me "Error: [psoc6.cpu.cm4] clearing lockup after double fault" so instead I changed it to match the size in the script file: "DEFINES+=CY_CORTEX_M4_APPL_ADDR=CY_FLASH_BASE+0x8000U". As I said the LEDs blink just fine. But Eclipse is showing some stuff after programming that I don't know what to make of it. I was expecting a "programming ok" or something like that. Eclipse also opens up a new tab titled "0x190" (picture below). I'll include a copy of the weird text after the picture... it is long.
My question is ... what is that text at the end and why does Eclipse opens the new tab?
This is the new tab.
Here is the text. I'm including everything that shows up after I click program (kitprog3...). I'm interested to know what the stuff is towards the end. I'll mark it as bold: Thanks.
Started by GNU MCU Eclipse
Open On-Chip Debugger 0.11.0+dev-4.4.0.2134 (2022-09-08-13:07)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
kitprog3 set_latest_version: C:/Users/wgates/ModusToolbox/tools_3.0/fw-loader 2.40.1241
adapter speed: 2000 kHz
adapter srst delay: 25
adapter srst pulse_width: 25
** Auto-acquire enabled, use "set ENABLE_ACQUIRE 0" to disable
cortex_m reset_config sysresetreq
cortex_m reset_config sysresetreq
Info : Using CMSIS-flash algorithms 'CY8C6xxA_SMIF' for bank 'psoc6_smif0_cm0' (footprint 17056 bytes)
Info : CMSIS-flash: ELF path: ../flm/cypress/cat1a/CY8C6xxA_SMIF.FLM
Info : CMSIS-flash: Address range: 0x18000000-0x1FFFFFFF
Info : CMSIS-flash: Program page size: 0x00001000 bytes
Info : CMSIS-flash: Erase sector size: 0x00040000 bytes, unified
Warn : SFlash programming allowed for regions: USER, TOC, KEY
Info : Using CMSIS-DAPv2 interface with VID:PID=0x04b4:0xf155, serial=050A0DF301237400
Info : CMSIS-DAP: SWD supported
Info : CMSIS-DAP: Atomic commands supported
Info : CMSIS-DAP: FW Version = 2.0.0
Info : CMSIS-DAP: Interface Initialised (SWD)
Info : SWCLK/TCK = 1 SWDIO/TMS = 1 TDI = 0 TDO = 0 nTRST = 0 nRESET = 1
Info : CMSIS-DAP: Interface ready
Info : KitProg3: FW version: 2.40.1241
Info : KitProg3: Pipelined transfers enabled
Info : KitProg3: Asynchronous USB transfers enabled
Info : VTarget = 3.032 V
Info : kitprog3: acquiring the device (mode: reset)...
Info : clock speed 2000 kHz
Info : SWD DPIDR 0x6ba02477
Info : [psoc6.cpu.cm0] Cortex-M0+ r0p1 processor detected
Info : [psoc6.cpu.cm0] target has 4 breakpoints, 2 watchpoints
Info : [psoc6.cpu.cm0] external reset detected
***************************************
** Silicon: 0xE40B, Family: 0x102, Rev.: 0x11 (A0)
** Detected Device: CY8C624AAZI-D44
** Detected Main Flash size, kb: 2048
** Flash Boot version: 3.1.0.45
** Chip Protection: VIRGIN
***************************************
Info : [psoc6.cpu.cm4] Cortex-M4 r0p1 processor detected
Info : [psoc6.cpu.cm4] target has 6 breakpoints, 4 watchpoints
Info : [psoc6.cpu.cm4] external reset detected
Info : starting gdb server for psoc6.cpu.cm0 on 3333
Info : Listening on port 3333 for gdb connections
Info : starting gdb server for psoc6.cpu.cm4 on 3334
Info : Listening on port 3334 for gdb connections
Info : SWD DPIDR 0x6ba02477
Info : kitprog3: acquiring the device (mode: reset)...
psoc6.cpu.cm0 halted due to debug-request, current mode: Thread
xPSR: 0x41000000 pc: 0x00000190 msp: 0x080ff800
** Device acquired successfully
** psoc6.cpu.cm4: Ran after reset and before halt...
psoc6.cpu.cm4 halted due to debug-request, current mode: Thread
xPSR: 0x01000000 pc: 0x0000012a msp: 0x080ff800
Started by GNU MCU Eclipse
Info : Listening on port 6666 for tcl connections
Info : Listening on port 4444 for telnet connections
Info : accepting 'gdb' connection on tcp/3333
Info : New GDB Connection: 1, Target psoc6.cpu.cm0, state: halted
Warn : Prefer GDB command "target extended-remote :3333" instead of "target remote :3333"
Verifying region (0x10000000, 23768)... Match
Verifying region (0x10008000, 10900)... Mismatch
Info : Data mismatch, proceeding with flash programming
Info : Flash write discontinued at 0x10005cd8, next section at 0x10008000
Info : Padding image section 0 at 0x10005cd8 with 296 bytes (bank write end alignment)
[ 31%] [######### ] [ Erasing ]
[ 34%] [########## ] [ Erasing ]
[ 36%] [########### ] [ Erasing ]
[ 40%] [############ ] [ Erasing ]
[ 42%] [############# ] [ Erasing ]
[ 46%] [############## ] [ Erasing ]
[ 48%] [############### ] [ Erasing ]
[ 53%] [################ ] [ Erasing ]
[ 55%] [################# ] [ Erasing ]
[ 57%] [################## ] [ Erasing ]
[ 63%] [#################### ] [ Erasing ]
[ 68%] [##################### ] [ Erasing ]
[ 70%] [###################### ] [ Erasing ]
[ 72%] [####################### ] [ Erasing ]
[ 76%] [######################## ] [ Erasing ]
[ 82%] [########################## ] [ Erasing ]
[ 85%] [########################### ] [ Erasing ]
[ 89%] [############################ ] [ Erasing ]
[ 93%] [############################# ] [ Erasing ]
[ 95%] [############################## ] [ Erasing ]
[100%] [################################] [ Erasing ]
[100%] [################################] [ Programming ]
Info : Padding image section 1 at 0x1000aa94 with 364 bytes (bank write end alignment)
[ 68%] [##################### ] [ Erasing ]
[ 72%] [####################### ] [ Erasing ]
[ 77%] [######################## ] [ Erasing ]
[ 81%] [######################### ] [ Erasing ]
[ 86%] [########################### ] [ Erasing ]
[ 90%] [############################ ] [ Erasing ]
[100%] [################################] [ Erasing ]
[100%] [################################] [ Programming ]
Info : SWD DPIDR 0x6ba02477
Info : kitprog3: acquiring the device (mode: reset)...
psoc6.cpu.cm0 halted due to debug-request, current mode: Thread
xPSR: 0x41000000 pc: 0x00000190 msp: 0x080ff800
** Device acquired successfully
** psoc6.cpu.cm4: Ran after reset and before halt...
psoc6.cpu.cm4 halted due to debug-request, current mode: Thread
xPSR: 0x01000000 pc: 0x0000012a msp: 0x080ff800
Info : SWD DPIDR 0x6ba02477
psoc6.cpu.cm0 halted due to debug-request, current mode: Thread
xPSR: 0x81000000 pc: 0x10002776 msp: 0x08001fe0
Info : dropped 'gdb' connection
Hi ,
I have been spending the last few days trying to figure out how to increase the flash size according to the linkers scripts for GCC -Arm compiler.
According to the documentation and a few of the posts this should not be that difficult but it is proving to be an big challenge .
According to the documentation in the dual system design guide,in the CMOP linker script the following should be the correct changes , with 512 byte blocks for the flash
ram (rwx) : ORIGIN = 0x08000000, LENGTH = 0x8000
flash (rx) : ORIGIN = 0x10000000, LENGTH = 0x40000
According to the documentation in the dual system design guide I only need to change the following for the CM4 linker script
/* The size of the Cortex-M0+ application image at the start of FLASH */
FLASH_CM0P_SIZE =0x40000;
However if I change to anything above 0x2000 for the flash on the CM0 both cores stop working .
Compiling does not complain about the changes which seem to indicate its correct but when programming a hard fault gets generated . I am unable to pin point the hard fault and this only happens when the flash is changed in the linker scripts .
[100%] [################################] [ Programming ]
Info : SWD DPIDR 0x6ba02477
Info : kitprog3: acquiring the device (mode: reset)...
psoc6.cpu.cm0 halted due to debug-request, current mode: Thread
xPSR: 0x01000000 pc: 0x00001f34 msp: 0x080477a8
** Device acquired successfully
** psoc6.cpu.cm4: Ran after reset and before halt...
psoc6.cpu.cm4 halted due to debug-request, current mode: Thread
xPSR: 0x61000000 pc: 0x1600400c msp: 00000000
Info : SWD DPIDR 0x6ba02477
Error: [psoc6.cpu.cm4] clearing lockup after double fault
psoc6.cpu.cm4 halted due to debug-request, current mode: Handler HardFault
xPSR: 0x41000003 pc: 0x8008f3ee msp: 0x080457e0
psoc6.cpu.cm0 halted due to debug-request, current mode: Thread
xPSR: 0x01000000 pc: 0x080002ba msp: 0x08001fb8
Info : dropped 'gdb' connection
Any assistance is welcome
C
Show LessHi
I am using CY8CPROTO-062-4343W board I downloaded Wi-Fi scan program in ModusToolbox ide .While tracing the code in UART it showing like below. How can I sort out this issue
Show Less
Hi,
I'm trying to debug code on CY8CPROTO-063-BLE board but it doesn't work. Is it possible to hw debug on CY8CPROTO-063-BLE?
I tried with ModusToolbox 3.0 and ModusToolbox 2.1 but the debugger can not connect to the board.
Show Less
Someone has the "Find Me" project for Psoc 6 CY8CPROTO-063-BLE, it turns out that I recently acquired this Psoc and messing around I accidentally deleted it. I couldn't do anything with it, please help.
Show LessHi,
I have attached an attachment which consists of the pin mapping of PSoC 6. As I have mapped but I don't know if its correct or not can you help me out with it. It would be helpful if I receive the reply fast as its on prior.
Please verify it ASAP.
Regards
Nirmith
Show Less