lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


If you haven't already, you should try to take lua out of the equation and make
sure the code responds as expected.  Is your application the master or the
slave?  If you are the master, are you sure you are continuing to clock bits out?

Since you are already doing stuff in C, I would avoid using a lua function like
write_format.  C would be able to do this much more quickly without all the
temporary string overhead, math lib function calls and divide/mod.

I would create a lua_CFunction that takes whatever addressing you need, plus a
lua string and optional position args (same as string.sub).