Coder Social home page Coder Social logo

Comments (10)

artfwo avatar artfwo commented on August 22, 2024 1

@artfwo I assume that most people would/should be using pymonome instead?

generally, yes, reasons are: there's a tutorial on grid studies, the API is a bit more pythonic, it uses the OSC protocol and so handles multiple devices gracefully.

Are there any advantages to libmonome's Python bindings over pymonome?

It doesn't need serialosc, but then again, i don't know if that's an advantage - the rest of "bindings" we have on grid studies also depend on serialosc.

For extreme cases you can always use pyserial with standardised event loops, which I think I would prefer over libmonome's module.

from libmonome.

tehn avatar tehn commented on August 22, 2024

i'd be fine dropping it, but i'm also not aware if anyone is actually using it. as far as i know @artfwo is the foremost monome-in-python user :)

from libmonome.

simonvanderveldt avatar simonvanderveldt commented on August 22, 2024

@artfwo Do you think there would be an advantage in refresh rate for libmonome's Python bindings over pymonome?

from libmonome.

artfwo avatar artfwo commented on August 22, 2024

@simonvanderveldt when directly accessing devices through libmonome you don't hit the the UDP buffer size limits (which you will hit with serialosc), you will hit the serial i/o buffer though. in practice the framerates in both cases can go crazy high (beyond visible refreshing), for example i currently run the arc at 100 fps through serialosc/pymonome in my live setup, but if I set the framerate to 1000 it will still work - actual framerate will be probably lower due to some UDP packets skipped, but i won't be able to notice this with naked eye.

from libmonome.

simonvanderveldt avatar simonvanderveldt commented on August 22, 2024

@artfwo Thanks for the explanation, sounds like pymonome is plenty fast :)
Unless anything else comes up it seems like it should be fine to drop the Python bindings I guess? Shall I try to create a PR or would you prefer that you do it?

from libmonome.

artfwo avatar artfwo commented on August 22, 2024

@simonvanderveldt please do so if you like, sorry, i have somehow busy week again.

from libmonome.

catfact avatar catfact commented on August 22, 2024

i'm gonna go ahead and nuke the python bindings and monomeserial from this library, which will henceforth be focused on offering a clean C binding to serial devices. (since the other tools handle the other jobs better, and are better maintained.)

from libmonome.

catfact avatar catfact commented on August 22, 2024

on second thought, may as well leave the Cython bindings. it does offer a lightweight means of directly controlling the serial device, handling protocol detection/rotation/etc.

from libmonome.

artfwo avatar artfwo commented on August 22, 2024

@catfact an alternative to Cython bindings is pyserial that provides a more pythonic API and is compatible with standard Python event loops (pyserial-asyncio), but the downside is of course that you have to write a grid protocol layer on top of it.

from libmonome.

shakfu avatar shakfu commented on August 22, 2024

Please don't nuke the python bindings:

  1. It works works perfectly with the latest python (tested on 3.9.9)
  2. The cython code is really minimal (without the header section which doesn't change, it's just 861 words (using wc -w) and 343 lines (using wc -l) which is hardly a maintenance burden.
  3. It's a great place for python-centric people to grok the c-api and experiment with libmonome via python scripting.

from libmonome.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.