doc:lua_make-your-own-scripts
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
doc:lua_make-your-own-scripts [2015/11/15 13:31] – [Miscellaneous Commands] admin | doc:lua_make-your-own-scripts [2015/12/06 11:23] – admin | ||
---|---|---|---|
Line 136: | Line 136: | ||
- | ==== The Communication | + | ==== The Communication Commands ==== |
Line 192: | Line 192: | ||
- | ^ filename | + | ^ filename |
- | |/ | + | |/ |
- | |/ | + | |/ |
- | |URL like '' | + | |URL like '' |
- | |URL like '' | + | |URL like '' |
- | === ioRead(" | + | === ioRead(" |
- | Read one line of the input file ending with either %%\%%r%%\%%n or %%\%%n as string without the EOL. In case of input EOF or read errors the function returns nil | + | Read one line of the input file ending with either %%\%%r%%\%%n or %%\%%n as string without the EOL. In case of input EOF or read errors the function returns nil. By this the whole file can be read line per line |
- | === ioRead ("%%*%%all") === | + | === ioRead (" |
Read the whole file as string | Read the whole file as string | ||
+ | === ioRead (" | ||
- | === ioRead (count) === | ||
+ | Here it's assumed that the input file consists of a JSON string containing data. This string is translated into a lua table structure and returned | ||
- | Read count number of bytes as string | ||
+ | === ioRead (" | ||
- | === ioOutput(URL[, | ||
+ | This mainly for testing purposes. It returns the sha256 checksum of that file | ||
- | Try to opens '' | ||
- | === ioWrite (String) === | ||
- | Attaches the string content to the output file | + | ==== The Buffer Commands ==== |
+ | |||
+ | FIXME this whole Buffer section is not implemented and actual just here as a reference for discussion | ||
Line 302: | Line 303: | ||
- | ==== Miscellaneous | + | ==== WriteString Command Syntax |
+ | As default the command | ||
- | === serDisplayWrite(String) === | + | |
+ | |||
+ | |||
+ | writes //String// to the build in output console. But with an optional secound parameter as command this behavior can be changed: | ||
+ | |||
+ | serDisplayWrite(parameter, | ||
+ | |||
+ | The different commands have the following effects: | ||
+ | |||
+ | ^ parameter | ||
+ | | buffername | ||
+ | | - | clear | clears actual buffer content | | ||
+ | | - | clearall | ||
+ | | filename | ||
+ | | filename | ||
+ | | filename | ||
+ | | filename | ||
+ | |||
+ | |||
+ | |||
+ | |||
+ | ==== Miscellaneous | ||
- | Writes //String// to the build in output console. | ||
=== dbLookup(db-File , searchstring) === | === dbLookup(db-File , searchstring) === | ||
doc/lua_make-your-own-scripts.txt · Last modified: 2019/04/08 18:43 by admin