-
-
Notifications
You must be signed in to change notification settings - Fork 7
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
[Feature] Enabling other MicroPython features #140
Comments
have u forgotten the EV3 Hub or isn't this meant for it? |
No, I didn't mean to suggest that 😄 EV3 has nearly infinite memory and SD Card flash space compared to these hubs, so it has all of these features enabled already. |
oh okay, makes sense |
A while ago, someone mentioned enabling slicing. This increases frimware size by 4K, so it is quite expensive in that regard. But not out of the question if there is high demand. |
Some other available builtins:
Some available modules:
|
@dracode: we've made some major steps forward with Pybricks recently, so now might be the time to give it another try, and review the feature set if you like. |
I think we may want to consider the Available memory appears to be a contentious topic of discussion in the SPIKE Prime community, so this could help make that more specific, and control over the @devinbreise requested it here, in this case for EV3. |
FYI, this is already possible. import micropython
micropython.mem_info()
micropython.mem_info(1) # shows memory map in ascii art |
I can't say about modules as I'm really newbie to Python, but definitely would like to see included some library that would enable inter-hub BT communication. |
This issue is more about features available in the MicroPython language upon which Pybricks is built. For specific features to Pybricks, such as wireless communication, it would be better to open a separate issue so we don't forget about it. |
Hmm, ubluetooth is a micropython fearure isn’t it? I would be very much interested in that. Especially as the new hubs are essentialy disconnected from all lego specific communication without it. Can‘t use lego remote, can‘t use lego app, can’t interact. |
Also with the misleading error messages in issue #217 in mind I would vote for slicing enabled. |
I'm also interested in the 'ubluetooth' module. Mainly to connect with a remote control (eg. the new xbox series x controller with BLE) or a ESP32 (for example). |
I'm not sure If ubluetooth will work great on the small lego hubs, this is a heavy library. I worked with that library on a spike prime and I often run into memory problems with that until the last two firmware upgrades (I think lego has a bit optimized memory management or the base system consumes less memory). And it only works good as optimized pre-compiled lib which is copied to the hub. The resources on the other lego hubs are much smaller and I'm not sure if this will work as expected |
I got now a xbox controller with BLE support. Service and characteristic discovery works, but I am stuck now. |
Does it not work with .gap_connect ? Is .gap_pair necessary for that ? This is part of a newer version of Micropython, which is not yet released for the prime hub :/ |
Ok good to know. |
I would like to see a Neopixel module (ws2812) LED drivers. This has to be done natively because python is too slow to create the 2microsecond pulses. |
I would like to have the @micropython.asm_thumb enabled.
|
Maybe this will be part of hub2hub, but some kind of RPC (remote procedure calls) would also be nice on top of data transfer. OpenMV has an implementation, but I don't know how general that is: https://docs.openmv.io/library/omv.rpc.html |
On top of basic hub2hub data connections, a communication layer that handles buffers, waits, packing, unpacking, pickling, encode, decode, etc... would be really helpful. Preferably a solid, efficient, real-time data protocol with retention of Python typing. |
|
This would allow us to use |
The delta on today's firmware seems to be only |
pybricks/support#140 This enables slicing on all Powered Up hubs except Move Hub. This will be especially useful when dealing with raw data coming from Bluetooth or UART devices.
Thanks for the suggestions everyone! Quite a few of these are now enabled and we are in the process of documenting them as part of the V3.1 release in #286. A few comments were made about hub-to-hub communication as well. We won't be enabling Feel free to open a dedicated issue for each feature you still think would be worth having. |
We currently have most MicroPython modules and some features disabled. This is because we started on Move Hub, which does not have a lot of space (~106Kb). The other hubs have more space (~232Kb), so they can have more features enabled.
This issue is to collect ideas and suggestions from the community for modules and features we should enable.
The text was updated successfully, but these errors were encountered: