{ "info": { "author": "Edouard Theron", "author_email": "edouard@edtheron.me", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Intended Audience :: Developers", "License :: OSI Approved :: GNU General Public License (GPL)", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.3", "Programming Language :: Python :: 3.4", "Programming Language :: Python :: 3.5", "Topic :: Software Development :: Build Tools" ], "description": "py-midi\n=======\n\n**Simply send and receive MIDI messages using Python3.**\n\nThis program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY.\n\n**Warning: To use with Python3 only**. The library doesn't work with Python2.\n\n1. Purpose\n-----------\n\nThis Python3 library has been made in order to communicate easily with any MIDI devices. The only requirement is to have a serial\ninterface on your machine. It's on this interface that you must connect MIDI cables to establish a communication between your\nmachine and the MIDI devices.\n\nThe py-midi library allows users to build and/or read MIDI messages without having to worry on formating them before sending and/or after receiving.\n\nMIDI (Musical Instrument Digital Interface) is a standard used for making easy for instruments, computers and other electronic devices\nto communicate.\n\nThis library is able to deal with any kind of MIDI messages, on any of the 16 possible channels (for channel-type messages) or with any kind of SysEx messages.\n\nFor more details on the MIDI standard, see Wikipedia MIDI page https://en.wikipedia.org/wiki/MIDI\n\n2. Installation\n---------------\nEasily install the package using `pip`::\n\n\t$ pip3 install py-midi\n\nThen you can import the package to your program:\n\n.. code-block:: python\n\n\t>>> import midi\n\n\n3. Getting started\n-------------------\n\nCreates an interface between your program and the serial port of the machine. You instanciate by giving the path to the serial port. Example:\n\n.. code-block:: python\n\n >>> from midi import MidiConnector\n >>> conn = MidiConnector('/dev/serial0') # path to use on RaspberryPi 3\n\nIf you don't want the ``MidiConnector.read()`` method to block forever if it receives nothing, use the keyword argument **timeout** to set up a maximum duration (seconds) of blocking:\n\n.. code-block:: python\n\n >>> conn = MidiConnector('/dev/serial0', timeout=5)\n\nThe ``timeout`` kwarg is only used for reading, not for writing.\n\nTo send a MIDI message, you first need to instantiate a ``MidiMessageType``. There are 8 differents types of MIDI message. Here they are, with there instanciation parameters:\n\n* ``NoteOff(note_number, velocity)``\n* ``NoteOn(note_number, velocity)``\n* ``PolyphonicAftertouch(note_number, pressure)``\n* ``ChannelAftertouch(pressure)``\n* ``ControlChange(control_number, value)``\n* ``ProgramChange(program_number)``\n* ``PitchWheel(lsbyte, msbyte)``\n* ``SysEx(manufacturer_id, data1, data2..., dataN)``\n\n**NOTE**\nAll instanciation parameters must be included within [0, 127] except for ``SysEx`` data (0 to 255) or ``ProgramChange``' number (1 to 128).\n\nExample: create a type ``ControlChange``:\n\n.. code-block:: python\n\n >>> from midi import ControlChange\n >>> cc = ControlChange(100, 127)\n\nNow build the full message, providing a channel:\n\n.. code-block:: python\n\n >>> from midi import Message\n >>> msg = Message(cc, channel=1)\n\nYou can access the attributes of your message directly:\n\n.. code-block:: python\n\n >>> msg.control_number\n 100\n >>> msg.value\n 127\n\nSend the message to MIDI OUT, using the connector:\n\n.. code-block:: python\n\n >>> conn.write(msg) # returns the number of bytes sent\n 3\n\n-------\n\nFor reading messages received via MIDI IN, use the method ``read()`` as follow: (here, we )\n\n.. code-block:: python\n\n >>> msg = conn.read() # read on ANY channel by default\n >>> # Pretend to receive a ProgramChange message, on channel 2\n >>> msg\n Message(ProgramChange(35), 2)\n >>> msg.channel\n 2\n >>> msg.type\n ProgramChange(35)\n >>> msg.program_number\n 35\n\nBy default, the connector's ``read()`` method reads in OMNI mode. To specify a channel, add the channel number as a parameter:\n\n.. code-block:: python\n\n >>> msg = conn.read(8) # read only on channel 8, ignore the rest\n\nAs per the MIDI standard, there are 16 channels you can read from, numbered from 1 to 16.\n\n\n", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/edouardtheron/py-midi", "keywords": "package library midi music digital serial interface", "license": "GNU", "maintainer": "", "maintainer_email": "", "name": "py-midi", "package_url": "https://pypi.org/project/py-midi/", "platform": "", "project_url": "https://pypi.org/project/py-midi/", "project_urls": { "Homepage": "https://github.com/edouardtheron/py-midi" }, "release_url": "https://pypi.org/project/py-midi/2.0.1/", "requires_dist": [ "pyserial" ], "requires_python": "", "summary": "A package for sending and receiving MIDI messages easily.", "version": "2.0.1" }, "last_serial": 5033465, "releases": { "1.1.1": [ { "comment_text": "", "digests": { "md5": "89e2cf9ece93cb3a6ae9d79b8d8b5908", "sha256": "f6ca55150aca2f03362fd3377993ab3b3f183e345678a13c0e8c00aa0ed5df2d" }, "downloads": -1, "filename": "py_midi-1.1.1-py3-none-any.whl", "has_sig": false, "md5_digest": "89e2cf9ece93cb3a6ae9d79b8d8b5908", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 11706, "upload_time": "2017-03-07T20:02:53", "url": "https://files.pythonhosted.org/packages/e5/04/cf233b487df6a3d37a9fcdb72efca15bbe04053ca8fc3cf6df9d9d11b985/py_midi-1.1.1-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "797d9492347f5332ec0974791f570ea0", "sha256": "d1378fb4278ae4dcb9c5a132b7388ce3f3074dc4959af5d00281ce3cf126ecc1" }, "downloads": -1, "filename": "py-midi-1.1.1.tar.gz", "has_sig": false, "md5_digest": "797d9492347f5332ec0974791f570ea0", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7955, "upload_time": "2017-03-07T20:02:55", "url": "https://files.pythonhosted.org/packages/30/d5/cf8e8415b341a84c21e2a3b5cfaa9337acdd0b1a83eab3fbb66f0fd389ea/py-midi-1.1.1.tar.gz" } ], "1.1.2": [ { "comment_text": "", "digests": { "md5": "1aa81f0ae368802ccc2dde7b40dab3fe", "sha256": "737939a9d955aa023141ec18ef09cb01564ef294661dc5687bc72f14b9178a67" }, "downloads": -1, "filename": "py_midi-1.1.2-py2-none-any.whl", "has_sig": false, "md5_digest": "1aa81f0ae368802ccc2dde7b40dab3fe", "packagetype": "bdist_wheel", "python_version": "py2", "requires_python": null, "size": 11288, "upload_time": "2017-03-10T00:01:29", "url": "https://files.pythonhosted.org/packages/73/3d/dba1e6cd91350155fdd694e549d7ed4999ecd246222876295af36cb7235d/py_midi-1.1.2-py2-none-any.whl" }, { "comment_text": "", "digests": { "md5": "bccc587ffcb15c05aee887da3950ded5", "sha256": "3c1ac7472230e406db441da43f11b1181f6ca0dfb37b9fa7ae2b3caddf1523d5" }, "downloads": -1, "filename": "py-midi-1.1.2.tar.gz", "has_sig": false, "md5_digest": "bccc587ffcb15c05aee887da3950ded5", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7890, "upload_time": "2017-03-10T00:01:31", "url": "https://files.pythonhosted.org/packages/78/97/6382f56613c8a6da358d102b5a94dfd154c67a1a8722f67c0f89b109caa0/py-midi-1.1.2.tar.gz" } ], "1.1.3": [ { "comment_text": "", "digests": { "md5": "02f013a4da90daa9e7c1b0c67d7106ba", "sha256": "280444db3de3db9b8b6d0b340ebbd52aa02acdeeb408511234dbf167d5bb361b" }, "downloads": -1, "filename": "py_midi-1.1.3-py3-none-any.whl", "has_sig": false, "md5_digest": "02f013a4da90daa9e7c1b0c67d7106ba", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 12093, "upload_time": "2017-03-10T17:37:06", "url": "https://files.pythonhosted.org/packages/c6/6e/0a0fd91b4d0abddda4da529efd44f927c857fcde2691e252405a4e7a18b5/py_midi-1.1.3-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "093b2cfd7a8339bcd59f6b8790ddea47", "sha256": "01a5f59e99260ada2eac765c148563b3ec18d445bf0522a834ad5ca7f5eb515f" }, "downloads": -1, "filename": "py-midi-1.1.3.tar.gz", "has_sig": false, "md5_digest": "093b2cfd7a8339bcd59f6b8790ddea47", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7885, "upload_time": "2017-03-10T17:47:01", "url": "https://files.pythonhosted.org/packages/4b/cb/2ee0e38a551f0ad2ee98cb3f85a6c0e4c335be1018a7ceaa9388bf1f4a43/py-midi-1.1.3.tar.gz" } ], "1.2.1": [ { "comment_text": "", "digests": { "md5": "03fd6238e2d150db747c04ad186341c8", "sha256": "374171aecc1faf11f576886ab23b8ab752b146cbfe23a610c11e66583e539c55" }, "downloads": -1, "filename": "py_midi-1.2.1-py3-none-any.whl", "has_sig": false, "md5_digest": "03fd6238e2d150db747c04ad186341c8", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 13430, "upload_time": "2017-03-12T01:06:03", "url": "https://files.pythonhosted.org/packages/94/12/bcf887ec8be98b5d5f6f19d5105cebe709db1e60787f466a871bf242d19a/py_midi-1.2.1-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "8f516e0e5400036746ab1cd75e75ae95", "sha256": "a7f1db44d5fc3eda122afb7f8510aea04fea9718050e022a4897d457553dcca8" }, "downloads": -1, "filename": "py-midi-1.2.1.tar.gz", "has_sig": false, "md5_digest": "8f516e0e5400036746ab1cd75e75ae95", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8710, "upload_time": "2017-03-12T01:09:42", "url": "https://files.pythonhosted.org/packages/70/29/3e4361be77c899b0becbd4a953ab36788b1eb7146834475c47f32a1a13bd/py-midi-1.2.1.tar.gz" } ], "1.2.2": [ { "comment_text": "", "digests": { "md5": "5cd99697a694292aee817432cc093ce6", "sha256": "d1f033c21219e66d4758a45215470d10c8d0a0e5e5df10c0ba43a35f36c15998" }, "downloads": -1, "filename": "py_midi-1.2.2-py3-none-any.whl", "has_sig": false, "md5_digest": "5cd99697a694292aee817432cc093ce6", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 13430, "upload_time": "2017-03-12T01:24:03", "url": "https://files.pythonhosted.org/packages/46/13/c03f11dee41285f97097b20234fe40c85afa4cf054db6dde687f4e18cfc0/py_midi-1.2.2-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "75188906752e0c953f422290339e66cf", "sha256": "64b8dd2732b943fbc9062985fb970032eb18c75c85d6382a5a27dc84077de1b3" }, "downloads": -1, "filename": "py-midi-1.2.2.tar.gz", "has_sig": false, "md5_digest": "75188906752e0c953f422290339e66cf", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8710, "upload_time": "2017-03-12T01:24:06", "url": "https://files.pythonhosted.org/packages/a7/71/5d407c63fee38979fced030e76897de8777911ebbd6800d47c54fddc58f4/py-midi-1.2.2.tar.gz" } ], "1.2.3": [ { "comment_text": "", "digests": { "md5": "3da4dd8566720488a63ff0f546669e79", "sha256": "f593ec45636a805bd42721c2668406d283b4d1f12413f19f3e36e7be0387451a" }, "downloads": -1, "filename": "py_midi-1.2.3-py3-none-any.whl", "has_sig": false, "md5_digest": "3da4dd8566720488a63ff0f546669e79", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 13449, "upload_time": "2017-11-16T03:58:05", "url": "https://files.pythonhosted.org/packages/32/fb/72e94cb921db0593e65f359582855886de8e378295a7b4f8cf170caee57a/py_midi-1.2.3-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "017b3bdc352c2a27e133061452695ec8", "sha256": "bd3d6a1fab4e9abd59103c8b1e62379920b9eba99b082187674c036d3324bafe" }, "downloads": -1, "filename": "py-midi-1.2.3.tar.gz", "has_sig": false, "md5_digest": "017b3bdc352c2a27e133061452695ec8", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8736, "upload_time": "2017-11-16T03:58:08", "url": "https://files.pythonhosted.org/packages/a4/9b/9a235e7eb6823114124cb0b3f854cc9a6540d4163ff21e130b3680c84634/py-midi-1.2.3.tar.gz" } ], "1.2.4": [ { "comment_text": "", "digests": { "md5": "f67e331c99b5ae4b97eddbcd58c574bc", "sha256": "34d772d228cd441ce4fc76238813797a2c2f73e53f24d154d283335c153d170d" }, "downloads": -1, "filename": "py_midi-1.2.4-py3-none-any.whl", "has_sig": false, "md5_digest": "f67e331c99b5ae4b97eddbcd58c574bc", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 13448, "upload_time": "2017-11-16T04:03:57", "url": "https://files.pythonhosted.org/packages/bc/ad/b5fea59b97b62fe288f5d8d6c111870ee67c748b5bc65b5edc592fcab65d/py_midi-1.2.4-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "782b59f920b1b5b039384be39e47d679", "sha256": "50e5f5138d005d5f4af226572401529f41b1184b411a5d3c845770792112031c" }, "downloads": -1, "filename": "py-midi-1.2.4.tar.gz", "has_sig": false, "md5_digest": "782b59f920b1b5b039384be39e47d679", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8730, "upload_time": "2017-11-16T04:03:59", "url": "https://files.pythonhosted.org/packages/56/a6/0f65dad54ca08eed303afd13d4bbedb1c6692573a5414b89046883702c9b/py-midi-1.2.4.tar.gz" } ], "1.2.5": [ { "comment_text": "", "digests": { "md5": "e51f3cdeacd588effc54b5bdb4af4e5b", "sha256": "1e6167ca0ae016ea9f3e3fd73bd9b0926278c8cffb17c49b4d62deed81f245c8" }, "downloads": -1, "filename": "py_midi-1.2.5-py3-none-any.whl", "has_sig": false, "md5_digest": "e51f3cdeacd588effc54b5bdb4af4e5b", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 13449, "upload_time": "2017-11-16T15:33:59", "url": "https://files.pythonhosted.org/packages/5e/07/5abfa459f5884a9776ce8e2a3f1eed856818c9771f22c7365b3e7a62fb94/py_midi-1.2.5-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "86377699006a5f2e62cce9b2be2fd93f", "sha256": "931a546ee1fef628a024b32dad1941f6129be26e6b49f840373cbc6c04679da8" }, "downloads": -1, "filename": "py-midi-1.2.5.tar.gz", "has_sig": false, "md5_digest": "86377699006a5f2e62cce9b2be2fd93f", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8735, "upload_time": "2017-11-16T15:34:04", "url": "https://files.pythonhosted.org/packages/c7/c4/4b0db4cb669bbe180f0d22d9000cabbd4f0811d364819a25627c18eaec47/py-midi-1.2.5.tar.gz" } ], "2.0": [ { "comment_text": "", "digests": { "md5": "5e52407fa3612c592f841f1e27dcf9cf", "sha256": "3f2531bd51241ebc7732430a8688568890a36e76e8e074d7185786b55a273408" }, "downloads": -1, "filename": "py_midi-2.0-py3-none-any.whl", "has_sig": false, "md5_digest": "5e52407fa3612c592f841f1e27dcf9cf", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 23839, "upload_time": "2019-04-01T16:29:52", "url": "https://files.pythonhosted.org/packages/4e/ab/b26c05d4c73dad6a395d9e47e6f30074e1bc3cf37460a8f265fb768ff36c/py_midi-2.0-py3-none-any.whl" } ], "2.0.1": [ { "comment_text": "", "digests": { "md5": "8a11dd755c63c9152f99b2962a0ed50f", "sha256": "3bbc896f4bd7ee55e595a2300e173e95522c87964f3acbee705a3d160bfdeac6" }, "downloads": -1, "filename": "py_midi-2.0.1-py3-none-any.whl", "has_sig": false, "md5_digest": "8a11dd755c63c9152f99b2962a0ed50f", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 23871, "upload_time": "2019-04-01T16:41:20", "url": "https://files.pythonhosted.org/packages/72/9b/42dd830c90d4b1d3d0280148516a396f64d1d98b6d80701c5999ce6124b2/py_midi-2.0.1-py3-none-any.whl" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "8a11dd755c63c9152f99b2962a0ed50f", "sha256": "3bbc896f4bd7ee55e595a2300e173e95522c87964f3acbee705a3d160bfdeac6" }, "downloads": -1, "filename": "py_midi-2.0.1-py3-none-any.whl", "has_sig": false, "md5_digest": "8a11dd755c63c9152f99b2962a0ed50f", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 23871, "upload_time": "2019-04-01T16:41:20", "url": "https://files.pythonhosted.org/packages/72/9b/42dd830c90d4b1d3d0280148516a396f64d1d98b6d80701c5999ce6124b2/py_midi-2.0.1-py3-none-any.whl" } ] }