Linking two DS sessions on a PC usually comes down to one emulator: NO$GBA, which has long been the go-to for local multiplayer experiments because you can launch it more than once.
The method is straightforward. Open the emulator, load your game, then open a second instance and load it again. Each window behaves as its own console, which is what you need for trade or versus setups.
The catch is save data. Two instances reading and writing the same save file will overwrite each other, so duplicate the game folder, drop the copy somewhere else, and boot the second instance from that location. That gives each session its own independent save.