Is there any software for the make which offers command line (or other scripting) utility to modify AudioUnit parameters?
The use case is this:
Default (Built-In) input
Attach better Gain Control
AudioUnit (the default OS-X gain
control is inadequate)
Attach L-R balance control (or
"pan")
Pass-through (link) to Default
Output a.k.a. LineIn.app
Script control of AudioUnit 2).
For a 0-100% volume control of the
input audio. In 1/16 increments
(6.5%) just like the main volume in
OS-X.
Script control of AudioUnit 3)
for L-R balance (pan) control.
The problem here for me is at steps 5 and 6.
Steps 1) through to 4) can be adequately achieved graphically in AudioHijackPro. The pass-through, and audio units can be created in there. It also comes with a really good gain control dial / knob. However all those effects are set exclusively through the GUI interface.
Desperately searching for a command-line tool (or "audiounit host") which can set the parameters values and send them to these audio units with the set parameter C api function(s).
Do any existing tools on the Mac offer this kind of functionality?
It sounds like you want Triumph. It can't be controlled from the command line but it is Applescript-able.
Spotify's Pedalbord is a Python library that can apply AU plugins:
https://github.com/spotify/pedalboard
With Fire, it's trivial to turn any Python script into a CLI tool:
https://github.com/google/python-fire
Related
I am a trying to print Shipping labels from a website to my TSC DA310 thermal printer. I have installed QZ tray locally, but my printer is printer Raw commands instead of the shipping label along with the barcode etc. Anyone else faced a similar issue?
Quoting the DA310 user's manual, this printer has a special "TSPL-EZD" firmware which emulates
"out of the box" the following label formats:
Eltron® EPL command emulation
Zebra® ZPL command emulation
Datamax® DPL command emulation
To quote the original symptom:
my printer is printer Raw commands instead of the shipping label along with the barcode etc.
Since all shipping providers provide commands in one of the above formats, this suggests that the vendor-provided driver may be interfering with the printing.
One way to bypass the driver is to change it from TSC DA310 to Generic / Text Only using Printer Properties, Advanced, New Driver.
Since this printer driver is provided by a 3rd party (at time of writing, a company called "Seagull Scientific") you may consider reaching out to Seagull Scientific with this particular problem. At time of writing this, te default driver does not seem to offer any configurable options regarding specifically to language emulation.
If all else fails, reach out to TSC technical support to see how to send raw label commands to their hardware.
TSC technical support will want to know which label format you are sending. To find out, see the following reference:
ZPL usually looks like this: ^XA ^FO ...
EPL usually looks like this: N q812 Q1218 B5 ... A310 ..
DPL usually looks like this: <STX>L D11
Lastly, for help using the TSC-series printers with QZ Tray (per qz-tray tag), you may reach out directly to support or ask a new question and link it here in the comments.
I am writing a small shell in Rust on Linux as an exercise and I wanted to implement command history as well as cursor moving (i.e. moving back the cursor to edit a typo in the command).
I did not find a way in the Rust standard library to handle arrow key events, but I found the Termion crate which handles key events.
However, handling key events with Termion means entering "raw mode" for stdout, which overrides "legacy" functionalities, as described in this article about the crate:
Without raw mode, you cannot write a proper interactive TTY application. Raw mode gives you complete control over the TTY:
It disables the line buffering: As you might notice, your command-line application tends to behave like the command-line. The programs will first get the input when the user types \n. Raw mode makes the program get the input after every key stroke.
It disables displaying the input: Without raw mode, the things you type appear on the screen, making it insufficient for most interactive TTY applications, where keys can represent controls and not textual input.
It disables canonicalization of the output: For example, \n represents “go one cell down” not “break the line”, for line breaks \n\r is needed.
It disables scrolling.
I find this solution a bit overkill, as I want to retain most of the "legacy" I/O functionalities. Is there another way to handle arrow key input, or will I need to use the raw mode?
There are several crates that provide line editing features for interactive programs. Here are a few that I found by searching crates.io for "readline" (the name of a C library):
rustyline seems to be the most popular on crates.io.
liner
linefeed
linenoise-rust is a set of Rust bindings to the linenoise library written in C.
I haven't used any of them, so this list is not a recommendation. Take a look at a few of them and choose one that suits your needs.
I use a bash script to auto-generate a pdf calendar each month.I use the wonderful remind program as the basis for this routine. Great as are the calendars I get using that program, I need a more detailed header for the calendar (than just the name of the month and the year). I couldn't puzzle out a way to get the remind program to enhance the header, but I was able to get the enhanced results I wanted by creating a second pdf containing the header enhancements I need, then overlaying that pdf onto the calendar I produce with remind, via the pdftk utility (pdftk calendar.pdf stamp calendar_overlay.pdf output MONTH-YEAR-cal.pdf). Unfortunately, I recently lost the ability to use pdftk since keeping it on my system would necessitate me ceasing to do other system updates. In short, I had to remove it in order to continue updating my system.
So now I'm looking for some alternative that I can incorporate into my bash script. I am not finding any utility that will allow me to overlay one pdf with another, like pdftk allows. It seems I may be able to do something like what I'm after using imagemagick (-convert), though I would likely need to overlay the pdf with an image file like a .jpg rather than with a pdf. Another possible solution may be to use TeX/LaTeX to insert text into the pdf as described at https://rsmith.home.xs4all.nl/howto/adding-text-or-graphics-to-a-pdf-file.html.
I wanted to ask here, before investing a lot of time and effort into pursuing one or other of the two potential options I've identified, whether there is some other way, using command line options that can be incorporated into a bash script, of overlaying one pdf with another in the manner described? Input will be appreciated.
LATER EDIT: another link with indications how to do such things using LaTeX https://askubuntu.com/questions/712691/batch-add-header-footer-to-pdf-files
Assuming for simplicity that both of your files are of size 500pt x 200pt,
you can use pdfjam with nup and delta options to trick it into overlaying your source pdf files.
pdfjam bottom.pdf top.pdf --outfile merged.pdf \
--nup "1x2" \
--noautoscale true \
--delta "0 -200pt" \
--papersize "{500pt, 200pt}"
Unfortunately, I've found in my tests that I needed to increase the y delta by one point to get perfect alignment.
pdftk-java is a Java-based port of pdftk which looks to be actively in development. Given that its only real requirement appears to be Java 7+, it should work even in environments such as your own that no longer support the requirements of pdftk, so long as they have a Java runtime installed.
I am trying to configure a Mac OS X print queue so that a script can do some processing on each file printed before forwarding it on to another CUPS printer (on the same host).
I have been reading up on CUPS and have found an article describing how to use lpadmin to configure a queue with a "System V style interface script", but the caveat is that such a queue is seen as a "Generic Printer". I presume that means the user looses all ability to choose paper trays, etc. when submitting a job from the Print dialog. Is that correct?
[That makes this approach undesirable for my purposes, because the final destination is a POS receipt printer with non-standard paper sizes and print job options for cutting the paper roll, opening the cash drawer, etc.]
Is there a better way to accomplish my goal, which is simply to run a script on each receipt printed through a particular CUPS print queue?
I believe you need to configure a cups filter, which I believe can be created for just about any printer. It basically works as an input/output filter - where you modify the job in flight.
anyway, here is a link I found that explains an approach to do so (although it is for a slightly different use case). hope it helps.
Programming a Filter/Backend to 'Print to PDF' with CUPS from any Mac OS X application
be well.
I'm trying to have some fun with fluxus, but its manual and online docs all seem to assume that the reader is already an expert network programmer who's never heard of Scheme before. Consequently, you get passages that try to explain the very basics of prefix notation, but assume that you know how to pipe sound-card data into the program, or setup and connect to an OSC process.
Is there any tutorial out there that goes the opposite way? IE, assumes that you already have a handle on the Lisp/Scheme thing, but need some pointers before you can properly set up sound sources or an OSC server?
Barring that, does anyone know how to get (for example) the system microphone to connect to (fluxus), or how to get it to play a sound file from disk?
To get the system microphone to connect to fluxus you need a software to comunicate and take the data in your audio card, like jackpilot http://www.jackosx.com/about.html
Once you have installed in your computer (mac in this case):
go to system preferencies/audio... in audio IN, you need to select your microphone
strart jackpilot
in jackpilot preferences configure audio IN to microphone too
put in buffer size 1024, and sample rate 44100
save (jackpilot) and click run
open fluxus
try this little code
(clear)
(start-audio "" 1024 44100)
(define (something)
(rotate (vector (gh 0) (gh 5) (gh 15)))
(draw-cube)
)
(every-frame (something))
If you need the same info in linux, tell me.
If you need to do the same on windows... windows do not have audio support.
I hope this info works for you.