[erlang-questions] sleep for a few microsconds

Atul Goyal atulindore2@REDACTED
Thu Nov 16 09:53:27 CET 2017


hi Vance

Thanks but already  tried that :)


On Thu, Nov 16, 2017 at 2:06 PM, Vance Shipley <vances@REDACTED> wrote:

> On Thu, Nov 16, 2017 at 12:57 PM, Atul Goyal <atulindore2@REDACTED>
> wrote:
> > I was wondering if there is a way to sleep for few u'sec in erlang .
>
> Do the opposite?
>
> 1> F = fun(F, T1, T2) when T1 < T2 ->
> 1>           F(F, erlang:system_time(milli_seconds), T2);
> 1>        (_, _, _) ->
> 1>           ok
> 1> end,
> 1> T = erlang:system_time(milli_seconds),
> 1> F(F, T, T + 3).
> ok
>
>
> --
>      -Vance
>



-- 
atul
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20171116/4214b64e/attachment.htm>


More information about the erlang-questions mailing list