Perhaps this is a very basic question, please pardon me if it is --- I'm a beginner in C#.
I have a WPF GUI for sending commands to a receiver. The commands are ASCII texts. Now, I separated the communication part into a separate project because I have console applications that use the communication methods in addition to the GUI. The communication DLL uses async methods on normal sockets.
Now the problem is that I will have a circular dependency. The GUI needs to call communication routines to send messages, and the routines need to call GUI to show the responses. I understand that I could make an interface which the communication inherits and get around the dependency, but is this the best way to do this? Or is this a flaw in my design? I basically wanted to decouple the GUI from the underlying communication layer.
Thanks a lot for the help!