The Blog for Rhapsody (Power) Users.

Month: April 2019

Transylvania

Je komt nog eens ergens

That is Dutch and means something like: “You go places”. Yes I certainly do. This time I had to be in Rumania to do a training for a customer that has a development center there.
Because everything was organized in a hurry I did not really prepare well for this trip. That is, I did the necessary things but no more than that. So I was not be able to visit the HardRock Cafe in Bucharest since that is a 5 hour drive away from Sibiu where I was located. My flights would stop in Buicharest but not long enough unfortunately.
My original plan to fly to Bucharest and take a car was not a good one, Romania does not have a concept of highways like we do. So the average speed will be under 50km/h which effectively rules out using a rental car. Also the rentals were really expensive, no idea why, cars are not really expensive in Rumania.
I also did not look up anything about the place I was about to visit..

Rumania is not _really_ Europe

They are part of the European Union, without the Euro though, they use their own currency, but that was not really noticeable. KLM did not offer flights to Sibiu on their website although I managed to find flights from AMS via OPT to SBZ (OPT = Bucharest, SBZ is Sibiu) via another website. I decided to phone with the Platinum Hotline (Hey! You have to use what you’ve got!) and they advised men to use the Air France Website and…. bingo. That was possible. The wonders of Air Travel.. KLM-Air France say they are one organization but as far as I know they are far from that.
Also going in and out I had to show my ID. Schengen??? “Never heard of”…

Looking Good, or?

Coincidentally I looked on my phone in the Air France app and I noticed that there was a message. I looked on it and it said: Your flight is cancelled, please contact the ticketing Buro.
Cool. What if I had not looked??? So phone again with the hotline. This was all done during my previous trip in a car driving from Germany to France via Switzerland… They said the last part of the trip was cancelled. This was the Tarom (Rumanian Air Company) flight from OTP-SBZ. First they told me I had to fly on another day. After i (still politely) explained them that that was a real bad idea because people would be waiting for me… They completely rebooked me to a Lufthansa flight AMS-VIE-MUC-SBZ (Yes… Vienna, Munich in that order…) Hopping through Europe like a crazy kangaroo… Also I would arrive at 1:10 am on the next day.

Later at home I phoned again and now they had a better alternative, AMS-MUC-SBZ, arriving 18:00 on the correct day. “Geht doch”…

Without Status…

I had already arranged that my XP would still be booked (important, I do not want to loose my fresh status on KLM) but I noticed that contrary to KLM (Where they really treat you well as a status passenger) Lufthansa did not know me at all…. And did not let me in their lounge nor would they give me a nice chair. They promised me a window seat on the flight from Munich. I had a seat next to the place where normally the windows are. Unfortunately not on that row….
But I arrived. And on time. The hotel was also close to the airport and the company where I had to be. Going by foot was not advised so i still used taxis but they are very cheap in Rumania. (Even when the taxi driver screws you…)

Dracula

Yes… I have to mention it… The part of Rumania where I was is Transylvania. Home of the famous Count Dracula. And Vampires and so. Luckily I do not believe in that.
Sibiu is a very nice city, definitively worth another visit!!!
My friend Jan Scholten (who has been in Rumania before) told me that Sibiu has a German speaking minority and that the town was also known as “Hermannstadt“. Since it has been the cultural capitol of Europe (in 2007) a lot of Restauration took place and it looks really beautiful!

Training

This was again an example of the necessity of having a training when you start to use Rhapsody. There are so many things that you can learn very fast from an experienced person but can hardly read in a book because you cannot find the connection between all that is written.
The Rhapsody manual is 600 pages, it does not nearly cover all topics and still you find nothing unless you really know what you are looking for.
Yes, partly that is due to the fact that the Rhapsody GUI is not always as easy as it could be. But I know that people are working very, very hard to improve that. Rhapsody 8.4 will be a great step in that direction. But even if the GUI would have been perfect, it is still a lot of stuff you have to learn.

Shortcuts

Three times in a row I met people that were quite experienced in Rhapsody but still did not know the keyboard shortcuts that make life so much easier….

  • Pressing “Alt” during resizing elements on diagrams will only resize the “outer” element and leave the content of the resized element as it is. (You can do that via the normal menu as well…)
  • Pressing “Shift” when dragging up or down in a sequence diagram will shift everything under the cursor up or down. (That way you can create or fill space on a Sequence diagram)
  • You can “multi” select using Shift and/or CTRL. You can then delete multiple items but also change “common” features or Display Options.
  • In the (OK…not so really cool) Editor you can select Rhapsody Model elements with CTRL-Space. (Intellivisor) The one in Eclipse (Or VS) is better but it’s not bad at all! Saves typing!
    Have you already tried the “Mouse menu” feature? Right clicking in a diagram gives you all possible model elements for that position. You don’t have to move the mouse to the menu and back!

That’s it! Have fun modeling with Rhapsody!

Walter van der Heiden (wvdheiden@willert.de)

Travel, travel, travel and… my EW 2019 Presentation

Back in the air

