serial speed

Mark Waddingham mark at
Fri May 3 11:36:17 EDT 2019

On 2019-05-03 17:01, runrevlist--- via use-livecode wrote:
> LC is ver well suited for all kinds of programs communicating with
> robots, 3D printers, milling machines etc. if only we could have a
> decent speed. I am not even asking for the preferred speed of 22…..
> The arduino IDE can easily communicate at that speed, why not LC?

Which platform are you using?

On Windows, any limit in baudrate is determined by Win32: the 
property is passed to the 'BuildCommDCBW' Win32 API function to parse 
(which doesn't
explicitly mention a baudrate limit).

On Mac/Linux, however, there is an 'artificial' limit - the engine 
parses the control
string itself in those cases and maps the integer baudrate value to a 
system constant...

So the reason it is limited to 57600 baud will be because when that code 
was written, the only constants which were defined by the system were 
those up to 57600 baud (it would appear at least.

This would need a (simple) engine patch to enable speeds up to the ones 
which are defined (on macOS there are constants up to 230400, Linux has 
a few higher ones defined too) when using 'the serialControlString' 

> Does any one have a solution or idea how to increase this silly speed
> limit of LC?

Alternatively, you might be able to open the serial device from LC as 
you do now and then use the 'stty' shell command to tweak the settings:

    stty -F /dev/tty... <baudrate>

Here <baudrate> is one which is known by the system. For Linux this 
appears to be a reasonably normative list 
(although a baudrate being there doesn't mean the device supports it).

Warmest Regards,


Mark Waddingham ~ mark at ~
LiveCode: Everyone can create apps

More information about the Use-livecode mailing list