Skip to content
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

Add some missing pio functions #2074

Merged
merged 1 commit into from
Nov 20, 2024

Conversation

peterharperuk
Copy link
Contributor

Adds some 64 versions to work with rp2350b and more than 32 pins. Change cyw43 code to use the new function.

Fixes #1834

Adds some 64 versions to work with rp2350b and more than 32 pins.
Change cyw43 code to use the new function.

Fixes raspberrypi#1834
@kilograham
Copy link
Contributor

merging this prior to some more PIO api cleanup I'm doing for > 32 pins, so it is possible it may change slightly

@kilograham kilograham merged commit 54d4f3a into raspberrypi:develop Nov 20, 2024
4 checks passed
@kilograham kilograham added this to the 2.1.0 milestone Nov 20, 2024
@lurch
Copy link
Contributor

lurch commented Nov 21, 2024

@kilograham When I do a full-build with arm-none-eabi-gcc it's complaining that:

...../pico-sdk/src/rp2_common/hardware_pio/pio.c: In function 'pio_sm_set_pins_with_mask64':
...../pico-sdk/src/rp2_common/hardware_pio/pio.c:259:41: error: conversion from 'uint64_t' {aka 'long long unsigned int'} to 'unsigned int' may change value [-Werror=conversion]
  259 |         uint base = (uint)__builtin_ctz(pin_mask);
      |                                         ^~~~~~~~
compilation terminated due to -Wfatal-errors.
cc1: all warnings being treated as errors

And indeed https://github.com/raspberrypi/pico-sdk/blob/develop/src/rp2_common/pico_platform_compiler/include/pico/platform/compiler.h#L63 says:

static inline uint __builtin_ctz(uint x) {

@kilograham
Copy link
Contributor

kilograham commented Nov 21, 2024

yeah, thanks, i will fix this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants