Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Lars

Pages: 1 [2] 3 4 ... 75
16
Games / Re: DOS VDM - USB and Game port Gamepad support
« on: May 13, 2023, 05:51:15 pm »
I had thought of contacting him to get him back on board with USB but I haven't done so.

It might be possible that he is doing fine but personal reasons holding him back from again getting engaged with OS/2. If he didn't answer you, it might be better to leave him alone.

17
Applications / Re: LVM.EXE cannot execute
« on: May 13, 2023, 05:37:32 pm »
Hi Neil,

by now I have identified the problem: for me, the problem was in USBMSD.ADD.
Very early in the system start process, OS2DASD.DMD and OS2CDROM.DMD call into USBMSD.ADD in order to find out what units it knows about. At that point in time, USBMSD.ADD knows of no unit because it has not even reset the HC controllers and started the device enumeration (at least with my driver set).
That's also the reason why you need the /REMOVABLES switch: it reserves units so that if USB MSD devices eventually show up, these can be assigned to one of these reserved unit slots.

And here comes the difference:
LVM.EXE expects that an error was reported to OS2DASD.DMD and OS2CDROM.DMD that no unit is yet ready. But Minilvm.EXE and LVMGUI can happily live with a NO_ERROR return.

So: how is your ZIP disk connected to your system ? Via IDE, USB or even via the parallel interface that required the proprietary PPAOS2.ADD driver ?

If it is via IDE (and therefore managed by DANIS506.ADD) I would think that you need to experiment with the various DANIS506.ADD switches so that DANIS506.ADD will return an error on that initial request for units.
If it is via USB, then I can say that the latest available code from IBM (that all existing USB drivers of today are based upon) was not doing the right thing.

18
Hardware / Re: Problem usbdrv248 - 10.248
« on: May 13, 2023, 03:52:35 pm »
Then the answer can only be: move away from OS/2.
It is no longer of practical use anyway (you can exchange data with Windows, but why do you then need OS/2 in the first place? Obviously, then you are also using Windows...).
If you see it as a hobby, then how much fun is it to wait for fixes that are never going to happen?

19
Hardware / Re: [Solved] Iomega ZIP 100 IDE
« on: May 13, 2023, 03:48:23 pm »
Hi Pete,

I don't see this as a problem. I have installed /REMOVABLES:2 - this is 2 disks. Another one is either a USB CDrom or a blank for ZIP 100. But the trouble is that when the floppy disk is inserted, this blank is not filled with real media data.

A floppy disk will never show up under LVM. And LVM will only show dummy units for whatever is specified via the /REMOVABLES switch.

20
Applications / LVM.EXE cannot execute
« on: May 13, 2023, 11:55:42 am »
I know this has been mentioned in the past but I cannot find the forum posts:

When I try to run "lvm.exe" I get this error in response:"Cannot get disk data from the LVM engine".

Strangely enough, if I instead run "minilvm.exe" or "lvmgui", then I have no problem running these two apps even though they also need to open the LVM engine to do their job.

I then had a look in Theseus to find out what is going on, in particular I checked what process loads "IVM.DLL" and "LVM.DLL" (these implement the LVM engine, I believe).
These two DLLs are loaded by PMSHELL.EXE but I could not find out exactly what loads these two DLLs (is it a WPS class ? Or what else ?).

Has anyone else also experienced this problem ?

21
Hardware / Re: Problem usbdrv248 - 10.248
« on: May 13, 2023, 11:18:40 am »
Igor is trying to mix the AN drivers and my USBMSD.ADD because the one from AN does not properly work with USB floppy drives. That worked in the past (per coincidence) but now fails because of the changes I had to do for USB boot support.
As always, if you use AN stuff: you have paid for it, you are entitled for support.

22
Programming / Re: Compiling a PM sample with GCC (2023)
« on: May 11, 2023, 05:04:21 pm »
Thanks Lars. Seems that this sample will be hard for me to compile or even to try to port it to 32bits.

