General Discussions
send variable via serial

Hi,
I´m trying to send via serial a variable inside CV, also this I´m trying to send the timestamp.
How is the syntax to send the content of the variable via serial?
I tryed these:
1SERIAL("\w[500]\e{#001SCK<?(timestamp)>7A\013\010}\m[001SCK<>16]")
1SERIAL("\w[500]\e{#001SCK<?(500cv)>7A\013\010}\m[
001SCK<>16]")

Best Regards

Neceel

Hi, I&acute;m trying to send via serial a variable inside CV, also this I&acute;m trying to send the timestamp. How is the syntax to send the content of the variable via serial? I tryed these: 1SERIAL(&quot;\\w[500]\\e{#001SCK&lt;?(timestamp)&gt;7A\\013\\010}\\m[*001SCK&lt;&gt;16]&quot;) 1SERIAL(&quot;\\w[500]\\e{#001SCK&lt;?(500cv)&gt;7A\\013\\010}\\m[*001SCK&lt;&gt;16]&quot;) Best Regards Neceel

Hi neceel,

1SERIAL("{ output actions } input actions ", options )

is the generic serial channel structure.

For the 500CV the correct synthax is
%d[500cv] for integer value, f for float etc...details on page 346 of the user manual.

For the time stamp is trickier
I'll copy the date and time values on CV and then send them as for every CV.

Best regards

Giovanni

Hi neceel, 1SERIAL(&quot;{ output actions } input actions &quot;, options ) is the generic serial channel structure. For the 500CV the correct synthax is %d[500cv] for integer value, f for float etc...details on page 346 of the user manual. For the time stamp is trickier I&#039;ll copy the date and time values on CV and then send them as for every CV. Best regards Giovanni

Hi Neceel,

?(timestamp) as replacement strings is only available for unloading the data (as COPYD options). When you want to send the date and time over serial then you have to build the entire strings manually. Unfortunately there is no short cut to pass date+time string.

So if you have set 1CV as hour, 2CV as minute and 3Cv as second, you can use 1SERIAL("{%d[1CV]:%d[2CV]:%d[3CV]}") to pass them as serial string. As you can see the declaration will utilise %d which represent decimal number/ integer (other representation is %f for floating point).

The allocation of CV is enclosed with square brackets [] and you can declare colon (for time separator) as it is (:)

Best regards,
Rudy Gunawan

Hi Neceel, ?(timestamp) as replacement strings is only available for unloading the data (as COPYD options). When you want to send the date and time over serial then you have to build the entire strings manually. Unfortunately there is no short cut to pass date+time string. So if you have set 1CV as hour, 2CV as minute and 3Cv as second, you can use 1SERIAL(&quot;{%d[1CV]:%d[2CV]:%d[3CV]}&quot;) to pass them as serial string. As you can see the declaration will utilise %d which represent decimal number/ integer (other representation is %f for floating point). The allocation of CV is enclosed with square brackets [] and you can declare colon (for time separator) as it is (:) Best regards, Rudy Gunawan
50
2
3
live preview
enter atleast 10 characters
WARNING: You mentioned %MENTIONS%, but they cannot see this message and will not be notified
Saving...
Saved
With selected deselect posts show selected posts
All posts under this topic will be deleted ?
Pending draft ... Click to resume editing
Discard draft