Livejournal
Log in
Post
Friends
My journal
pyhedgehog
Модуль dbms_output для cx_Oracle
Feb 27, 2012 18:46
Написал тут простенький модуль для использования вместе с cx_Oracle для получения вывода через модуль dbms_output.
(
Пример
)
oracle
,
python
Leave a comment
Comments 3
(The comment has been removed)
pyhedgehog
March 19 2012, 18:08:26 UTC
Сейчас посмотрю. Извини, но только сейчас заметил комментарий...
Reply
pyhedgehog
March 21 2012, 11:03:37 UTC
#!/usr/bin/env python
import time
import win32com.client.gencache
#dll = "C:\\Program Files\\Jazz-Soft\\Jazz-Plugin\\JazzControl.dll"
jazz_plugin = win32com.client.gencache.EnsureModule('{B08A99FE-0E66-467A-83D8-1E9F23EBC6C7}',0,1,0)
jazz = jazz_plugin.JazzCtrl()
assert jazz
print "Jazz-Plugin ver.", jazz.version;
devlist = jazz.MidiOutList()
if not devlist:
print "No MIDI Out devices found!"
for dev in devlist:
print "Testing", dev,
if jazz.MidiOutOpen(dev) != dev:
print "- cannot open!"
else:
time.sleep(1)
jazz.MidiOut(0x90,0x3c,0x7f)
jazz.MidiOut(0x90,0x40,0x7f)
jazz.MidiOut(0x90,0x43,0x7f)
time.sleep(2)
jazz.MidiOut(0x80,0x3c,0)
jazz.MidiOut(0x80,0x40,0)
jazz.MidiOut(0x80,0x43,0)
print "- done!"
Reply
(The comment has been removed)
Thread 5
Leave a comment
Up
Comments 3
(The comment has been removed)
Reply
#!/usr/bin/env python
import time
import win32com.client.gencache
#dll = "C:\\Program Files\\Jazz-Soft\\Jazz-Plugin\\JazzControl.dll"
jazz_plugin = win32com.client.gencache.EnsureModule('{B08A99FE-0E66-467A-83D8-1E9F23EBC6C7}',0,1,0)
jazz = jazz_plugin.JazzCtrl()
assert jazz
print "Jazz-Plugin ver.", jazz.version;
devlist = jazz.MidiOutList()
if not devlist:
print "No MIDI Out devices found!"
for dev in devlist:
print "Testing", dev,
if jazz.MidiOutOpen(dev) != dev:
print "- cannot open!"
else:
time.sleep(1)
jazz.MidiOut(0x90,0x3c,0x7f)
jazz.MidiOut(0x90,0x40,0x7f)
jazz.MidiOut(0x90,0x43,0x7f)
time.sleep(2)
jazz.MidiOut(0x80,0x3c,0)
jazz.MidiOut(0x80,0x40,0)
jazz.MidiOut(0x80,0x43,0)
print "- done!"
Reply
(The comment has been removed)
Leave a comment