China DOS Union

-- Unite DOS · Advance DOS · Grow DOS --

Union site: www.cn-dos.net Forum site: www.cn-dos.net/forum
DOS stands for freedom, openness and progress. Let us work hard, learn from the openness and GNU spirit of FreeDOS and Linux, and together build and grow a free GNU GPL world!

中国DOS联盟论坛
The time now is 2026-08-01 16:35
中国DOS联盟论坛 » DOS开发编程 & 发展交流 (开发室) » Recently, some preliminary research and development achievements in DOS development View 3,844 Replies 33
Original Poster Posted 2007-07-26 10:56 ·  中国 广东 深圳 电信
初级用户
Credits 38
Posts 17
Joined 2006-01-16 16:53
20-year member
UID 49072
Status Offline
DOS programming is quite familiar, belonging to the earliest generation of writing programs with debug.com. But I haven't touched DOS for many years. So before starting work, I once posted here, hoping that experienced people would recommend or introduce a few relatively mature DOS development tools now. But unfortunately, no one replied, so I had to compare one by one. I would like to share my some conclusions for peers who encounter similar problems for reference. I think the optimal combination is DJGPP + ALEGRO. The reasons are as follows: DJGPP is 32-bit. Those who have experience all know why 32-bit code is easier to write than 16-bit code, which doesn't need to be explained more. DJGPP is based on GCC, with guaranteed quality, no need to waste time to get familiar with grammar characteristics. DJGPP is free, no potential copyright risks. ALEGRO already has all the commonly needed UI controls, checkbox, radiobox, text, list, etc., and can very easily support GB-encoded Chinese (saying that UNICODE format is needed is a misunderstanding of laypeople), can perfectly display Chinese without patching the source code. This is also relatively important. If patching the source code is needed, then in the future, with the version upgrade of alegro, one has to continuously maintain their own patch and is not sure whether the principle of the patch is still feasible, which will be a long-term drag. Mature compiler + mature graphics library. Developing products is different from playing with a small program by oneself. The significance of the word "mature" is very important. For IDE, rh is not easy to use. It is recommended to use VC and then call bat to achieve integration. Finally: I strongly suggest!!!! Do not believe those "xxx development packages" often seen in forums for promotion. I tested all that can be found, and there isn't a single one that works well. Either it is out of date, or the programming environment is bad, or there are compatibility problems. Such a suite is not something that can be well done by one or two people in one or two years in their spare time. Using these things that haven't been strictly tested, don't have special maintenance, lack technical support, and lack practical application is equivalent to letting the product commit suicide. Personal opinions, everyone has their own views. [ Last edited by sunx on 2007-7-26 at 11:03 AM ]
Floor 2 Posted 2007-07-26 11:21 ·  中国 福建 宁德 电信
初级用户
★★
Credits 178
Posts 85
Joined 2006-07-06 15:25
20-year member
UID 58125
Status Offline
But a shortcoming of DJGPP + ALLEGRO has been found currently. The compiled program will lose keyboard response on AMD 690 chipset or early ATI chipset. I have tried 4 different motherboards (ASUS, ONDA), and all have this situation. The owner may verify or correct it when free. I am getting old and now have no ability to find bugs.

If the content to be displayed is small, directly modify the font file. More than 100 ASCII characters are used. In fact, the ALLEGRO font corresponds to an image, and you can make the image as large as you want.

I strongly suggest!!!! Do not believe those xxx development kits often seen in forums for sale.

I object to this. The binary development kits of Winsail and ecurb2006 themselves are free. The ecurb function is a bit weak. Personally, I feel Winsail is still very convenient. I am not a shill for Winsail. I have written several programs with Winsail before, and they are all pretty good. But I haven't tried the environment like the industrial control industry that needs long-term stable operation.

[ Last edited by zqlcch on 2007-7-26 at 11:23 AM ]
Floor 3 Posted 2007-07-26 13:10 ·  中国 广东 深圳 电信
初级用户
Credits 38
Posts 17
Joined 2006-01-16 16:53
20-year member
UID 49072
Status Offline
For a small number of hardware that can't run, of course there's no way.
As long as the hardware supports it, djgpp is still the first choice.

Winsail and ecurb2006, if used in commercial products, are chargeable.
The free package of ecurb2006 currently only supports 16-bit.
I feel that Winsail is modified from a SourceForge project that hasn't been updated for several years.

My feeling about both of these is that they are relatively crude, and overall, they are patched layer by layer from something lacking overall design, so there are many messy places, which makes me uncomfortable to look at.


Personal opinion, forgive me if it touches on the manufacturer.

