Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

serial comms & uml beginner questions

 
Mary Boss
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm trying to put together a model for system that passes messages between serial ports. I have never done any OO or UML so I'm looking for some advice on where to start,what diagrams I need,or any useful links that can give me a "jump start". Thanks!
 
Ilja Preuss
author
Sheriff
Posts: 14112
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Mary, welcome at the Ranch!
I would advice you to care more about learning OO design than UML. UML is just a language for depicting designs - drawing those diagrams won't automagically generate you good designs; in fact I think it will delay important feedback from the code.
If you are also new to Java, but have some experience in a procedural language, I would recommend "Thinking in Java" by Bruce Eckels. It now only teaches the syntax of Java, but also basic OO design principles.
If you already feel somewhat comfortable with basic OO concepts, like inheritance, encapsulation etc., you could take a look at Robert Martins "Agile Software Development - Principles, Patterns and Practices".
Personally, I first groked what OO really is about while reading Martin Fowlers "Refactoring".
 
Pradeep bhatt
Ranch Hand
Posts: 8933
Firefox Browser Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ilja is right. Learning UML isnt tough but doing OOAD is really a challening job.
 
Ilja Preuss
author
Sheriff
Posts: 14112
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
By the way, "Thinking in Java" is available online (just google for it), whereas for Bob's and Fowler's books you have to visit the bookstore of your choice...
 
Robert Martin
Author
Ranch Hand
Posts: 76
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Mary Boss:
I'm trying to put together a model for system that passes messages between serial ports. I have never done any OO or UML so I'm looking for some advice on where to start,what diagrams I need,or any useful links that can give me a "jump start". Thanks!

It is a common misconception that models come before code, and drive the code. We like to think that we can forsee the structure of the code before it is written. In reality that structure evolves in ways that we cannot predict without actually writing it.
If you have never written code using an OO language, then I advise you not to begin with UML. Instead, begin by writing some OO programs.
 
Mary Boss
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Well, the thing is that I do know how to "just write the code" - but, I'm testing a tool that does code generation from the model - that is why I need help with diagrams. I actually want to see how usable code I can get from the model. I'm wandering if it is enough to do class (or object?) and sequence diagram. I'll ignore port settings - I only want to be able to open/close/read/write ports and I'm just not sure what diagrams I need, and what to put in them to "accurately paint the picture".
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic