HELP! programming objects (without knowing how to program)


#1

Hi there!I I am a newbie trying to finish my first patch (a 4track sampler with effects and assignable lfo´s and envelopes all of it controlled with twister midi fighter). I still have plenty CPU BUT Im struggling with SRAM at the moment. I read about saving SRAM and after attending to remake the whole patch without subpatches and after realize I need even more SRAM I decided to start changing OBJECT´s program. I never program before but I copy/paste or delete what I think I need to do to change the object the way I want.. I succeeded in a few easy ones ( like deleting parameters or adding inputs) but im having problems with the tiar/gain/vca3 im trying to make a "tear/gain/vca4" (add 1 more input) but I have this error message every time

Generate code complete
Creating directory on sdcard : /sampler live efectos REMAKE 12
Done creating directory
Changing working directory on sdcard : /sampler live efectos REMAKE 12
Done changing working directory
Start compiling patch
Compiling patch... with /Applications/Axoloti.app/Contents/Java/firmware
BDIR = /Users/steve/Documents/axoloti/build
FIRMWARE = .
RM
APP
! /Users/steve/Documents/axoloti/build/xpatch.h.gch
/Users/steve/Documents/axoloti/build/xpatch.cpp: In member function 'void rootc::instancevca3__1::dsp(const int32_t*, int32_t, const int32_t*, int32_t, const int32_t*, int32_t, const int32_t*, int32_t, int32_t (&)[16])':
/Users/steve/Documents/axoloti/build/xpatch.cpp:9728:45: error: expected ')' before ';' token
__SMMUL(inletin1[i], g1 += dg1))) << 5;
^
make: *** [/Users/steve/Documents/axoloti/build/xpatch.bin] Error 1
shell task failed, exit value: 2
Compiling patch failed ( /Users/steve/axoloti patches DrGwon/sampler live efectos REMAKE 12.axp )

Im doble checking everything on the code but I really don't know what im doing :upside_down_face:
Anyone knows what can I do to make it right?(seem like a easy thing but the knowledge needed its way over my head)... any help will be very appreciated at this point!


#2

Add a ' ) ' before the << 5 in the last line of the k code. ( I assume that you have somehow generalized the tiar object)


#3

a good way to troubeshoot an object is to temporarily remove a part of the code and see it the object works. If so, then you know the mistake is in the part of the code that you deleted, if not, place it back and remove another part.
Just make sure not to remove parts where you initiate something like "int32_t bladibla" as these could be used in another part of the code, giving another new error when you remove those.

anyways, in this error it states " expected ')' before ';' token ", so like patatos states, you are missing one ')'. Make sure you put it at the right place for the formula to work correct.


#4

Thanks guys! As I said before this is way over my knowledge. I just delete or copy/paste outlets or parameters Im not going to use so I save SRAM ... Sometimes works but sometimes I delete something and I don't know what it is. Maybe im having more question about programming soon. If it's not a problem I will post it in this treat so I don't have to start a new one every time i need a programmer super hero to come and rescue me.


#5

don't worry, I started out the same way a couple of years ago. When you get the hang of it, you just shake them out of your sleeves one after the other.


#6

I had no idea about code before axoloti, after a year with it fiddling with existing objects like you are I'm now coding my own objects!


#7

Hi guys! I still reprogramming object as a practical way to save SRam. Very very slowly I'm starting to understand a few things when rewriting (copy/paste) object code. Right now I'm trying to make "filter/multimode svf m" object to get cutoff lower.
I want it to totally close.
Is there something in the code that I can change to make it possible?
Thanks!