[ Last edited by sunx on 2007-7-26 at 01:23 PM ]
Floor 4 Posted 2007-07-26 14:02 ·  中国 广东 深圳 宝安区 电信
初级用户
★★
Credits 138
Posts 67
Joined 2007-07-04 10:11
19-year member
UID 93093
Gender Female
From 云南
Status Offline
Why use DJGPP when you can use Windows directly? I don't understand!
Can the owner explain it?

My personal feeling is "DJGPP is a good thing, but it was born at the wrong time. It is more complicated than programming for WinCE, has not had a good mass base, and there are almost no Chinese documents"!

[ Last edited by windowsvesta on 2007-7-26 at 02:12 PM ]
Floor 5 Posted 2007-07-26 15:05 ·  中国 广东 深圳 宝安区 电信
高级用户
★★
Credits 668
Posts 295
Joined 2005-07-26 00:00
21-year member
UID 41110
Gender Male
From 广东深圳
Status Offline
The purpose of WinSail's development is for industrial control applications. It has undergone nearly ten years of practical application in the market, and it is safe, stable, and reliable, worthy of everyone's trust!

Interface 1:


Interface 2:


Interface 3:


Interface 4:



Interface 5:


[ Last edited by firstsail on 2007-7-26 at 08:07 PM ]
Floor 6 Posted 2007-07-27 04:15 ·  中国 广东 深圳 电信
初级用户
Credits 38
Posts 17
Joined 2006-01-16 16:53
20-year member
UID 49072
Status Offline
You seem not to know what DJGPP is. DJGPP is a compiler, no essential difference from TC, BC. You can actually compare a compiler with Windows, speechless.

Originally posted by windowsvesta at 2007-7-26 14:02:
Where there can use DJGPP, why not directly use Windows, I am very puzzled!
Can the landlord explain it for me?

My personal feeling is "DJGPP is a good thing, but it was born at an inopportune moment, it is more complicated than WinCE programming,...
Floor 7 Posted 2007-07-27 10:01 ·  中国 广东 深圳 电信
高级用户
★★
Credits 668
Posts 295
Joined 2005-07-26 00:00
21-year member
UID 41110
Gender Male
From 广东深圳
Status Offline
My View on DJGPP, which Only Represents My Personal Opinion, Not Universality!

We often say phrases like "DOS programming", "Windows programming", "WinCE programming". If we must be pedantic and analyze the Chinese grammar of these sentences, we can regard such words as "what only an utterly ignorant person would say". DOS is an operating system; can it program? "Windows" is also an operating system; can it program?

The "DOS programming" we often talk about generally refers to programming using compilers under DOS, such as tools like Turbo C, Basic, BC31, Pascal, DJGPP, etc.

The "Windows programming" we often talk about generally refers to programming using compilers under Windows, such as tools like Visual C++, Borland C++, Visual Basic, Visual Foxpro, etc.

So for IT vocabulary, as long as everyone reaches a common understanding!

"XXX development kit" is not mutually exclusive with DJGPP, with Borland C++/Turbo C, with Basic, etc., but rather a complementary relationship. For example, after compiling the C++ source code of the "development kit" under the DJGPP compiler, at least more than 95% of the code can become a development kit under DJGPP without any modification. Broadly speaking, "XXX development kit" is independent of compilers.

Regarding C++ compilers under DOS, in my personal opinion, I still prefer Borland C++ 3.1 first. Regarding C compilers under DOS, I prefer Turbo C first. Regarding Basic compilers under DOS, I prefer QBasic first. Regarding Pascal compilers under DOS, I prefer Turbo Pascal first.

I prefer Borland C++ 3.1 first because:
(1) It integrates "editing, compiling, linking, debugging" into one.
(2) At least more than 90% of C++ programmers under DOS are familiar with it, having a vast mass base.
(3) At least 95% of actual programming applications under DOS C++ programming can be satisfied.
(4) In libraries, books about "BC31/45" function libraries are still available now (2007).
(5) Chinese is monosyllabic vocabulary. "BC31" has only two letters "BC" and they are two consecutive letters, which is easy to remember; while "DJGPP" has five letters and the letters are scattered, which is not easy to remember. So in terms of name, from the Chinese habit, BC is superior to DJGPP.

Based on the above five points, there is still a long way for DJGPP to surpass BC31, and it will be quite difficult to do so......

[ Last edited by firstsail on 2007-7-27 at 11:42 AM ]
Floor 8 Posted 2007-07-27 15:41 ·  中国 广东 深圳 电信
初级用户
Credits 38
Posts 17
Joined 2006-01-16 16:53
20-year member
UID 49072
Status Offline
I don't completely agree with what firstsail said.
But most of it has nothing to do with the things I want to discuss in my post. Here I only argue about what is related to the topic:

For a developer, always looking for a better development tool.
It's not that just meeting the programming needs is enough.