On a general thing I would like to have more documentation of which is the old API and which is the new one, to try to document it clearly on the EDM/2 wiki.
For the moment my reference is the EDM/2 wiki where I tried to separate the current CPI API from the 1.x one. http://www.edm2.com/index.php/Control_Program_Functions_(Summary)

The 16-bit functions are all listed here: http://www.edm2.com/index.php/Category:Dos16
There might not be a staight 1:1 match between old 16-bit and new 32-bit.
Of course, you can still build the 16-bit examples. But you would not want to. If at all possible, convert them all to 32-bit. The only thing that comes to mind where you have to go through hoola hoops is when you try to run IOPL code (straight reads/write from/to IO ports). That still requires the core code to be 16-bit. And that in turn requires thunking so that you can call that from 32-bit code. But that's for another day (and I can provide example code as have done others).

23
Hardware / Re: Problem usbdrv248 - 10.248
« on: May 11, 2023, 07:05:31 am »
I cannot. USBMSD.ADD interacts with USBD.SYS in a certain way to allow boot support and the changes I made to USBMSD.ADD and USBD.SYS (and the HC drivers, but these are minor) also have a repercussion on the use of USBMSD.ADD if not booting from USB. I guess the AN USBD.SYS driver works differently. Sorry.

24
Programming / Re: Compiling a PM sample with GCC (2023)
« on: May 11, 2023, 07:02:41 am »
This is one of the points where it needs engineering judgement. DOSFRSEM (the various API functions: DosFSRamSemRequest etc.) implements a RAM semaphore and this is no longer supported with 32-bit OS/2 (the OS does no longer offer this, I guess this was decided in order to prevent undermining memory protection).
You will need to use Mutex semaphore instead. See Control Programming reference, search for "Mutex".

25
Programming / Re: Compiling a PM sample with GCC (2023)
« on: May 09, 2023, 09:39:31 am »
Hi

Now I'm going after PMColour.
https://github.com/OS2World/DEV-SAMPLES-PM-PMColour

It compiled and works with the tools I decided to use. I just have this warning about a pointer that I don't know how to solve it.

Code: [Select]
gcc -Wall -Zomf -c -O2 pmcolour.c -o pmcolour.obj
pmcolour.c: In function 'DlgProc':
pmcolour.c:116:23: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
  116 |      *cwdata->rgb = *((RGB *) &mp1);
      |                      ~^~~~~~~~~~~~~
gcc -Zomf pmcolour.obj pmcolour.res pmcolour.def -o pmcolour.exe
wrc pmcolour.res
Open Watcom Windows and OS/2 Resource Compiler Version 2.0beta1 LA
Portions Copyright (c) 1993-2002 Sybase, Inc. All Rights Reserved.
Source code is available under the Sybase Open Watcom Public License.
See http://www.openwatcom.org/ for details.

Any tip is welcome.

Regards

First, try this: *cwdata->rgb = (RGB)mp1;

If that still does not work, then consult the gcc Compiler's manual and see how you can disable the "strict-aliasing" warning.
"-Wstrict-aliasing" enables it so maybe "-Wno-strict-aliasing" disables it. You will have to find out.


The story behind this warning: first you tell gcc that mp1 is of type MPARAM which effectively evaluates to ULONG aka unsigned long int.
That would mean that &mp1 is a pointer to unsigned long int. Then all of a sudden you tell it that &mp1 is a pointer to an RGB.
Since gcc is a picky smartass it tells you that it's not ok to first claim it is a pointer to an unsigned long int and later claim it is a pointer to an RGB.

26
Programming / Re: Compiling a PM sample with GCC (2023)
« on: May 09, 2023, 09:35:05 am »
GCC disagrees, without the l,
Code: [Select]
gcc -Wall -Zomf -DOS2EMX_PLAIN_CHAR -c -O2 wintree.c -o wintree.obj
wintree.c: In function 'TraverseWindows':
wintree.c:150:26: warning: format '%X' expects argument of type 'unsigned int',
but argument 4 has type 'HWND' {aka 'long unsigned int'} [-Wformat=]
  150 |       sprintf(szLine,"%s%X...%s...%s",szLeader, hwndNext, szTitle, szClass);
      |                                       ~^                      ~~~~~~~~
      |                                          |                      |
      |                                         unsigned int           HWND {aka long unsigned int}
      |                                         %lX

