Magic Lantern Forum

Developing Magic Lantern => Scripting Corner => Archived scripts => Topic started by: gerk.raisen on May 27, 2013, 02:23:08 PM

Title: Convert PicoC script to run on TCC?
Post by: gerk.raisen on May 27, 2013, 02:23:08 PM
Now that many people (me too) are trying raw_rec module (so with PicoC disabled and TCC enabled),
I was figuring out how to convert simple scripts from PicoC to TCC.

I read that with TCC scripting is a little more complicated.

For example (taken from brack.c)
What i need to run to make it work?



// Custom bracket sequence
// ISO 3200 1/10 f1.8
// ISO 100 1/10 f8
// ISO 100 1" f8
// ISO 100 10" f8

console_hide();

set_aperture(1.8);
set_iso(3200);
set_shutter(1./10);
takepic();

set_aperture(8);
set_iso(100);
takepic();

set_shutter(1);
takepic();

set_shutter(10);
takepic();
Title: Re: Convert PicoC script to run on TCC?
Post by: g3gg0 on May 27, 2013, 02:24:31 PM
wrap it with

int main()
{
...
}

thats the most important stuff.
then we will see which functions are missing.
Title: Re: Convert PicoC script to run on TCC?
Post by: federico.albertini on November 01, 2013, 06:53:06 PM
From where do you run a script, within ML?

cheers, F.