The first version of WPS was written with debug.com. Now we can't do such things again because times are progressing and the development of development tools is continuously simplifying programmers' work. But in that specific era at that time, debug.com was the only best development tool.

BC is the same. BC has its glorious achievements. In the category of 16-bit pure DOS development, BC is universally recognized as the best. But BC has stopped developing for many years. For the new technologies in these many years, BC has no support.

1. BC doesn't support 32-bit. People who have written many DOS programs must have deeply felt the helplessness about seg:ofs and the 64K maximum memory segment limit. Now for products, it's very normal to have a larger data table. Dealing with large data in 16-bit is annoying to think about.

2. There is a lack of powerful graphics support under BC. Well, you said we are Chinese. Chinese people need Chinese characters and have to deal with graphics. There are BGI graphics and TV UI. Unfortunately, there is no TV+BGI GUI.

3. The DJGPP compiler is GCC. In the present, the mass base of GCC is恐怕 much larger than BC. People using Windows may not necessarily use BC, but people who have used Linux must have dealt with GCC.

4. Unless there is no other choice, still don't use something that has stopped developing. Actually, the current situation of BC is not even as good as an open-source tool. Borland company doesn't care about it. Amateur programmers want to improve it but can't; on the contrary, DJGPP/Alegro is always developing. You report a bug, and it will be corrected in the next version soon.


-----------------------------------------------------------------------------------------------------------


Finally, I really can't help but say one thing. Your fifth point is really a bit too absurd. Otherwise, in the future, when we choose things, we'll learn from Stephen Chow. Take a ruler to measure length. Haha, just a joke. No malicious intent.
Floor 9 Posted 2007-07-27 18:34 ·  中国 天津 电信
初级用户
★★
Credits 178
Posts 85
Joined 2006-07-06 15:25
20-year member
UID 58125
Status Offline
DJGPP is very widely used abroad. For example, the multi-platform emulator mame is made with djgpp + allegro. On the contrary, BC has basically disappeared.

Due to the problem of mother tongue, very few people in China use DJGPP. This is a weak point for Chinese people to learn computer.
Floor 10 Posted 2007-07-27 19:02 ·  中国 广东 深圳 电信
初级用户
★★
Credits 138
Posts 67
Joined 2007-07-04 10:11
19-year member
UID 93093
Gender Female
From 云南
Status Offline
Since "DJGPP" is based on 32-bit operation under DOS and has such a large market, why don't foreigners develop it into the style like Visual C++? Is this a technical issue, or is it that the development investment is not proportional to the market return?

[ Last edited by windowsvesta on 2007-7-27 at 07:07 PM ]
Floor 11 Posted 2007-07-27 19:18 ·  中国 广东 深圳 电信
初级用户
★★
Credits 138
Posts 67
Joined 2007-07-04 10:11
19-year member
UID 93093
Gender Female
From 云南
Status Offline
I believe that as long as Borland is willing, developing a 32-bit protected mode compiler under DOS will definitely be the best 32-bit protected mode compiler! But why doesn't Borland want to upgrade "BC" to a 32-bit protected mode compiler?
Personally, I think that a 32-bit protected mode compiler under DOS won't cause a big stir, and will only be applied in "special occasions", and mainly limited to "elite people" using it! So DJGPP is naturally "elite and non-popular".
UNIX takes the elite path, Windows takes the popular path, who wins and who loses?

[ Last edited by windowsvesta on 2007-7-27 at 07:35 PM ]
Floor 12 Posted 2007-07-27 21:01 ·  中国 广东 深圳 电信
高级用户
★★
Credits 668
Posts 295
Joined 2005-07-26 00:00
21-year member
UID 41110
Gender Male
From 广东深圳
Status Offline
"BC does not support 32-bit. Those who have written many DOS programs must have deeply felt the helplessness regarding the seg:ofs and the 64k maximum memory segment limit."


Only in the assembly language era did people often deal with "Seg : Off". After entering the high-level language (such as BC31) era, such dealings can be said to be "a wait of a thousand years".

Now products have a relatively large data table, which is very normal. Just thinking about handling large data under 16-bit makes people feel irritable.

If you are not afraid of "millisecond"-level lag when handling a large amount of data, you can completely use XMS extended memory to solve it, and the XMS internal processing itself is also in "protected mode".

BC lacks powerful graphic support. Well, you also said that we are Chinese. Chinese people need Chinese characters and have to deal with graphics. There are BGI graphics and TV UI. Unfortunately, there is no TV+BGI GUI.


In fact, BC31 has the most powerful graphic support among all compilers under DOS. It just has no GUI part. So I launched the GUI part of WinSail to make up for its deficiencies, just as Alegro makes up for the deficiencies of DJGPP.

