SynthMaker

Code Box - what's not in the manual!

Archive · 2009 7 old posts

From the original SynthMaker forum (2004–2014), with its members’ names and dates.

brokebust ·

Is there a FULL list of code for the code box anywhere? I have seen things on here (the not equal operand, as one example !=, also stuff like OR, XOR etc) which are not mentioned in the manual. I feel like there's a toolbox with all the tools I need and yet I can't see what's in it.

Also, if there are any resources for programming in this language beyond what's on this site I'd love em - there is a sore lack of tutorials 😉

Any help much appreciated, bB 🙂

Below is a list of the expressions in the manual:

sin1(a) cos1(a) tan1(a) log10(a) max(a,b) min(a,b) rndint(a)

* + - /

%

> >= < <=

&

brokebust ·

Also, this link in the manual is broken: http://www.borg.com/~jglatt/tech/midispec.htm

Can anyone provide an alternative? How do you make a MIDI message - what are the definitions of the status values 1-127 etc?

Not having any documentation is really screwing me with this software 🙁

oddson ·

http://home.roadrunner.com/~jgglatt/tech/midispec.htm

This guy has a great reference site but this is the fourth time it's moved in the past four years... I was almost ready to offer to host it myself just so I don't have to keep track of where it is.

As for code - there's not much more to it that what's in the documentation. Hopefully someone with more coding knowldege can add some details.

MichaelBenjamin ·

so theres == and != and i think thats it. some more in asm, squareroot, poor precision (seems to work for most audio) 1/x, sse2 rndint and others.

theun ·

The manual also doesn't mention the " | " , the bitwise OR mask. So it's 3 operands the code component chapter in the manual misses: "==", "!=" and "|". That's all! It would have been nice to have a secret toolbox , though! 😉

Regarding documentation: did you check the S|M WIKI ? There are a few excellent articles on the code component e.g. [old link] and [old link]

Another starting point is this forum here: there are some interesting topics about using code, such as this one: Code tips x a beginner

cheers!

Theun

Shalako ·

This is standard bit operation logic used in C++ and other coding languages,therwise known as Logic Gates also used in electrionic circuts it the basics of digital/binanary system.

A logic gate is a true/false statement in binary otherwise represented by 0 (false) or 1 (true)

example would be: C is true if a and b are equal

a = 10 & b = 5 c = false (signal does not pass through circuit)

a= 10 & b = 10 c = true (siganal does pass through circuit)

'|' binary bitwise inclusive OR as in A or B (one or the other) == Equal to as in A is = to B

(When I say maths I mean addition, subtraction, multipication, division and so on)

sin1(a) maths cos1(a) maths tan1(a) maths log10(a) maths max(a,b) Max of two numbers (which is bigger A or B) min(a,b) Min off two numbers (which is smaller A or B) rndint(a) ??not sure but could be Round a float to an interger

* maths + maths - maths / maths

% remainder

> Greter than >= greater than or equal to (example: >= 5 means all numbers up to 5 and including 5 itself. so 1 to 5 = true and 6+ equals false) < less than <= Less than or equal to

& adress of or and (not sure which in this case I think normal && is And

Now Im not 100% sure that these mean the same thing in SM as they do normally but I'll bet it's pretty close.

Don't ask me how I know this stuff I just do. Helps to have once had a hobby building hardware synths.

Shalako ·

I found a wiki page that might help

http://en.wikipedia.org/wiki/Operators_in_C_and_C%2B%2B

Wrote something here? To have a post removed or your name hidden, write to [email protected].

Before your first post

A few rules keep this a friendly place. You agree to them once.

Shown next to what you post, here and in the app. It doesn’t have to be your real name: 3–24 lower-case letters, digits or _ (capitals become lower case, spaces become _).

    Then your post goes up straight away.

    Delete this reply?

    Open it in SynthMaker?

    It goes on the track you’re editing there, in place of that track’s sound, and into My sounds. Your other tracks stay as they are.

    Want to keep that track’s sound? Start a new song in SynthMaker first (Song › New song), then open this.

    Report this reply?

    Only the developer reads reports. The person isn’t told who reported them.

    What’s wrong with it?

    Block this person?

    You won’t see their posts and replies here any more. They aren’t told, and you can unblock them at any time.

    People you’ve blocked

    Their posts and replies are hidden from you. Unblock someone to see them again.

    The community rules

    A few rules keep this a friendly place. Everyone agrees to them once, before their first post.