The travel continues but hey… I’m the traveling modeler…. Last week I had an appointment in France but close to Switzerland so I took the plane to Geneva again.
As usual the moment of booking is mostly right before the mail or call with the question if you could also show up somewhere else.
Flexible as I am, I always try to arrange that. This was not so easy… I had to be in the south of Germany (Rietheim) and I was is France (Cluses). On the map that was 225km. Via the road it turned out to be almost 500…. The Swiss have these “Mountains” that really take in a lot of space…
But I organize all of it and so I took the train to Schiphol (My second home) and then the plane to Geneva. Unfortunately (also as usual) flights were cancelled and I was rebooked to another flight via Paris. Via CdG, not really my favorite airport (I try to be polite)
CdG lived up to its reputation… although I was only a few meters away from the gate of my connections flight I had to take a detour to go through the pass control… ( What happened to Schengen?) But I made it in time to the connecting flight (I could even drink coffee in the lounge.)

Platinum

Yes. The lounge… since recently KLM has handed me my platinum card. I crossed 300XP within one year. (Yes KLM no longer has miles… you earn XP when you fly, like in Pokémon Go)
This makes the traveling life much more easy and comfortable. And a comfortable place to write BLOg entries…

Snow!

Yep… Snow. And a lot. After flying the second leg of the trip to Genève, I picked up my rental car and drove out of the parking lot and asked myself: What is this white stuff falling from the sky??
It was snowing. I did not expect that. Luckily Hertz was so friendly to rent me a BMW 120d xDrive. (4-wheel Drive ) with decent wintertyres. That helped. But is was quite a drive. So finally I arrived at the hotel that luckily had parking places. And (what I first noticed in the morning, a Skipass machine… I was in a ski area….

Switzerland

the next day, after a good day at the customer I drove to Rietheim in south-Germany. That was a seriously long drive. Through a lot of snow.. And again arriving in the hotel at 10pm… After the customer visit the next day I had to drive almost the same distance back. Not as far because I had a hotel room close to the airport. The next day I returned the car and flew back without trouble.

Embedded World 2019

I have written about that already: EW 2019, we had a booth there but I also had a presentation! Not entirely about Rhapsody but about SECollab, also interesting enough! Here is the link to it: video, it is in English.

That was it! Happy modeling with Rhapsody!

Walter van der Heiden (wvdheiden@willert.de)

Roger Waters Factory Pattern

Us + Them

That is the name of the Roger Waters tour. I managed to buy tickets for the concert in the ZiggoDome on June 22 and I went there with my cousin and my son. It was a bit stressful… I just arrived from Switzerland, went home by train and back to 020 by car. But I managed and… I have seen a lot of concerts, ranging from mwoah OK to fabulous but this was one of the best (if not the best) I ever saw. And I have seen Pink Floyd (Rotterdam 1993), Genesis, U2, the Stones and Peter Gabriel (multiple times)


Sound quality was absolutely awesome, before the break the show was fantastic, after the break it became breath-taking. Not bad for a 75-year-old guy…
I think the Pink Floyd guys always had fantastic sound quality but the technology now really offers them what they wanted to have 30 years ago.

The Factory you see is (of course) Battersea Power Station, as seen on the Animals Album. It was projected as were many other things. I am listening to the Animals Album while I am typing this….

Battersea Power Station from the river.jpg
By Alberto PascualOwn work, CC BY-SA 3.0, Link

 

OK… back to work. speaking about Factory…

That reminds me of the factory pattern. A nice pattern that helps you creating objects where you don’t know at compile time what class you want to use.
I always look for design patterns in one of my favourite books: Head First Design Patterns. Do yourself a favour: buy it (And in English please…, the German translation sucks.)

I use the Factory pattern in a model where I have 3 different platforms to generate code for, Linux, Windows and Keil CMSIS, and there is a possibility that it needs to be adapted to QNX as well.
I want to have a common debug output but also some interprocess communication that works different on all platforms.
This sounds easy, just define interfaces and inherit from them. (Or to be correct: create realizations)
Now that sounds cool but when you need to instantiate the objects (semi-)dynamically you cannot use that. You have to call something that is not the same on all platforms.
This is where the factory comes in. You create a global Class/Object (with a fixed name i.e. AbstractFactory) that has a static function “getInstance” (Yes correct… that is a singleton!) that checks if a static variable is already filled with a value. If NULL it will create an object and store it in the class variable otherwise it just returns the variable.

You then have a certified entry point. The Abstract Factory class should then have functions that create concrete factories for the environment. In this case I needed a LinuxFactory, a QNX Factory and a Windows Factory.

In the concrete factories you will make create_xxx functions that create objects for the classes you need. This can be multiple objects but also a singleton.

In a random class you can then call:

MyDebug = AbstractFactory::getInstance()->createDebugOutput()

This will give you a pointer to a class that handles the debug output. This is also a singleton. For the IPC it was just a “new” that created an IPC Channel.

Design Patterns rule!

Some useful reminders:

  • Separate what varies from what stays the same
  • Composition is better than Inheritance
  • Program to an Interface rather than to an implementation.

That was it, happy modeling with Rhapsody

Walter van der Heiden (wvdheiden@willert.de)

© 2025 Rhapsody Tech Blog

Theme by Anders NorenUp ↑