Esempio n. 1
0
def display_patch(patch):
    print(patch.to_text())
    print('')
    print(g1on.build_debug_count_header(128))
    print('')
    print(patch.to_scrambled_hex_text())
    print('')
    print(patch.to_hex_text())
    print('')
    print(g1on.build_debug_count_header(21))
    print('')
    for effect in patch.get_scrambled_effects(5):
        print(g1on.to_hex(effect))
    print('')
    for effect in patch.get_effects(5):
        print(effect.to_hex_text())
Esempio n. 2
0
 def to_hex_text(self):
     return _g1on.to_hex(self.effect)
Esempio n. 3
0
# (at your option) any later version.
#
# This project is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU Affero General Public License for more details.

import sys

import g1on

if __name__ == '__main__':
    if len(sys.argv) == 2:
        i = g1on.BI(sys.argv[1])
        while i:
            try:
                i.fill()
                if i.has_non_sysex():
                    nonsysex = i.get_non_sysex()
                    print(g1on.to_hex(nonsysex))
                if i.has_sysex():
                    sysex = i.get_sysex()
                    print(g1on.to_hex(sysex))
            except IOError as e:
                if e.errno != 11:
                    print(e)
                    i.close()
                    i = None
    else:
        print('Usage: %s MIDIDEVICEFILENAME' % (sys.argv[0]))
Esempio n. 4
0
	def to_scrambled_hex_text( self ):
		return _g1on.to_hex( self.patch )
Esempio n. 5
0
	def to_hex_text( self ):
		return _g1on.to_hex( self.data )