diff --git a/examples/usercimaimodule/imagimob/README.md b/examples/usercimaimodule/imagimob/README.md index b74a865761ea4..9807dd3dd5203 100644 --- a/examples/usercimaimodule/imagimob/README.md +++ b/examples/usercimaimodule/imagimob/README.md @@ -15,13 +15,24 @@ Currently the existing sample model files are generated for [Human Activity Reco ## Installation -Please check for the pre-requisites mentioned [here](https://github.com/Infineon/micropython/tree/ports-psoc6-main/ports/psoc6#pre-requisites). +### Dependencies + +- WSL (Windows Subsystem Layer) +- USBIPD +- ModusToolbox (version 3.0) +- MicroPython project with psoc6 port enabled + +The development environment for the project is [WSL](https://learn.microsoft.com/en-us/windows/wsl/install). Please follow the steps in link to get WSL ready. Additionally [usbip](https://learn.microsoft.com/en-us/windows/wsl/connect-usb) installation should be done to allow accessing psoc device within WSL. + +Please ensure to follow the pre-requisites mentioned [here](https://github.com/Infineon/micropython/tree/ports-psoc6-main/ports/psoc6#pre-requisites) and get the required installation. + +By now, all the required installations should be working. ## Usage Follow the steps below to generate micropython bindings for your imagimob generated model. -1. The imagimob micropytthon integration is available in imai-mp-integration, so checkout to that branch after cloning this repository. +1. Clone the repository and switch to ports-psoc6-main branch. git clone https://github.com/Infineon/micropython.git @@ -33,6 +44,12 @@ Follow the steps below to generate micropython bindings for your imagimob genera make mtb_init BOARD= + where board-name is your target device. Currently following boards are supported: + + - CY8CKIT-062S2-AI + - CY8CPROTO-062-4343W + - CY8CPROTO-063-BLE + 3. Retrieve submodules: make submodules diff --git a/examples/usercimaimodule/imagimob/imai_mp_iface.c b/examples/usercimaimodule/imagimob/imai_mp_iface.c index 6ff9ad65002f0..cdd558b6be36f 100644 --- a/examples/usercimaimodule/imagimob/imai_mp_iface.c +++ b/examples/usercimaimodule/imagimob/imai_mp_iface.c @@ -34,7 +34,6 @@ static mp_obj_t dequeue(mp_obj_t data_out_obj) { if (result == 0) { return MP_OBJ_NEW_SMALL_INT(result); } else if (result == -1) { - mp_printf(&mp_plat_print, "No data is currently available\n"); return MP_OBJ_NEW_SMALL_INT(result); } else if (result == -2) { mp_raise_msg_varg(&mp_type_ValueError, MP_ERROR_TEXT("Internal memory allocation error"), result); diff --git a/ports/psoc6/Makefile b/ports/psoc6/Makefile index 731837a1e4196..526f82196d53c 100644 --- a/ports/psoc6/Makefile +++ b/ports/psoc6/Makefile @@ -64,7 +64,7 @@ ifeq ($(MICROPY_PSOC6_LWIP),1) endif LD = arm-none-eabi-gcc -CFLAGS_CORTEX_M4 = -mthumb -mtune=cortex-m4 -mcpu=cortex-m4 -msoft-float -fsingle-precision-constant -Wdouble-promotion -Wfloat-conversion -UMICROPY_USE_INTERNAL_PRINTF +CFLAGS_CORTEX_M4 = -mthumb -mtune=cortex-m4 -mcpu=cortex-m4 -msoft-float -fsingle-precision-constant -Wdouble-promotion -Wfloat-conversion -UMICROPY_USE_INTERNAL_PRINTF -Wno-error=float-conversion # std=c11 instead of std=c99 : provides "static_assert" (not available in c99) # -D_XOPEN_SOURCE=700 : makes sure the setenv/unsetenv headers are included diff --git a/ports/psoc6/README.md b/ports/psoc6/README.md index bd8bfe06fff95..5c154e3d2ec11 100644 --- a/ports/psoc6/README.md +++ b/ports/psoc6/README.md @@ -6,7 +6,7 @@ This port is intended to run on Infineon PSoC™ 6 microcontrollers. The following port is using Infineon ModusToolbox™ to resolve the specific PSoC™ board resources and building flags. Before working with micropython: -1. Install [ModusToolbox](https://www.infineon.com/cms/en/design-support/tools/sdk/modustoolbox-software/). Minimum version required is 3.0. +1. Install [ModusToolbox](https://softwaretools.infineon.com/tools/com.ifx.tb.tool.modustoolbox?_ga=2.77665684.1651703860.1718094141-10754106.1710937391). Minimum version required is 3.0. 2. Run the following script from MicroPython repository root to add the required tools to the system PATH, and install the udev rules: