set_prop 24 0
-- Set the self-timer to 10 secondsprops = require("propcase")set_prop(props.SELF_TIMER, 1) -- Value 1 corresponds to a 10-second self-timer
@title Set 10-sec Timerset_prop 219 1
If you get errors on a very simple, valid script, make sure you saving the script file as plain ASCII text, not Unicode, UTF-8, or some not-text format like wordpad
Alright, thanks. Is my script valid though, or did I make a mistake, since I'm pretty sure I saved as a plain text format file.
props = require("propcase")set_prop(props.WB_MODE, 2)
set_capture_mode = 1
set_capture_mode(1)
@params a = value@default a = 0set_video_resolution(a)
The uBASIC Script gave me a uBASIC:6 Parse err...
I'm beginning to doubt if propcases even work.
Even this super simple script just says "STARTED" and then "FINISHED", and once again, nothing changes. Code: [Select]set_capture_mode = 1Is my syntax wrong?
I even asked ChatGPT, and gave it all the documentation, and IT couldn't figure it out either.
EDIT: Somehow I figured something out, by SHEER LUCK! I changed it to Code: [Select]set_capture_mode(1) and it worked!
The thing is, I'm trying to make a script for example, where I can change the resolution number, for example the S3IS has 480p at 30fps, and 320p at 60fps. If let's say 480p 30fps is number 1 in propcase video resolution, then I'd be able to write a simple lua script that would look something like this. Code: [Select]@params a = value@default a = 0set_video_resolution(a)However, I'm not exactly sure how to do this, as I managed to do it with the set_capture_mode(1) script, but I have no idea what the syntax is for any of the other controls.
I just want to inject manual values because if there is a hidden locked off mode, let's say some kind of SCN mode like Foliage but for example let's say there was a SCN preset called Ocean that enhances certain colors and shadows, and it was only on the S1IS, but in the S3IS it still exists in the firmware, but is locked off in code, but if you inject the value, it turns it on.
I have modded many PlayStation2 games, using CheatEngine. I can inject a certain double digit hex value into a certain RAM section, which can make the tires of a car larger than what is possible by default in the game, and it works....
I want to inject a value that isn't documented, and see what happens. Maybe it unlocks some hidden mode, maybe it enters a certain secret servicing menu. Unfortunately, I don't see that happening anytime soon, because I don't even know where to start.Is this even possible, or am I asking for too much?
The number should be the number of the line with the problem.
The syntax is the same standard Lua 5.1 syntax no matter which function you are using. The available functions are mostly listed on https://chdk.fandom.com/wiki/CHDK_Scripting_Cross_Reference_Page and documented to some extent.
Did you discover which address changes the tire size, or are you just changing values that someone else found? What you want to do with CHDK is more like the first option.
You can set propcases, or call eventprocs with call_event_proc or arbitrary functions with call_func_ptr, or change memory directly with poke. Doing anything interesting with any of these generally requires significant understanding of the firmware, usually obtained by reverse engineering.You might occasionally get lucky trying a propcase value based on a hunch, but otherwise you have to do the work.
Is there a chance I can brick my camera by directly writing to the addresses?
Is there actual information for the S3IS addresses for all the things CHDK uses?
it seems you need to know how the firmware itself works before doing anything
Randomly changing memory locations will probably only cause a crash, with or without permanent consequences, who knows.
Yes, in the source code for S3IS, that is its purpose.
I believe all cameras have full frame sensors but they are locked to these unbearably small sizes.
Started by vine General Chat
Started by LjL General Discussion and Assistance
Started by pigeonhill Script Writing
Started by albo General Chat
Started by TimPeTwo DryOS Development