Berry FFI questions #469
|
Hi! And thanks for this awesome project! I am considering to use Berry for a low-tech project with a very limited memory (64Ko of RAM and 2M of flash), but good computation resources. The documentation is really helpful, however there is some gray area.
Thanks! |
Replies: 2 comments 2 replies
The second argument in Example, let's say the function takes 2 arguments:
I'm not sure to understand. Just consider what I posted above, it should make it clearer about what you can and can't do
I have never done it. You have some examples in
I don't quite remember the details. |
Thanks! This is more clear now. However, I still don't know how to call a function defined in a berry script. |
There is no direct way. You need to find and push the berry function on top of the stack.
One way would be to use
be_getglobal(vm, "func_name");if the name is global.