{"id":103583,"date":"2023-11-23T11:12:24","date_gmt":"2023-11-23T03:12:24","guid":{"rendered":"https:\/\/www.tm-robot.com\/?post_type=docs&p=103583"},"modified":"2024-03-04T13:18:49","modified_gmt":"2024-03-04T05:18:49","slug":"run-a-customized-user-interface-for-running-projects-with-tmcraft-shell","status":"publish","type":"docs","link":"https:\/\/www.tm-robot.com.cn\/zh-hant\/docs\/run-a-customized-user-interface-for-running-projects-with-tmcraft-shell\/","title":{"rendered":"Run a Customized User Interface for Running Projects with TMcraft Shell"},"content":{"rendered":"
Examples are valid for<\/strong><\/p>\n TMflow Software version: 2.16.2400 or later<\/p>\n TM Robot Hardware version: HW3.2 \/ HW5.x<\/p>\n Other specific requirements: TMcraft Packer 1.12.1100 or later<\/p>\n Note that older or newer software versions may have different results.<\/p>\n <\/p>\n This is a tutorial for running a sample shell on your robot. There are the advantages of using shell:<\/p>\n Full-Screen Interface<\/span><\/strong><\/p>\n You can run your full-screen user interface(shell) on robot controller now! Operate and monitor the process in the way you want for all-time operation.<\/p>\n <\/p>\n Simplify the Operation<\/span><\/strong><\/p>\n For some standardized applications such as parts loading\/unloading, dispensing, you can develope and deploy shell on the robots to simplify the operation.<\/p>\n <\/p>\n Leverage the Power of TMflow<\/span><\/strong><\/p>\n TMflow is always runing in the background, switch back to TMflow for advanced operation at anytime!<\/p>\n <\/p>\n <\/p>\n <\/p>\n Your shell could interact with TMflow through TMcraft API, such as changing TMflow projects, read variables, run project, etc.<\/p>\n This is a glance of developing a shell:<\/p>\n <\/p>\n <\/p>\n Execute Microsoft Visual Studio 2022<\/strong><\/em>.<\/p>\n <\/p>\n Unzip and open [P6]RunProject<\/em><\/span><\/strong>\/Runproject.sln<\/strong><\/em>, then you should have the view below:<\/span><\/span><\/p>\n There are two main files: MainWindow.xaml<\/strong><\/em>(main user interface) and Window_Prompt.xaml<\/strong><\/em>(hint window when you click “?”).<\/p>\n You can modify it as you want or just leave them here.<\/p>\n <\/p>\n About the Resolution of Shell<\/strong><\/span><\/p>\n There are 2 configurations of resolution:<\/p>\n Due to this mechanism, please consider two resolutions with your shell. In this example, the resolution of view is programmed to 1280*800 and works on both resolutions.<\/p>\n <\/p>\n Navigate to Tab>Build>Rebuild Solution<\/strong><\/em>:<\/p>\n <\/p>\n When it is done, copy [P5]<\/strong> \\TMcraft files<\/strong><\/em> and REPLACE them to the folder(…\\RunProject\\bin\\Debug\\net6.0-windows<\/span><\/span>) of built target:<\/span><\/span><\/p>\n Run [P4]<\/strong> TMcraft Packer<\/strong><\/em>, select SHELL<\/span> and enter any project name<\/span>, then CREATE<\/span>. This is the configuration of building Shell.<\/span><\/span><\/p>\n <\/p>\n Follow instructions below to finish the settings, then click GENERATE<\/strong> and OK<\/span> <\/strong>when it is done. Make sure there is Everything is Ok<\/span> on the screen:<\/span><\/span><\/p>\n <\/p>\n The<\/span> packed file is in the folder(for example, C:\\Techman Robot\\TMcraft Packer\\USB\\TM_Export\\A11090031NB\\TMcraft\\Shell<\/strong><\/em>, target folder<\/span> in [Step4]<\/strong><\/span>). Copy the TM_Export<\/span> (the packed file is in this folder also)folder and replace it to the root folder in the USB stick[P9] USB stick with name of “TMROBOT”<\/strong>:<\/span><\/span><\/p>\n A11090031NB is the name of PC.<\/p>\n <\/p>\n The virtual robot\/simulator is a standard new feature when you install TMflow2.16 on your PC.<\/p>\n In [P2]<\/strong>TMflow<\/em><\/strong><\/span>, run it on your PC and select any virtual robot(TM5S-X for example):<\/p>\nGoal<\/strong><\/h2>\n
<\/a><\/p>\nWhat is Shell?<\/strong><\/h2>\n
\n
<\/a><\/p>\n
<\/a><\/p>\n
<\/a><\/p>\nPreparation<\/strong><\/h2>\n
\n
<\/a><\/strong><\/span><\/li>\n
<\/a><\/strong><\/span> (this file is the same result in [Step4])<\/li>\n
<\/a><\/strong><\/span><\/li>\n<\/ul>\nRelated Manual<\/strong><\/h2>\n
\n
Step-by-step Operations<\/h2>\n
[1] Run Microsoft Visual Studio 2022<\/strong><\/span><\/h3>\n
[2] Open sorurce code<\/span><\/strong><\/h3>\n
<\/a><\/p>\n
<\/a><\/p>\n\n
<\/a><\/p>\n[3] Build the files<\/strong><\/span><\/h3>\n
<\/a><\/p>\n
<\/a><\/p>\n[4] Pack the files to TMflow Shell format<\/strong><\/span><\/h3>\n
<\/a><\/p>\n
<\/a><\/p>\n
<\/a>
<\/a><\/p>\n[5] Put the Shell file in USB stick\u00a0<\/strong><\/span><\/h3>\n
<\/a><\/p>\n[6] Run TMflow2.16(simulator)<\/strong><\/span><\/h3>\n