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

Bluetooth write_characteristic_value fails #699

Open
FireTime opened this issue May 9, 2023 · 18 comments
Open

Bluetooth write_characteristic_value fails #699

FireTime opened this issue May 9, 2023 · 18 comments

Comments

@FireTime
Copy link

FireTime commented May 9, 2023

Bug in Core Bluetooth fails with PY_SSIZE_T_CLEAN macro must be defined for '#' formats whenever write_characteristic_value is called

@FireTime FireTime changed the title Core Bluetooth write_characteristic_value fails with Bug: Core Bluetooth write_characteristic_value May 9, 2023
@FireTime FireTime changed the title Bug: Core Bluetooth write_characteristic_value Bluetooth write_characteristic_value fails May 9, 2023
@firmum-main
Copy link

Running into the same issue.

PY_SSIZE_T_CLEAN indicates that @omz needs to update the cb module to account for an interface change introduced with python 3.10. The documentation seems to be https://docs.python.org/3/c-api/arg.html#strings-and-buffers .

@sonnenwind
Copy link

An update would be very much appreciated! At the current state, I cannot use my Bluetooth serial adapter with my iPad which I used to check the state on various devices..

@kami83
Copy link

kami83 commented Sep 5, 2023

Same problem here. Please make an Update.

BR kami

@mdxs
Copy link

mdxs commented Nov 4, 2023

@omz @zrzka @cclaus Please fix this; the hint provided in the comments before hopefully helps. In my experience it was also due to some iPadOS update, which broke my scripts that help my customers use BLE to operate/test devices; currently, my customers are instructed not to update iPadOS or Pythonista, but this is getting critical. If not addressed, I will stop using Pythonista and will need to provide my customers with some custom Apps to operate/test BLE devices instead.

Testing with Pythonista 3.4 on iPadOS 17.1 shows the PY_SSIZE_T_CLEAN macro must be defined for '#' formats system error message when my script tries to write to the BLE device; it does work on scanning for devices, it can connect and discover services; and it can read using BLE; it is on the write that the error occurs.

@FireTime
Copy link
Author

FireTime commented Nov 6, 2023

The issue is the core Bluetooth library needs to be updated to be compatible with python 3.10. Relevant python docs here.

@kami83
Copy link

kami83 commented Jan 15, 2024

Hi, anything new for this?

BR kami

@Cronocide
Copy link

Following this thread just in case this ever gets fixed. If CoreBluetooth write isn't fully implemented, it shouldn't really be listed as a feature of the app on the app store.

@alessaba
Copy link

Following this thread just in case this ever gets fixed. If CoreBluetooth write isn't fully implemented, it shouldn't really be listed as a feature of the app on the app store.

I am pretty sure it was working before the latest update. Probably a combination of module upgrades
That's a useful but not very used feature, i can understand that some regressions can be missed when releasing an update, just be patient.

I am having the same problem, i will wait for an update :-)

@kami83
Copy link

kami83 commented Jan 23, 2024

Hi, you are right, in the last version it was working. Is there any way to downgrade? I need this function really often. Because i have got a lot of script for Bluetooth recieve and send. BR kami

@fakuoone
Copy link

As far as I know, no update yet? Or am I mistaken

@FireTime
Copy link
Author

Still not working.

@kami83
Copy link

kami83 commented Mar 20, 2024

Also waiting.

@FireTime
Copy link
Author

FireTime commented May 8, 2024

🎂

1 year

@kami83
Copy link

kami83 commented May 8, 2024

Happy Birthday :) Please fix it. BR kami

@paulhamsh
Copy link

Please fix this or explain how to downgrade or use some other library - this is very frustrating as this was my main use of Pythonista

@jhershbe
Copy link

jhershbe commented Oct 14, 2024

How is this still broken? Is pythonista not maintained anymore? Maybe the project is dead.

I assume there are no work-arounds given this thread.

@brunobeat
Copy link

PY_SSIZE_T_CLEAN
Please fix this or is
there any solution possible to define macro ?
Thanks in advance

@FireTime
Copy link
Author

FireTime commented Oct 30, 2024

No work arounds are available. Issue can only be fixed by @omz .

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

No branches or pull requests