PSoC™ 6 Forum Discussions
text.format{('custom.tabs.no.results')}
Hello Cypress,
I am trying to use an SCB UART but it is very hard to find a suitable and free pin to connect to. For example P3.0 and P3.1 would be suitable, according to the device configurator. Yet, I cannot find P3.1 on the breakout board !
Can you please suggest suitable pins to utilize an SCB UART for an external RS232 connection ?
Any help is greatly appreciated.
Regards,
Stefan
Show LessHello,
I try to implement 2 alarms with the RTC component on the PSOC6,
My issue it's when I call 2 functions to Set the 2 different alarms :
rtcApiResult = Cy_RTC_SetAlarmDateAndTime(&alarm1,CY_RTC_ALARM_1);
rtcApiResult = Cy_RTC_SetAlarmDateAndTime(&alarm2,CY_RTC_ALARM_2);
I got the good return for the first function, but an error for the second (CY_RTC_INVALID_STATE)
If I put a CyDelay(1) between the 2 functions, I don't have any trouble
My question is : how to set the 2 alarms correctly (use the delay it's maybe not the good way to do it)
Thank you
Hello Cypress,
I get a CYHAL_UART_RSLT_ERR_INVALID_PIN error result from calling
/* Initialize the UART Block */
rslt = cyhal_uart_init(&uart_obj, CYBSP_UART1_TX, CYBSP_UART1_RX, CYPSP_UART1_CLK_HW, &uart_config);
if(rslt != CY_RSLT_SUCCESS)
{
handle_error();
}
The pins are named just like this in the Device Configurator. Seems like I am having trouble allocating the resources correctly.
Or there is some well hidden syntax when naming pins or clocks ?
Debugging gets me down to CYHAL_HWMGR_RSLT_ERR_INVALID from the CYHAL_HWMGR. I have made the P8_0 and
P8_1 pins available as they are used in the PSoC 6 WIFI-BT Pioneer Kit - had to remove a resistor and to add two 0Ohms as explained in the kit documentation.
Any help is appreciated.
Regards
Stefan
Show LessI'm trying to read continuous data from a UART proximity sensor using PSoC 6. I'm getting the data mixed with garbage on tera Term .I am not sure how to receive the data correctly . If anyone can also advise on interfacing Pmod based SPI and I2C sensors to PSoC 6
I will attach my code and the output and here is part of the sensor data sheet info:
The Pmod MAXSONAR communicates with the host board via the UART protocol, analog output, and PWM timing. The module requires 250 milliseconds to power up and then will perform a self-calibration if the Receive Data (RX) pin is left at floating or logic level high voltage. The calibration will take 49 ms, and after an additional 100 ms of waiting time, the module will be able to take measurement readings every 49 milliseconds.
The UART protocol is configured with a baud rate of 9600, 8 bits, no parity, and a single stop bit. When the RX pin is left floating or held at a logic level high voltage, 5 bytes will be sent out over the Transfer Data (TX) pin beginning with the capital ASCII character 'R', three ASCII digits representing the detected distance, and a carriage return character (ASCII character 13).
An analog signal representative of the measured distance of the object in front of the Pmod MAXSONAR may also be read. The output itself has nine bits of resolution, so with a power supply at 3.3V each inch is equivalent to ~6.4 mV. Users that are measuring the incoming analog signal with a popular 10-bit ADC will have to divide their measured value by 2 before calculating the reported distance.
The Pmod MAXSONAR also provides distance data through a pulse-width modulation signal. Every 147 uS that the pin is measured at a logic level high voltage state is equivalent to 1 inch away. If the signal is measured to be high for 2.205 milliseconds, then the detected object is 15 inches away from the front of the Pmod MAXSONAR. The maximum measured pulse time of 37.5 milliseconds indicates that there is no object within 255 inches of the Pmod.
Hello,
I'm trying to use CY8C6145LQI in Modus Toolbox. But I can't find device selection.
In the PSoC Creator, I was able to selet the target MCU family and then use the device selector in the Workspace Explorer window to change specific device.
Is there no device selector in the Modus Toolbox? How to create new project with CY8C6145?
Regards,
YS.
Show LessHi,
I am using Toshiba NAND flash with CY8CKIT-062S2-43012. I am using this flash for OTA using HTTP with the sample application "AnyCloud_OTA_Using_HTTPS". OTA is successful with the local mongoose server as mentioned in the application.
Now instead of local mongoose server my requirement is to use AWS. I have placed the bin file and ota_update.json job document in a bucket in S3 AWS and these files are made public. I want to download these via HTTP. Can you please guide me how to implement this.?
I modified the HTTP_SERVER (bucket_name.s3.amazonaws.com) and HTTP_SERVER_PORT (changed to 80) in file ota_app_config.h
Can you please guide me on this?
Thanks,
Binsy M S
Show LessHi everyone,
I got a Posc64 ,and getting step by step by Getting start with the Cypress CY8CKIT-064S0S2-4343W
(https://docs.aws.amazon.com/freertos/latest/userguide/getting_started_cypress_psoc64.html).
Now, I am in step"Build and run the FreeRTOS Demo project".
I would like to perform " Build aws_demos Application" (use Modustoolbox IDE) on my project (aws_demos) ,
and occur some errors in the below context used bold text,and you can see the errors are similar .
How should I solve this problem?
---------------------------------------------------------------------------------------------------------------------------------------
11:34:32 **** Incremental Build of configuration Debug for project aws_demos ****
"C:\\Users\\Mike\\ModusToolbox\\tools_2.3\\modus-shell\\bin\\make" CY_MAKE_IDE=eclipse CY_IDE_TOOLS_DIR=C:/Users/Mike/ModusToolbox/tools_2.3 CY_IDE_BT_TOOLS_DIR= -j2 all
Tools Directory: C:/Users/Mike/ModusToolbox/tools_2.3
CY8CKIT_064S0S2_4343W.mk: ../../../../../vendors/cypress/boards/CY8CKIT_064S0S2_4343W/aws_demos/application_code/cy_code/CY8CKIT_064S0S2_4343W.mk
Prebuild operations complete
Commencing build operations...
Tools Directory: C:/Users/Mike/ModusToolbox/tools_2.3
CY8CKIT_064S0S2_4343W.mk: ../../../../../vendors/cypress/boards/CY8CKIT_064S0S2_4343W/aws_demos/application_code/cy_code/CY8CKIT_064S0S2_4343W.mk
Initializing build: aws_demos Debug CY8CKIT_064S0S2_4343W GCC_ARM
Auto-discovery in progress...
-> Found 249 .c file(s)
-> Found 42 .S file(s)
-> Found 18 .s file(s)
-> Found 0 .cpp file(s)
-> Found 0 .o file(s)
-> Found 24 .a file(s)
-> Found 600 .h file(s)
-> Found 0 .hpp file(s)
-> Found 0 resource file(s)
Applying filters...
Auto-discovery complete
Constructing build rules...
Build rules construction complete
==============================================================================
= Building application =
==============================================================================
Generating compilation database file...
-> C:/Users/Mike/amazon-freertos/build/cy/aws_demos/compile_commands.json
Compilation database file generation complete
Building 521 file(s)
C:/Users/Mike/ModusToolbox/tools_2.3/gcc/bin/arm-none-eabi-objcopy -R .cy_sflash_user_data -R .cy_toc_part2 C:/Users/Mike/amazon-freertos/build/cy/aws_demos/CY8CKIT_064S0S2_4343W/Debug/aws_demos.elf C:/Users/Mike/amazon-freertos/build/cy/aws_demos/CY8CKIT_064S0S2_4343W/Debug/cm4.elf; C:/Users/Mike/ModusToolbox/tools_2.3/gcc/bin/arm-none-eabi-objcopy -O ihex C:/Users/Mike/amazon-freertos/build/cy/aws_demos/CY8CKIT_064S0S2_4343W/Debug/cm4.elf C:/Users/Mike/amazon-freertos/build/cy/aws_demos/CY8CKIT_064S0S2_4343W/Debug/cm4.hex; cp "../../../../../vendors/cypress/MTB/psoc6/psoc64tfm/COMPONENT_TFM_S_FW/tfm_s_unsigned.hex" "C:/Users/Mike/amazon-freertos/build/cy/aws_demos/CY8CKIT_064S0S2_4343W/Debug/cm0.hex"; cysecuretools --policy "../../../../../vendors/cypress/MTB/psoc6/psoc64tfm/security/policy/policy_multi_CM0_CM4_jitp.json" --target "cy8ckit-064s0s2-4343w" sign-image --hex "C:/Users/Mike/amazon-freertos/build/cy/aws_demos/CY8CKIT_064S0S2_4343W/Debug/cm0.hex" --image-type UPGRADE --image-id 1; cysecuretools --policy "../../../../../vendors/cypress/MTB/psoc6/psoc64tfm/security/policy/policy_multi_CM0_CM4_jitp.json" --target "cy8ckit-064s0s2-4343w" sign-image --hex "C:/Users/Mike/amazon-freertos/build/cy/aws_demos/CY8CKIT_064S0S2_4343W/Debug/cm4.hex" --image-type UPGRADE --image-id 16; cp "C:/Users/Mike/amazon-freertos/build/cy/aws_demos/CY8CKIT_064S0S2_4343W/Debug/cm0_unsigned.hex" "C:/Users/Mike/amazon-freertos/build/cy/aws_demos/CY8CKIT_064S0S2_4343W/Debug/cm0.hex"; cp "C:/Users/Mike/amazon-freertos/build/cy/aws_demos/CY8CKIT_064S0S2_4343W/Debug/cm4_unsigned.hex" "C:/Users/Mike/amazon-freertos/build/cy/aws_demos/CY8CKIT_064S0S2_4343W/Debug/cm4.hex"; cysecuretools --policy "../../../../../vendors/cypress/MTB/psoc6/psoc64tfm/security/policy/policy_multi_CM0_CM4_jitp.json" --target "cy8ckit-064s0s2-4343w" sign-image --hex "C:/Users/Mike/amazon-freertos/build/cy/aws_demos/CY8CKIT_064S0S2_4343W/Debug/cm0.hex" --image-type BOOT --image-id 1; cysecuretools --policy "../../../../../vendors/cypress/MTB/psoc6/psoc64tfm/security/policy/policy_multi_CM0_CM4_jitp.json" --target "cy8ckit-064s0s2-4343w" sign-image --hex "C:/Users/Mike/amazon-freertos/build/cy/aws_demos/CY8CKIT_064S0S2_4343W/Debug/cm4.hex" --image-type BOOT --image-id 16;
2021-06-18 11:34:36,595 : C : ERROR : Validation against schema failed. Check the log for details
2021-06-18 11:34:36,595 : C : ERROR : 'STATUS_PARTITION' is not one of ['SRAM_DAP', 'FLASH_PC1_SPM', 'FLASH_PC2', 'FLASH_PC3', 'FLASH_PC4', 'FLASH_MAIN_CODE', 'FLASH_MAIN_XO', 'FLASH_MAIN_DATA', 'FLASH_SUPERVISORY', 'FLASH_WORK_SECURE', 'FLASH_WORK', 'SRAM_PC0_PRIV', 'SRAM_PC0_PUB', 'SRAM_SPM_PRIV', 'SRAM_SPM_PUB', 'SRAM_PC1_PRIV', 'SRAM_PC2_PRIV', 'SRAM_PC3_PRIV', 'SRAM_PC4_PRIV', 'SRAM_MAIN', 'SMIF_CODE', 'SMIF_XO', 'SMIF_DATA', 'BOOT', 'UPGRADE']
Failed validating 'enum' in schema['properties']['boot_upgrade']['properties']['firmware']['items']['properties']['resources']['items']['properties']['type']:
{'enum': ['SRAM_DAP',
'FLASH_PC1_SPM',
'FLASH_PC2',
'FLASH_PC3',
'FLASH_PC4',
'FLASH_MAIN_CODE',
'FLASH_MAIN_XO',
'FLASH_MAIN_DATA',
'FLASH_SUPERVISORY',
'FLASH_WORK_SECURE',
'FLASH_WORK',
'SRAM_PC0_PRIV',
'SRAM_PC0_PUB',
'SRAM_SPM_PRIV',
'SRAM_SPM_PUB',
'SRAM_PC1_PRIV',
'SRAM_PC2_PRIV',
Error: Failed processing!
'SRAM_PC3_PRIV',
'SRAM_PC4_PRIV',
'SRAM_MAIN',
'SMIF_CODE',
'SMIF_XO',
'SMIF_DATA',
'BOOT',
'UPGRADE'],
'id': 'type',
'required': True,
'type': 'string'}
On instance['boot_upgrade']['firmware'][0]['resources'][3]['type']:
'STATUS_PARTITION'. Check the log for details
2021-06-18 11:34:36,596 : C : ERROR : Policy validation finished with error. Check the log for details
2021-06-18 11:34:37,091 : C : ERROR : Validation against schema failed. Check the log for details
2021-06-18 11:34:37,091 : C : ERROR : 'STATUS_PARTITION' is not one of ['SRAM_DAP', 'FLASH_PC1_SPM', 'FLASH_PC2', 'FLASH_PC3', 'FLASH_PC4', 'FLASH_MAIN_CODE', 'FLASH_MAIN_XO', 'FLASH_MAIN_DATA', 'FLASH_SUPERVISORY', 'FLASH_WORK_SECURE', 'FLASH_WORK', 'SRAM_PC0_PRIV', 'SRAM_PC0_PUB', 'SRAM_SPM_PRIV', 'SRAM_SPM_PUB', 'SRAM_PC1_PRIV', 'SRAM_PC2_PRIV', 'SRAM_PC3_PRIV', 'SRAM_PC4_PRIV', 'SRAM_MAIN', 'SMIF_CODE', 'SMIF_XO', 'SMIF_DATA', 'BOOT', 'UPGRADE']
Failed validating 'enum' in schema['properties']['boot_upgrade']['properties']['firmware']['items']['properties']['resources']['items']['properties']['type']:
{'enum': ['SRAM_DAP',
'FLASH_PC1_SPM',
'FLASH_PC2',
'FLASH_PC3',
'FLASH_PC4',
'FLASH_MAIN_CODE',
'FLASH_MAIN_XO',
'FLASH_MAIN_DATA',
'FLASH_SUPERVISORY',
'FLASH_WORK_SECURE',
'FLASH_WORK',
'SRAM_PC0_PRIV',
'SRAM_PC0_PUB',
'SRAM_SPM_PRIV',
'SRAM_SPM_PUB',
'SRAM_PC1_PRIV',
'SRAM_PC2_PRIV',
'SRAM_PC3_PRIV',
'SRAM_PC4_PRIV',
'SRAM_MAIN',
'SMIF_CODE',
'SMIF_XO',
'SMIF_DATA',
'BOOT',
'UPGRADE'],
'id': 'type',
'required': True,
'type': 'string'}
On instance['boot_upgrade']['firmware'][0]['resources'][3]['type']:
'STATUS_PARTITION'. Check the log for details
2021-06-18 11:34:37,092 : C : ERROR : Policy validation finished with error. Check the log for details
Error: Failed processing!
cp: cannot stat 'C:/Users/Mike/amazon-freertos/build/cy/aws_demos/CY8CKIT_064S0S2_4343W/Debug/cm0_unsigned.hex': No such file or directory
cp: cannot stat 'C:/Users/Mike/amazon-freertos/build/cy/aws_demos/CY8CKIT_064S0S2_4343W/Debug/cm4_unsigned.hex': No such file or directory
2021-06-18 11:34:37,605 : C : ERROR : Validation against schema failed. Check the log for details
2021-06-18 11:34:37,605 : C : ERROR : 'STATUS_PARTITION' is not one of ['SRAM_DAP', 'FLASH_PC1_SPM', 'FLASH_PC2', 'FLASH_PC3', 'FLASH_PC4', 'FLASH_MAIN_CODE', 'FLASH_MAIN_XO', 'FLASH_MAIN_DATA', 'FLASH_SUPERVISORY', 'FLASH_WORK_SECURE', 'FLASH_WORK', 'SRAM_PC0_PRIV', 'SRAM_PC0_PUB', 'SRAM_SPM_PRIV', 'SRAM_SPM_PUB', 'SRAM_PC1_PRIV', 'SRAM_PC2_PRIV', 'SRAM_PC3_PRIV', 'SRAM_PC4_PRIV', 'SRAM_MAIN', 'SMIF_CODE', 'SMIF_XO', 'SMIF_DATA', 'BOOT', 'UPGRADE']
Failed validating 'enum' in schema['properties']['boot_upgrade']['properties']['firmware']['items']['properties']['resources']['items']['properties']['type']:
{'enum': ['SRAM_DAP',
'FLASH_PC1_SPM',
'FLASH_PC2',
'FLASH_PC3',
'FLASH_PC4',
'FLASH_MAIN_CODE',
'FLASH_MAIN_XO',
'FLASH_MAIN_DATA',
'FLASH_SUPERVISORY',
'FLASH_WORK_SECURE',
'FLASH_WORK',
'SRAM_PC0_PRIV',
'SRAM_PC0_PUB',
'SRAM_SPM_PRIV',
'SRAM_SPM_PUB',
'SRAM_PC1_PRIV',
'SRAM_PC2_PRIV',
'SRAM_PC3_PRIV',
'SRAM_PC4_PRIV',
'SRAM_MAIN',
'SMIF_CODE',
Error: Failed processing!
'SMIF_XO',
'SMIF_DATA',
'BOOT',
'UPGRADE'],
'id': 'type',
'required': True,
'type': 'string'}
On instance['boot_upgrade']['firmware'][0]['resources'][3]['type']:
'STATUS_PARTITION'. Check the log for details
2021-06-18 11:34:37,606 : C : ERROR : Policy validation finished with error. Check the log for details
2021-06-18 11:34:38,097 : C : ERROR : Validation against schema failed. Check the log for details
2021-06-18 11:34:38,097 : C : ERROR : 'STATUS_PARTITION' is not one of ['SRAM_DAP', 'FLASH_PC1_SPM', 'FLASH_PC2', 'FLASH_PC3', 'FLASH_PC4', 'FLASH_MAIN_CODE', 'FLASH_MAIN_XO', 'FLASH_MAIN_DATA', 'FLASH_SUPERVISORY', 'FLASH_WORK_SECURE', 'FLASH_WORK', 'SRAM_PC0_PRIV', 'SRAM_PC0_PUB', 'SRAM_SPM_PRIV', 'SRAM_SPM_PUB', 'SRAM_PC1_PRIV', 'SRAM_PC2_PRIV', 'SRAM_PC3_PRIV', 'SRAM_PC4_PRIV', 'SRAM_MAIN', 'SMIF_CODE', 'SMIF_XO', 'SMIF_DATA', 'BOOT', 'UPGRADE']
Failed validating 'enum' in schema['properties']['boot_upgrade']['properties']['firmware']['items']['properties']['resources']['items']['properties']['type']:
{'enum': ['SRAM_DAP',
'FLASH_PC1_SPM',
'FLASH_PC2',
'FLASH_PC3',
'FLASH_PC4',
'FLASH_MAIN_CODE',
'FLASH_MAIN_XO',
'FLASH_MAIN_DATA',
'FLASH_SUPERVISORY',
'FLASH_WORK_SECURE',
'FLASH_WORK',
'SRAM_PC0_PRIV',
'SRAM_PC0_PUB',
'SRAM_SPM_PRIV',
'SRAM_SPM_PUB',
'SRAM_PC1_PRIV',
'SRAM_PC2_PRIV',
'SRAM_PC3_PRIV',
'SRAM_PC4_PRIV',
'SRAM_MAIN',
'SMIF_CODE',
'SMIF_XO',
'SMIF_DATA',
'BOOT',
'UPGRADE'],
'id': 'type',
'required': True,
'type': 'string'}
On instance['boot_upgrade']['firmware'][0]['resources'][3]['type']:
'STATUS_PARTITION'. Check the log for details
2021-06-18 11:34:38,103 : C : ERROR : Policy validation finished with error. Check the log for details
Error: Failed processing!
make[1]: *** [../../../../../vendors/cypress/MTB/psoc6/psoc6make/make/core/build.mk:556: CY_BUILD_app_postbuild] Error 1
make: *** [../../../../../vendors/cypress/MTB/psoc6/psoc6make/make/core/main.mk:414: secondstage_build] Error 2
"C:/Users/Mike/ModusToolbox/tools_2.3/modus-shell/bin/make CY_MAKE_IDE=eclipse CY_IDE_TOOLS_DIR=C:/Users/Mike/ModusToolbox/tools_2.3 CY_IDE_BT_TOOLS_DIR= -j2 all" terminated with exit code 2. Build might be incomplete.
11:34:38 Build Failed. 6 errors, 0 warnings. (took 5s.266ms)
Show Less
Hello,
I tried to get RSSI value when using Bluetooth Mouse HID Example in situation when mouse is connected.
I add to file: host_main.c file in callback function: void AppCallBack(uint32_t event, void* eventParam)
case CY_BLE_EVT_GATTC_HANDLE_VALUE_NTF:
Cy_BLE_GetRssiPeer(0);
break;
case CY_BLE_EVT_GET_RSSI_COMPLETE:
DBG_PRINTF("CONNECTION %x \r\n",(*(cy_stc_ble_gap_auth_info_t *)eventParam).bdHandle);
DBG_PRINTF("RSSI VALUE: %d \r\n\r\n", (((cy_stc_ble_rssi_info_t*) ((cy_stc_ble_events_param_generic_t*) eventParam)->eventParams)->rssi));
break;
The problem is that CY_BLE_EVT_GATTC_HANDLE_VALUE_NTF or CY_BLE_EVT_GET_RSSI_COMPLETE events are never called.
I will be very thank full for any suggestions.
My main idea is to get bluetooth mouse that automatically connect/disconnect to nearest PC. Main problem is to get rssi and when it will be below given value mouse should disconnect.
Regards,
Bartek
Show Less
Hi,
I am currently using CY8C624ABZI-S2D44 (PSOC6) with DFU as APP0 and APP1 which supports USB-CDC UART based APP1 firmware update. Everything is working fine so far. But as I am expanding my application and need more FLASH memory as this PSOC6 comes with 2MB flash, I am unable to expand FLASH beyond 960KB and its unhappy when I tried to move FLASH_BOOT_META data inorder to allocate more than 1MB flash. Please refer this as my current “.ld” files configuration and provide valuable inputs on this.
flash_cm0p (rx) : ORIGIN = 0x10000000, LENGTH = 0x2000
flash_app0 (rx) : ORIGIN = 0x10002000, LENGTH = 0x10000
flash_app1 (rx) : ORIGIN = 0x10012000, LENGTH = 0xFA000
flash_boot_meta (rw) : ORIGIN = 0x100FFA00, LENGTH = 0x400
Show Less