473,382 Members | 1,380 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,382 software developers and data experts.

what are REGS,SREGS ?

hello,
I want to know for what purpose union REGS and struct SREGS are
used in windows programming? also how following code an determine that
running OS is windows?
in_regs.x.ax = 0x160A;
int86x(0x2F, &in_regs, &out_regs, &seg_regs);
if (out_regs.x.ax == 0)
Running_WIN=TRUE;
provided here
union REGS in_regs, out_regs;
struct SREGS seg_regs;

Nov 15 '05 #1
5 8149
ra*******@gmail.com wrote:
hello,
I want to know for what purpose union REGS and struct SREGS are
used in windows programming? also how following code an determine that
running OS is windows?

<snip>

Off-topic. Take it to comp.os.ms-windows.programmer, please.

S.
Nov 15 '05 #2
ra*******@gmail.com wrote in news:1128534736.435075.269810
@g49g2000cwa.googlegroups.com:
hello,
I want to know for what purpose union REGS and struct SREGS are
used in windows programming?
Hmmm ... Wrong group. Try comp.os.ms-windows.programmer.*
also how following code an determine that
running OS is windows?
in_regs.x.ax = 0x160A;
int86x(0x2F, &in_regs, &out_regs, &seg_regs);
if (out_regs.x.ax == 0)
Running_WIN=TRUE;
provided here
union REGS in_regs, out_regs;
struct SREGS seg_regs;


You would need to find out what int86x does, and then find out the
meanings of the parameters, and figure out what interrupt 0x2f does on
Windows. Google is your friend. Look for "Ralph Brown's Interrupt List".

Sinan

--
A. Sinan Unur <1u**@llenroc.ude.invalid>
(reverse each component and remove .invalid for email address)

comp.lang.perl.misc guidelines on the WWW:
http://mail.augustmail.com/~tadmc/cl...uidelines.html
Nov 15 '05 #3
<ra*******@gmail.com> wrote in message
news:11**********************@g49g2000cwa.googlegr oups.com...
I want to know for what purpose union REGS and struct SREGS are
used in windows programming? also how following code an determine that
running OS is windows?
First of all, these types and the intel 80x86 CPU architecture are beyond
the scope of the standard C, and so is the compiler having support for them.
in_regs.x.ax = 0x160A;
int86x(0x2F, &in_regs, &out_regs, &seg_regs);
if (out_regs.x.ax == 0)
Running_WIN=TRUE;
provided here
union REGS in_regs, out_regs;
struct SREGS seg_regs;


As it has already been pointed out, for more on the DOS/windows interrupts,
see the Ralf Brown's Interrupt List freely available on the net. If you want
to know more about the intel 80x86 CPUs, you're welcome to
http://developer.intel.com -- get yourself free intel manuals, called
something like intel ia32 software architecture -- they're 3 volumes under
this name. If you want to know more about REGS and SREGS, please study the
documentation of your compiler. Borland C/C++ compiler for DOS comes with
built in help in the IDE, Watcom C/C++ compiler also comes with the full
documentation -- these are two compilers which I know to support this
feature.

Alex
Nov 15 '05 #4
Alexei A. Frounze wrote:

As it has already been pointed out, for more on the DOS/windows interrupts,
see the Ralf Brown's Interrupt List freely available on the net. If you want
to know more about the intel 80x86 CPUs, you're welcome to
http://developer.intel.com -- get yourself free intel manuals, called
something like intel ia32 software architecture -- they're 3 volumes under
this name. If you want to know more about REGS and SREGS, please study the
documentation of your compiler. Borland C/C++ compiler for DOS comes with
built in help in the IDE, Watcom C/C++ compiler also comes with the full
documentation -- these are two compilers which I know to support this
feature.

Alex

AND PLEEEEEESE REMEMBER:

THAT WILL NOT WORK UNDER WINDOWS!!!
Nov 15 '05 #5
"jacob navia" <ja***@jacob.remcomp.fr> wrote in message
news:43**********************@news.wanadoo.fr...
Alexei A. Frounze wrote:

As it has already been pointed out, for more on the DOS/windows interrupts, see the Ralf Brown's Interrupt List freely available on the net. If you want to know more about the intel 80x86 CPUs, you're welcome to
http://developer.intel.com -- get yourself free intel manuals, called
something like intel ia32 software architecture -- they're 3 volumes under this name. If you want to know more about REGS and SREGS, please study the documentation of your compiler. Borland C/C++ compiler for DOS comes with built in help in the IDE, Watcom C/C++ compiler also comes with the full
documentation -- these are two compilers which I know to support this
feature.

Alex

AND PLEEEEEESE REMEMBER:
THAT WILL NOT WORK UNDER WINDOWS!!!


Not as part of a win32 program, that's for sure. The O.P. didn't say he
would execute that code in a win32 app.

Alex
Nov 15 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

92
by: Reed L. O'Brien | last post by:
I see rotor was removed for 2.4 and the docs say use an AES module provided separately... Is there a standard module that works alike or an AES module that works alike but with better encryption?...
2
by: Yannick Benoit | last post by:
Hi! I use this to find all links in a page : *(href)*=*(+) but recently i found out that it only works if links are setup this way: <a href = "... I would like to know if someone can help...
7
by: tombsy | last post by:
Please can you tell me what version of DAO does access 2002/2003 use ? Access 97/2000 can use DAO3.5 and DAO3.6 Can I compact a 2002/2003 db using DAO 3.6? thanks in advance regs Tombsy
4
by: Bruno Barros | last post by:
Hello, I donīt know if union REGS <dos.h> is part of this group, but i have a problem. At the moment i use turboc++lite and i donīt have reply when i execute the question code. Only a black...
132
by: Frederick Gotham | last post by:
If we look at a programming language such as C++: When an updated Standard comes out, everyone adopts it and abandons the previous one. It seems though that things aren't so clear-cut in the C...
5
by: kushmanr | last post by:
hi i am having to problems: interrupt decleration doesn`t compile: void _interrupt _far terminal_isr() ....... _dos_setvect(0xC,terminal_isr) : error C4226: nonstandard extension used :...
0
by: balajiv86 | last post by:
hi can anyone tell me the book which contains details abt inbuilt union regs in c
3
by: vicky | last post by:
Hi, i am vikram Please tell me the usage of REGS key word how it can be used? any kind of suggestions will help me.
9
by: no | last post by:
Thanks- I intend to learn with Microsoft Tools but my plans are to stay within the embedded industry.
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.