lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Peng Zhicheng <pengzhicheng1986@gmail.com> writes:
>> I am using Lua to develop a mobile appication.
>> Is there any function ( in lua sockets or other) to determine the
>> speed of the device's internet connection?
>>
>> Or should I just download a file and calculate (bytes/time)
>>
>> I need to detect if the device's internet is 2G or not..
>
> I have not used Lua on mobile devices.
> but at at least on Android devices, I know there is APIs to detect the
> connection type.

Such functionality is very device- and OS-specific, so it's pretty
unlikely a generic interface (like sockets) has it...

[If using Android, maybe a Lua binding for the Android interface
(and if a binding doesn't exist, it's probably not hard to make one,
if only a few simple functions are needed).]

-miles

-- 
Cat, n. A soft, indestructible automaton provided by nature to be kicked when
things go wrong in the domestic circle.