BlinkyPlusLegacy example

The example BlinkyPlusLegacy is much like the Blinky example but shows how to send a UML event from legacy code into your Rhapsody model.

Open BlinkyPlusLegacy from the directory \ARXF_CP_V8.0.1\Samples\Autosar\Model\BlinkyPlusLegacy.

If one wants to send an event from outside a Rhapsody model into that model, the easiest to use an operation in your model and call that to send some event.

This example uses a runnable exampleLegacy which gets triggered by the RTE. The runnable and a function foo() are visible in the model, where they are incorporated via Reverse Engineering:

Compared to the example Blinky, SwcA now has an operation sendEventToLed() to send this event to the LED, just as the ControllerA does in Blinky:

In the Windows simulation, we use a dedicated thread to call the runnable exampleLegacy(). For this, we call RXF_Active_signalEventReceived() to force the runnable SwcA_eventDispatcherSwc() to be triggered.

Deployer

The Deployer will deploy Rhapsody generated source files and some generated configuration files into your IDE. If the combination of Rhapsody Component and Configuration has not been deployed yet, a Deployment Configuration dialogbox is shown.

Configuration Target

The Configuration Target is for AUTOSAR with configured Basic Software and RTE to build and run the three generated SWCs including the ‘legacy code’.

Please inspect some ArText files at <ARXF_CP_V8.0.1 installation folder>\ARXF_CP_V8.0.1\Samples\Autosar\ArText\RXFplusLegacy-artext which come with this product for informational purposes only. These will help you understand what to configure in your AUTOSAR tools:

Configuration Simulation

The Configuration Simulation can be used to build and run BlinkyPlusLegacy within Visual Studio.
If Visual Studio is not launched, do so and browse to the folder <ARXF_CP_V8.0.1 installation folder>\ARXF_CP_V8.0.1\Samples\Autosar\Model\BlinkyPlusLegacy\IDEProjects\Autosar\Simulation and select the solution file BlinkyPlusLegacy.sln

The Visual Studio project BlinkyPlusLegacy will automatically be updated and show the folders GeneratedModel, Library, RXF and Legacy.

The folder Legacy contains the legacy example code.

Select Build | Build Solution which will result in a BlinkyPlusLegacy.exe which you can debug.

Please read the section InteriorLight example before starting modeling yourself.