-
-
Notifications
You must be signed in to change notification settings - Fork 8.2k
ports/esp32/ulp: Initial draft PR for RISCV ULP support S2/S3. #11572
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
Support for compiling and loading RISCV ULP code. Signed-off-by: Patrick Joy <patrick@joytech.com.au>
…V_ULP # Conflicts: # ports/esp32/esp32_ulp.c
Support for compiling and loading RISCV ULP code. Signed-off-by: Patrick Joy <patrick@joytech.com.au>
…V_ULP # Conflicts: # ports/esp32/esp32_ulp.c
Signed-off-by: Patrick Joy <patrick@joytech.com.au>
Signed-off-by: Patrick Joy <patrick@joytech.com.au>
Signed-off-by: Patrick Joy <patrick@joytech.com.au>
Signed-off-by: Patrick Joy <patrick@joytech.com.au>
This PR is ready for an initial review/feedback. RISCV ULP code is conditionally built and included in the firmware image if ulp_riscv/main.c is present. IDF support for the RISCV ULP seems to be still relatively new/WIP. For example only the basic GPIO/ADC functions are available in V4.4.4, i2c support is not supported until v5.1 and there is no v5.1 release yet. |
Signed-off-by: Patrick Joy <patrick@joytech.com.au>
This is an automated heads-up that we've just merged a Pull Request See #13763 A search suggests this PR might apply the STATIC macro to some C code. If it Although this is an automated message, feel free to @-reply to me directly if |
The S2 and S3 chips contain a RISCV ULP co-processor in addition to the FSM ULP.
This PR is an initial attempt to provide access to the RISCV co-processor from micropython.
Operation
Compilation
The ULP needs to be enabled in your sdkconfig.board
Build micropython as normal.
Example - Blinky
Tested with IDF v4.4.4, micropython latest
ports/esp32/ulp_riscv/main.c
After calling run() GPIO_14 will blink rapidly.
After entering deepsleep, GPIO_14 will continue to blink.
Sharing variables between ULP and main processor
Variables declared in the ULP code are made available in the main code using pointers to locations in the RTC memory. For example:
ULP code
Micropython
Next steps/improvements