The DJGPP compiler is GCC. In today's terms, GCC has a much larger user base than BC. Those who use Windows may not necessarily use BC, but those who have used Linux must have dealt with GCC.



I don't quite agree. Tools like TCC, BCC, and GCC are mainly used by people programming under UNIX, who are forced to use them and thus become familiar with them. There is a data: "More than half of database applications are written in Visual Basic". So people who use xCC are definitely very few! Only high-level experts are proficient in using it.

Unless there is no other choice, it is still not to use something that has stopped developing. In fact, the current situation of BC is not even as good as an open-source tool.


The fact is: DJGPP may not provide open source code either! Windows doesn't provide open source code either, and ordinary people still use it happily!

Finally, I really can't help but say that your fifth point is a bit too nonsensical. Otherwise, in the future, when we choose things, we can learn from Stephen Chow, measuring length with a ruler, haha, just a joke, no malice.


Brother SunX should not underestimate the feeling of Chinese people towards "English names". Words like "Alegro" can't be found in the "Oxford Dictionary" or in the "Kingsoft Ciba". In short, so far, I still can't pronounce it. Seeing unfamiliar "combinations of English letters" makes my eyes go blurry. I don't know why God created the "Latin family".

Look at today's "celebrities", most of them have been transformed by "feng shui masters", such as Jackie Chan, Faye Wong, and Stephen Chow, etc. "Feng shui" is a hard-to-fathom science! Believe it or not.


So I think "DJGPP" only has its vitality under UNIX! Only there is the soil for its development.

[ Last edited by firstsail on 2007-7-27 at 09:33 PM ]
Floor 13 Posted 2007-07-27 22:23 ·  中国 福建 厦门 电信
高级用户
★★★
Credits 741
Posts 366
Joined 2007-07-25 19:11
19-year member
UID 94024
Gender Male
Status Offline
Now the computer hardware is developing too fast. I raise a question - it is said that the next generation of Intel chipset will cut off LPT, COM, PCI. DOS based on the old kernel may have a hard time adapting. I wonder what everyone's plan is?
Floor 14 Posted 2007-07-27 23:30 ·  中国 福建 厦门 电信
高级用户
★★★
Credits 741
Posts 366
Joined 2007-07-25 19:11
19-year member
UID 94024
Gender Male
Status Offline
As for industrial control, there were a lot based on MSDOS and DRDOS in the early 1990s. In recent years, those based on Windows have accounted for the majority. More and more use VB + AD/DA acquisition card driver programs (fast development speed). In the past one or two years, even AD/DA cards are becoming fewer and fewer, and those directly using USB are gradually becoming popular. When it comes to freedom, bare metal is the freest. Why do we use an operating system? It's to call its functions. But most of the functions that DOS can offer us are concentrated mostly in the DISK aspect.
Floor 15 Posted 2007-07-28 01:12 ·  中国 广东 深圳 电信
初级用户
Credits 38
Posts 17
Joined 2006-01-16 16:53
20-year member
UID 49072
Status Offline
Work is something tangible; it can't be based on "what ifs."
For whatever reason, Borland didn't develop 32-bit, and it just didn't happen. I say that Borland at that time didn't have the ability to update the BC compilation core (the BC team disbanded, and the Delphi project was very urgent), and many people must be unwilling to accept that.
As for whether 32-bit is good or not, there's no need to argue about this because it's something that's a matter of consensus.

-----------------------------------------------------------------------------------------

By the way, I want to say to firstsail that it's pointless for you to argue with me.
Because as developers, what we need is not just to be usable, but to be as easy to use as possible.
Of course I understand that seg:ofs can also meet the usage, and I'm also clear that XMS can store data, but that can't be a reason for me to give up using 32-bit flat addressing, to rely on adjusting segments to access data exceeding 64k, and to rely on the XMS management interface to copy and switch memory back and forth.
It's like, there's a place I can go by car, but you非要 me to walk there, and there's no reason for that.
People's time and energy are limited, so one has to make the optimal choice in terms of methods.
For the same reason, considering stability, vitality, and long-term costs, I know that BC + Winsail can also be used, but that can't be a reason for me to give up using DJGPP + Allegro, which is open-source, free, has a wide user base, and is such an excellent thing.
Also, before denying something, one should fully understand that thing first, so that one's judgment will be reasonable and well-founded.
DJGPP is open-source; the version ending with s in each package is the source code.
You also said that GCC, which now has such strong influence, is something that only people under Linux would be forced to use.
When it comes to DJGPP/GCC/Linux, you should at least take all those and write a few programs more complex than hellworld, so that there will be a real feeling.
I have no grudge against Winsail. If the thing is good, I will use it too.

[ Last edited by sunx on 2007-7-28 at 01:33 AM ]
Forum Jump: