Extension of systemVersion

Something you want to see in a LiveCode product? Want a new forum set up for a specific topic? Talk about it here.

Moderators: Klaus, FourthWorld, heatherlaine, robinmiller, kevinmiller

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 3828
Joined: Fri Feb 19, 2010 10:17 am
Location: Bulgaria

Extension of systemVersion

Post by richmond62 » Sat Aug 31, 2019 10:00 am

Code: Select all

on mouseUp
       put the system version
end mouseUp
Will tell you which Operating system you are using.

What systemVersion will NOT tell you is if:

1. Your system is a 32 or 64 bit system.

2. Whether you are running a PPC, an INTEL or an ARM processor.

https://www.macrumors.com/2019/02/21/ap ... hips-2020/
Last edited by richmond62 on Sat Aug 31, 2019 10:07 am, edited 1 time in total.

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 3828
Joined: Fri Feb 19, 2010 10:17 am
Location: Bulgaria

Re: Extension of systemVersion

Post by richmond62 » Sat Aug 31, 2019 10:03 am

I am not quite sure how platform differs
from systemVersion.

But platform supplies nothing further of an use.

bogs
Posts: 4001
Joined: Sat Feb 25, 2017 10:45 pm

Re: Extension of systemVersion

Post by bogs » Sat Aug 31, 2019 1:17 pm

Funny you should mention this, I recently was trying to figure out how you would get this same information, and failed miserably in how to find it short of dropping to the CLI :roll:

If anyone knows, I too would appreciate the info!
I am not quite sure how platform differs
from systemVersion.
"Platform" simply returns which operating environment being run, "systemVersion" returns the version as well. While knowing you are on "OSX" might be handy, it would certainly be nicer to know if it is 10.6, 10.7, or 10.8 in some cases.
Image

SparkOut
Posts: 2031
Joined: Sun Sep 23, 2007 4:58 pm

Re: Extension of systemVersion

Post by SparkOut » Sat Aug 31, 2019 2:26 pm

I expect this severely depends on the computer environment in question, and probably depends a lot on what is in the path, but there are some global variables that might work.

On my Dell laptop running Windows 10, I can obtain info from the following globals:
$NUMBER_OF_PROCESSORS (returns 12)
$PROCESSOR_ARCHITECTURE (returns AMD64)
$PROCESSOR_IDENTIFIER (returns Intel64 Family 6 Model 158 Stepping 10, GenuineIntel)
$PROCESSOR_LEVEL (returns 6)
$PROCESSOR_REVISION (returns 930a)

$OS rather uselessly returns "Windows_NT"

I have no idea what you might get on Linux or Mac or mobile.

There is also a global:
msg which returns the last contents of the message box

bogs
Posts: 4001
Joined: Sat Feb 25, 2017 10:45 pm

Re: Extension of systemVersion

Post by bogs » Sat Aug 31, 2019 3:30 pm

Works on Windows, returns nothing on 'nix :(

Funny there is nothing about it in the dictionary, far as I can find.
Image

FourthWorld
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7041
Joined: Sat Apr 08, 2006 7:05 am
Location: Los Angeles
Contact:

Re: Extension of systemVersion

Post by FourthWorld » Sat Aug 31, 2019 4:13 pm

To learn about the processor, see the processor function.
Richard Gaskin
Community volunteer LiveCode Community Liaison

LiveCode development, training, and consulting services: Fourth World Systems: http://FourthWorld.com
LiveCode User Group on Facebook : http://FaceBook.com/groups/LiveCodeUsers/

bogs
Posts: 4001
Joined: Sat Feb 25, 2017 10:45 pm

Re: Extension of systemVersion

Post by bogs » Sat Aug 31, 2019 4:23 pm

I had actually found that, but it doesn't give very much information.
Summary:
Returns a string describing the system's CPU chip.

Examples:
the processor
if the processor is "ARM" then ...

Use the processor function to determine which microprocessor the device has.
Value:
The processor function returns one of the following strings:

* Motorola PowerPC - Mac OS system with a PowerPC processor.
* Motorola MC68000 - Mac OS system with a 68000-family chip (older Macs).
* unknown - Unix systems.
* x86 - Windows systems and Mac OS X systems with an Intel processor.
* i386 - iOS Simulator.
* ARM - iOS and Android Devices and the Android simulator.
Even where you were just looking for the processor type, $PROCESSOR_ARCHITECTURE (returns AMD64 on Windows) is more enlightening than (x86), if you see what I mean.

Mainly what I was looking for (can't speak for Richmond) was what SparkOut listed, and actually a lot more. Being able to find the complete system specs easily (as far as at least the OS understands them) would be a nice addition. I'm thinking about the amount of ram, processor details, possibly even MB specs and controllers available.
Image

SparkOut
Posts: 2031
Joined: Sun Sep 23, 2007 4:58 pm

Re: Extension of systemVersion

Post by SparkOut » Sat Aug 31, 2019 4:29 pm

Try looking in the Script Editor, on the Variables tab at the bottom pane. Tick the boxes that say Show Globals and Show Environment vars. See what is listed specific to your environment. I have a feeling that a lot will depend on what has been put in the Path for the target machine so you will probably not get a greatly reliable consistency.

bogs
Posts: 4001
Joined: Sat Feb 25, 2017 10:45 pm

Re: Extension of systemVersion

Post by bogs » Sat Aug 31, 2019 4:56 pm

Yup, checked those long ago. Guess 'nix users are out of luck heh. Oh well, not like the CLI is alien to me or something, after all, and I know how to pull the procs enough to determine what I'm looking for.
Image

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 5155
Joined: Sat Apr 08, 2006 8:31 pm
Location: Minneapolis MN
Contact:

Re: Extension of systemVersion

Post by jacque » Sat Aug 31, 2019 5:24 pm

richmond62 wrote:
Sat Aug 31, 2019 10:03 am
I am not quite sure how platform differs
from systemVersion.

But platform supplies nothing further of an use.
The systemVersion returns the numerical version of the OS. The platform returns the type of OS (android, windows, etc.) The machine returns the manufacturer's name for the hardware. The environment returns the the general environment (mobile, standalone, etc.)

It's all listed in the dictionary.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

FourthWorld
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7041
Joined: Sat Apr 08, 2006 7:05 am
Location: Los Angeles
Contact:

Re: Extension of systemVersion

Post by FourthWorld » Sat Aug 31, 2019 6:38 pm

The original request was for:
1. Your system is a 32 or 64 bit system.
The processor will tell you that. If you're able to turn up a case where it reports that incorrectly please submit a bug report.
2. Whether you are running a PPC, an INTEL or an ARM processor.
A little trickier in general, but not so tricky from inside LC given LC's deployment options:
PPC is no longer supported, so any additions to the language will not report that.
The processor should tell you whether running Intel or ARM, but that's not relevant for any platform but Android, where the bytecode nature of APKs usually makes that irrelevant.

What is the problem you're looking to solve?
Richard Gaskin
Community volunteer LiveCode Community Liaison

LiveCode development, training, and consulting services: Fourth World Systems: http://FourthWorld.com
LiveCode User Group on Facebook : http://FaceBook.com/groups/LiveCodeUsers/

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 3828
Joined: Fri Feb 19, 2010 10:17 am
Location: Bulgaria

Re: Extension of systemVersion

Post by richmond62 » Sat Aug 31, 2019 6:57 pm

What is the problem you're looking to solve?
My "problem", if it is a problem at all, is that in a perfect world (?) one should
be able to deploy LiveCode apps on all sorts of operating systems and all sorts
of processors; while at the moment one is able to deploy them on a subset of
those available.

That, Ding an sich, is not a problem . . especially as earlier versions of LiveCode/RunRev
and Metacard ARE available for those systems (such as UNIX and IRIS) which LiveCode saw
fit to abandon (a backward step, possibly), but as LiveCode is NOT, despite its claims,
completely cross-platform compatible, it can be useful for a standalone to work out
what tpe of OS on what type of processor it is running, so that scripts can come into
play that tweak a standalone for specific features that are NOT cross-platform
to come into play.

Which is a fairly long, and fairly pompous, way of stating what should be screamingly
obvious to anyone except those people who enjoy squashing my requests as a way of
sidestepping responsibility.

FourthWorld
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7041
Joined: Sat Apr 08, 2006 7:05 am
Location: Los Angeles
Contact:

Re: Extension of systemVersion

Post by FourthWorld » Sat Aug 31, 2019 8:08 pm

I'm still not understanding what specific programming task you're unable to complete with the existing functions.

Maybe I just need a bike ride. I'll go get one and see I can figure out what's needed when I get back.
Richard Gaskin
Community volunteer LiveCode Community Liaison

LiveCode development, training, and consulting services: Fourth World Systems: http://FourthWorld.com
LiveCode User Group on Facebook : http://FaceBook.com/groups/LiveCodeUsers/

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 5155
Joined: Sat Apr 08, 2006 8:31 pm
Location: Minneapolis MN
Contact:

Re: Extension of systemVersion

Post by jacque » Sat Aug 31, 2019 8:26 pm

Which is a fairly long, and fairly pompous, way of stating what should be screamingly
obvious to anyone except those people who enjoy squashing my requests as a way of
sidestepping responsibility.
I thought we did answer...
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

bogs
Posts: 4001
Joined: Sat Feb 25, 2017 10:45 pm

Re: Extension of systemVersion

Post by bogs » Sat Aug 31, 2019 10:07 pm

I'd like to say I appreciate everyone's answers, but, there are some things wrong in eden :D
FourthWorld wrote:
Sat Aug 31, 2019 6:38 pm
The original request was for:
1. Your system is a 32 or 64 bit system.
The processor will tell you that. If you're able to turn up a case where it reports that incorrectly please submit a bug report.
This is actually not the case, 'the processor' (and 'the machine') echo merely what the installed OS is, really, not what the processor is. For instance, this is on a 3 core 64 bit AMD processor, with 32 bit Linux Mint 19 installed -
machineStats.png
System stats...
The 'system version' (or systemVersion, either way) is actually complete, it returns the OS and the version number.
The 'platform' merely tells you the OS.
the systemversion - Linux 4.4.0-159-generic
the platform - Linux
The 'environment' is of course as stated, but inconsequential in this discussion (which I think is focusing on system information, but could be wrong).
Image

Post Reply

Return to “Feature Requests”