Home » Eclipse Projects » Papyrus for Real Time » Unable to add log port in the middle of the capsule
| | | | |
Re: Unable to add log port in the middle of the capsule [message #1794312 is a reply to message #1794311] |
Tue, 28 August 2018 19:23 |
Ernesto Posse Messages: 438 Registered: March 2011 |
Senior Member |
|
|
The downloads page at at https://www.eclipse.org/papyrus-rt/content/download.php shows four different options:
1) All-in-one RCP
2) The Papyrus-RT installer
3) The Eclipse installer
4) Manual installation.
The all-in-one RCP is, as the name says, all in one: you do not install it on top of an existing Eclipse install as an update site, you just unzip it and execute it (in Windows you will see an executable file in the folder extracted) and it comes with all dependencies.
The "Install New Software..." option is only when you use update sites explicitly. The RCP is not an update site, but a self contained application. That is different from the Eclipse installer, the Papyrus-RT installer or update sites. Therefore, you do not have to use the "Install New Software..." option to install Papyrus-RT if you downloaded the RCP.
Like I said in my previous message, I strongly recommend installing the RCP, and not from an update site if you are not very familiar with installing Eclipse plugins and their dependencies. As mentioned in the download page, if you need to install it on top of an existing Eclipse installation from an update site, you will have to manually install dependencies, and this is not trivial.
By the way, the 0.9 appears in that page near the bottom under the title "Older releases". If you read carefully, you'll see the 1.0 version under "Current releases" before the section on older releases.
|
|
|
Re: Unable to add log port in the middle of the capsule [message #1794348 is a reply to message #1794312] |
Wed, 29 August 2018 10:36 |
hey you Messages: 15 Registered: July 2018 |
Junior Member |
|
|
Hey Ernesto I downloaded now Papyrus for Real-Time 1.0.
however I again cannot add again state diagram to my capsule. I tried to undertake steps from your 1st steps, but it did not work. See attachments on how I created the project and on what is configured under "profile" and "language" tabs.
EDIT: I have managed to resolve it, I should have created new state-diagram under most top model, not under capsule.
Regards,
Ivan
[Updated on: Wed, 29 August 2018 14:43] Report message to a moderator
|
|
| |
Re: Unable to add log port in the middle of the capsule [message #1794365 is a reply to message #1794357] |
Wed, 29 August 2018 15:25 |
hey you Messages: 15 Registered: July 2018 |
Junior Member |
|
|
Ernesto Posse wrote on Wed, 29 August 2018 14:15The screenshot in "PRT_fsm.png" suggests that in the Model Explorer you are right-clicking the *capsule diagram* element (the yellow icon), rather than the *capsule* element itself (the icon with the <<Capsule>> stereotype). To create elements in a capsule (or any other UML element), you have to select and right-click the UML model element, not the diagram element.
Yes I realized that later on, I edited post ... did not refresh the website so I did not see your post. Anyways I managed to generate the code now. I followed instruction on how to compile and execute code as stated on the link but I am getting error when executing makefile.
Also link doesn't work under:
"Using an OS other than Linux
If you are using an operating system other than Linux, you can still compile and run your model. Go to Compiling and running Papyrus for Real Time applications for alternatives"
Is it possible to compile and execute code inside the papyrus on win10?
I will also try to install papyrus-rt on linux, the screenshot I sent was from Virtual Machine running Ubuntu on it, so I basically generated code on win10 and copy pasted it on VM. I guess problem with executing makefile is due to missing includes from Papyrus-RT libraries.
[Updated on: Wed, 29 August 2018 15:31] Report message to a moderator
|
|
| | | |
Re: Unable to add log port in the middle of the capsule [message #1794444 is a reply to message #1794383] |
Thu, 30 August 2018 16:32 |
hey you Messages: 15 Registered: July 2018 |
Junior Member |
|
|
I installed Cygwin setup-x86_64.exe (64-bit installation) from this website: https://www.cygwin.com/
$ cmake --version
cmake version 3.6.2
CMake suite maintained and supported by Kitware (kitware.com/cmake).
$ gcc --version
gcc (GCC) 7.3.0
GNU Make 3.82
Built for x86_64-w64-mingw32
This program is built by Equation Solution <http://www.Equation.com>
for Windows.
I have installed cmake from Cygwin setup-x86_64.exe file.
Things is I cannot event compile the files from ...\plugins\org.eclipse.papyrusrt.rts_1.0.0.201707181457\umlrts folder, under step Building the runtime system from tutorial. This is the output when I run make command:
Johnny@DESKTOP-EAEO31B ~/Desktop/org.eclipse.papyrusrt.rcp.product-win32.win32.x 86_64/Papyrus-RT/plugins/org.eclipse.papyrusrt.rts_1.0.0.201707181457/umlrts
$ make
Makefile:63: warning: TARGETOS not defined. Choosing linux
Makefile:69: warning: BUILDTOOLS not defined. Choosing x86-gcc-4.6.3
g++ umlrt/src/umlrtgetopt.cc -c -Wall -I./util/include -I./include -I./umlr t/src/include -I./os/linux/include -oobj/linux.x86-gcc-4.6.3/umlrt/src/umlrtget opt.o
make: [obj/linux.x86-gcc-4.6.3/umlrt/umlrtapi.o] Error 1 (ignored)
g++ umlrt/umlrtapi.cc -c -Wall -I./util/include -I./include -I./umlrt/src/i nclude -I./os/linux/include -oobj/linux.x86-gcc-4.6.3/umlrt/umlrtapi.o
make: [obj/linux.x86-gcc-4.6.3/umlrt/umlrtbasicthread.o] Error 1 (ignored)
g++ umlrt/umlrtbasicthread.cc -c -Wall -I./util/include -I./include -I./uml rt/src/include -I./os/linux/include -oobj/linux.x86-gcc-4.6.3/umlrt/umlrtbasict hread.o
make: [obj/linux.x86-gcc-4.6.3/umlrt/umlrtcapsule.o] Error 1 (ignored)
g++ umlrt/umlrtcapsule.cc -c -Wall -I./util/include -I./include -I./umlrt/s rc/include -I./os/linux/include -oobj/linux.x86-gcc-4.6.3/umlrt/umlrtcapsule.o
make: [obj/linux.x86-gcc-4.6.3/umlrt/umlrtcapsuleid.o] Error 1 (ignored)
g++ umlrt/umlrtcapsuleid.cc -c -Wall -I./util/include -I./include -I./umlrt /src/include -I./os/linux/include -oobj/linux.x86-gcc-4.6.3/umlrt/umlrtcapsulei d.o
make: [obj/linux.x86-gcc-4.6.3/umlrt/umlrtcapsuletocontrollermap.o] Error 1 (ign ored)
g++ umlrt/umlrtcapsuletocontrollermap.cc -c -Wall -I./util/include -I./inclu de -I./umlrt/src/include -I./os/linux/include -oobj/linux.x86-gcc-4.6.3/umlrt/ umlrtcapsuletocontrollermap.o
umlrt/umlrtcapsuletocontrollermap.cc: In static member function 'static bool UML
RTCapsuleToControllerMap::parseCapsuleControllerLine(char*)':
umlrt/umlrtcapsuletocontrollermap.cc:205:55: error: 'strtok_r' was not declared in this scope
capsuleName = strtok_r( line, " =\n\r\t", &saveptr);
^
make: *** [obj/linux.x86-gcc-4.6.3/umlrt/umlrtcapsuletocontrollermap.o] Error 1
[Updated on: Thu, 30 August 2018 16:35] Report message to a moderator
|
|
|
Re: Unable to add log port in the middle of the capsule [message #1794446 is a reply to message #1794444] |
Thu, 30 August 2018 17:15 |
Ernesto Posse Messages: 438 Registered: March 2011 |
Senior Member |
|
|
Ok, perhaps the instructions are not clear enough, but if you are building under Cygwin, you do not have to build the RTS manually as you seem to be trying to do. Building the RTS explicitly is only for Linux, not for Windows+Cygwin. The instructions at https://wiki.eclipse.org/Papyrus-RT/User_Guide/Compiling_and_running_Papyrus_for_Real_Time_applications under the section Building the runtime system begin with a note that reads:
Quote:Cygwin users
If you are on Windows using the Cygwin setup, skip this section and go directly to Building your applications on Windows with Cygwin
So, you only need to follow the instructions at https://wiki.eclipse.org/Papyrus-RT/User_Guide/Compiling_and_running_Papyrus_for_Real_Time_applications#Building_your_applications_on_Windows_with_Cygwin:
1) open a Cygwin terminal
2) navigate to the generated project
3) create a build folder if it doesn't already exist and move into it
4) type 'cmake ../src'
That's it. The call top cmake will automatically build the RTS and the generated application.
As for the exception in the linux version, that depends on your particular model. The exception reads:
Quote:Unexpected message to capsule instance Top.ponger role ponger on port pongPort protocol PingPongProtocol signal ping
This means precisely that the ponger capsule is in a state where it received a message 'ping' and there where no outgoing transitions from that state that had 'ping' in a trigger. So either you didn't create a transition from that state, or you created and didn't add a trigger or added a trigger and selected the wrong message to trigger the transition.
The exception is not linux-specific. You will get the same exception on Windows, because there the exception indicates a problem with the model, not the generated code.
|
|
| |
Re: Unable to add log port in the middle of the capsule [message #1794667 is a reply to message #1794454] |
Tue, 04 September 2018 16:53 |
Ernesto Posse Messages: 438 Registered: March 2011 |
Senior Member |
|
|
No, there is no language reference manual for Papyrus-RT. The language is UML-RT, which is essentially the same as ROOM for which there is a prominent reference book. UML-RT is essentially a UML 2.0 profile of ROOM, which inherits a lot of the semantics of UML 2.0 in relation to composite structure diagrams and state machines, but is not exactly the same and includes concepts different from UML 2.0, such as optional and plug-in capsule parts, service ports, port binding detection, and simplified state machines (no OR-states, no shallow history, only deep history). Nevertheless, in spite of these difference, the official OMG UML 2.x spec can be used as a reference.
|
|
|
Goto Forum:
Current Time: Sun Oct 13 04:20:49 GMT 2024
Powered by FUDForum. Page generated in 0.04462 seconds
|