The warning goes away with %lX.

Then gcc is a picky smartass.

27
Programming / Re: Compiling a PM sample with GCC (2023)
« on: May 08, 2023, 01:56:05 pm »
Use %u instead of %p. Or, if you want hex output, use %x.

GCC suggests %lu or %lx to fix the warning, and they do. Both work fine, personally I prefer the hex output as well, the original also had hex output.
Edit: Actually I like the capitals that %lX gives.
Hard to find what the l does, from the Linux man page on sprintf()
Code: [Select]
(ell) A following integer conversion corresponds to a long int or unsigned long int argument, or a
 following n conversion corresponds to a pointer to a long int argument, or a following c conversion
corresponds to a wint_t argument, or a following s conversion corresponds to a pointer to wchar_t
argument.

"l" stands explicitely for "long" as "h" explicitely stands for "short". For a 32-bit compiler you do not need to state "l" because that's the default. Likewise, for a 16-bit compiler, you do not need to state "h" as that's the default.

28
Programming / Re: Compiling a PM sample with GCC (2023)
« on: May 07, 2023, 10:16:48 pm »
Use %u instead of %p. Or, if you want hex output, use %x.

29
Applications / Re: ANPM - libc upgrade error...?
« on: May 06, 2023, 11:15:41 pm »
Just spotted that libc has been updated, so I figured I'd give this a go.

Firing up ANPM went just fine, but attempting to update that RPM consistently results in the following error (see attachment).

...so perhaps there is some sort of a scaling logic issue here? I do recall this is one of the changes that Alex rolled out in the last ANPM release.

BTW: nothing in POPUPLOG.OS2 and no TRP files.

Here is the full call stack until point of error:
Code: [Select]
Line 5 of RescaleObject in yumie.VRM:
+++                                                           x = VRGet(object, 'Left');
*** Error 40 Incorrect call to routine
Line 47 of SW_CONFLICT_Init in yumie.VRM:
+++                                                         Call RescaleObject 'DT_CONFLICT_IGNORE', factor;
Line 3 of SW_CONFLICT_Create in yumie.VRM:
+++                                                       Call SW_CONFLICT_Init;
Line 80 of Main in yumie.VRM:
+++                                                     Call SW_CONFLICT_Create;
Line 80 of Main in yumie.VRM:
+++                                                   Interpret __vrlsEvent;
Line 4 of ConflictPopup in yumie.VRM:
+++                                               Call VRLoadSecondary 'SW_CONFLICT', 'W';
Line 29 of DLLCheck in yumie.VRM:
+++                                             action = ConflictPopup('dll');
Line 102 of SW_DOWNLOAD_Init in yumie.VRM:
+++                                       c_action = DLLCheck();
Line 3 of SW_DOWNLOAD_Create in yumie.VRM:
+++                                     Call SW_DOWNLOAD_Init;
Line 80 of Main in yumie.VRM:
+++                                   Call SW_DOWNLOAD_Create;
Line 80 of Main in yumie.VRM:
+++                                 Interpret __vrlsEvent;
Line 547 of PyDone in yumie.VRM:
+++                             Call VRLoadSecondary 'SW_DOWNLOAD', 'W';
Line 51 of Main in yumie.VRM:
+++       Call PyDone;
Line 51 of Main in yumie.VRM:
+++     Interpret _VREEvent;

Maybe this has something to do with python (at least "yumie" is a python class), but I don't know. Let's hope that Alex will chime in.

30
Networking / Re: NAT Network & Host-Only Network
« on: May 05, 2023, 07:42:08 pm »
Shouldn't it be enough to have all guests in the same NAT network (I understood that Warp 4, Win NT and Win 2000 are all guests under some host, Linux/Win10/Win11 whatever) ?

I understood that "Host only" is for direct communication between a guest and the host but not between guests.

Pages: 1 [2] 3 4 ... 75