Home > HMS NETWORKS > HMS NETWORKS CANbridge NT Lua ADK Bridge Router User Guide

HMS NETWORKS CANbridge NT Lua ADK Bridge Router User Guide

CAN@net NT/CANbridge NT Lua ADK  
C Funcons Called from Lua  
Funcon 'on_action'  
on_action(param1, param2, param3)  
The "CAN-Gateway Conguraor" allows the denion of acon rules with the acon " Call Lua uncon  
'on_acon'". If this acon is triggered, the uncon on_actionis called.  
param1, param2and param3are strings or numeric values, depending on the denion in the acon rule.  
5.2. C Funcons Called from Lua  
5.2.1. Module misc  
Funcons from the module miscare loaded by default and are directly available.  
Funcon 'hex'  
hex(val)  
Converts the parameter valinto a hexadecimal represenaon.  
Funcon 'dump'  
dump(o, indent, nested, level)  
Dumps values in a one-statement format.  
For example, {test = {"Tesng..."}} becomes:  
{
test = {  
"Testing..."  
}
}
The uncon also supports tables as keys, but not circular references.  
indent: species an indenaon string, it defaults to a tab. Use the empty string to disable indenaon.  
nested: internal only. Do not provide any value.  
level: internal only. Do not provide any value.  
Funcon 'string.split'  
string.split(str, delim, include_empty, max_splits, sep_is_pattern)  
Splits the string strinto a list of substrings, breaking the original string on occurrences of the given separator  
delim(character, character set, or paern).  
include_empty: boolean, default: false, e.g. "a,,,b":split(",")returns {"a","","",b"}  
max_splits: number, if negave, splits are not limited, default: -1  
sep_is_pattern: boolean, species whether the separator is a plain string or a paern (regex), default:  
false, e.g. "a,b":split(",")returns {"a","b"}  
Page 10 of 20  
4.02.0332.20002 Version 1.5  
GeneralDetails
NameHMS NETWORKS CANbridge NT Lua ADK Bridge Router User Guide
MakeHMS NETWORKS
LanguageEnglish
FiletypePDF (Download)
File size MB
Download PDF
1 Star2 Stars3 Stars4 Stars5 Stars (1 votes, average: 5.00 out of 5)
Loading...

If you have any questions regarding HMS NETWORKS CANbridge NT Lua ADK Bridge Router User Guide, please ask here and describe the problem in detail.

Leave a Reply

Your email address will not be published. Required fields are marked *

six + seventeen =

HMS NETWORKS CANbridge NT Lua ADK Bridge Router User Guide