JP7444407B2 - Program execution system, control device and control program - Google Patents
Program execution system, control device and control program Download PDFInfo
- Publication number
- JP7444407B2 JP7444407B2 JP2020214624A JP2020214624A JP7444407B2 JP 7444407 B2 JP7444407 B2 JP 7444407B2 JP 2020214624 A JP2020214624 A JP 2020214624A JP 2020214624 A JP2020214624 A JP 2020214624A JP 7444407 B2 JP7444407 B2 JP 7444407B2
- Authority
- JP
- Japan
- Prior art keywords
- controlled device
- execution
- program
- command
- control
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
- 238000004590 computer program Methods 0.000 claims description 30
- 238000004088 simulation Methods 0.000 claims description 20
- 238000004891 communication Methods 0.000 description 25
- 238000000034 method Methods 0.000 description 21
- 238000012545 processing Methods 0.000 description 12
- 238000010586 diagram Methods 0.000 description 10
- 230000000694 effects Effects 0.000 description 7
- 239000011159 matrix material Substances 0.000 description 4
- 239000004973 liquid crystal related substance Substances 0.000 description 3
- 238000012790 confirmation Methods 0.000 description 2
- 230000004397 blinking Effects 0.000 description 1
- 238000006243 chemical reaction Methods 0.000 description 1
- 238000001514 detection method Methods 0.000 description 1
- 230000010365 information processing Effects 0.000 description 1
- 238000005259 measurement Methods 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 239000007787 solid Substances 0.000 description 1
- 230000007704 transition Effects 0.000 description 1
- 230000001960 triggered effect Effects 0.000 description 1
Images
Landscapes
- Debugging And Monitoring (AREA)
Description
被制御装置と、被制御装置を制御するコンピュータプログラムの実行が可能な制御装置とを備えるプログラム実行システム、そのようなプログラム実行システムにて用いられる制御装置、及びそのような制御装置を実現する制御プログラムに関する。 A program execution system comprising a controlled device and a control device capable of executing a computer program that controls the controlled device, a control device used in such a program execution system, and a control that realizes such a control device. Regarding the program.
コンピュータプログラミング(以下、プログラミングという)の普及に伴い、プログラミングを学習するための様々な方法が提案されている。例えば、非特許文献1では、実行される命令を抽象化した画像を組み合わせる専用のプログラム言語にてプログラミングを行うシステムを公開している。
With the spread of computer programming (hereinafter referred to as programming), various methods for learning programming have been proposed. For example, Non-Patent
しかしながら、非特許文献1に記載されているようなシステムでは、入力したコンピュータプログラムの実行状況を十分に把握することができないという問題がある。
However, the system described in Non-Patent
本発明は斯かる事情に鑑みてなされたものであり、コンピュータプログラムの実行状況の把握が容易なプログラム実行システムの提供を目的とする。 The present invention has been made in view of the above circumstances, and an object of the present invention is to provide a program execution system in which the execution status of a computer program can be easily grasped.
また、本発明は、本発明に係るプログラム実行システムにて用いられる制御装置の提供を他の目的とする。 Another object of the present invention is to provide a control device used in the program execution system according to the present invention.
また、本発明は、本発明に係る制御装置を実現するための制御プログラムの提供を更に他の目的とする。 Another object of the present invention is to provide a control program for realizing the control device according to the present invention.
上記課題を解決するために本願記載のプログラム実行システムは、被制御装置と、前記被制御装置を制御するコンピュータプログラムの実行が可能な制御装置とを備えるプログラム実行システムであって、前記制御装置は、画像を表示可能な表示部と、コンピュータプログラムを実行して前記被制御装置を制御する実行命令を、前記被制御装置へ送信する命令実行手段と、前記被制御装置を制御する実行命令を模擬実行して、前記被制御装置の状態を前記表示部に表示させる模擬実行手段と、実行しているコンピュータプログラムを前記表示部に表示させる実行表示手段とを備え、前記被制御装置は、前記制御装置から受信した実行命令を実行する手段を備えることを特徴とする。 In order to solve the above problems, a program execution system described in the present application is a program execution system including a controlled device and a control device capable of executing a computer program for controlling the controlled device, the control device being , a display unit capable of displaying an image; a command execution means for transmitting an execution command for controlling the controlled device by executing a computer program to the controlled device; and a simulation of the execution command for controlling the controlled device. The controlled device includes a simulation execution means for displaying the state of the controlled device on the display unit, and an execution display unit for displaying the computer program being executed on the display unit. The apparatus is characterized by comprising means for executing an execution command received from the apparatus.
また、前記プログラム実行システムにおいて、前記制御装置は、コンピュータプログラムの入力を受け付ける手段を備えることを特徴とする。 Further, in the program execution system, the control device includes means for receiving input of a computer program.
また、前記プログラム実行システムにおいて、前記制御装置が実行するコンピュータプログラムは、複数の命令を順次実行するインタプリタ型言語で示されており、前記制御装置は、コンピュータプログラムを、順次実行する命令単位で、前記被制御装置が実行可能な実行命令に変換する手段を備え、前記命令実行手段は、変換した実行命令を順次送信するようにしてあり、前記模擬実行手段は、前記命令実行手段が実行命令を送信する毎に、模擬実行することを特徴とするプログラム実行システム。 Further, in the program execution system, the computer program executed by the control device is expressed in an interpreted language that sequentially executes a plurality of instructions, and the control device executes the computer program in units of instructions that execute sequentially. The controlled device includes means for converting the executed commands into executable instructions, the command executing means sequentially transmits the converted execution commands, and the simulated execution means converts the executed commands into executable commands that can be executed by the command executing means. A program execution system characterized by performing mock execution every time it is sent.
また、前記プログラム実行システムにおいて、前記被制御装置は、自機の仕様を示す装置情報を前記制御装置へ送信する手段を備え、前記制御装置が備える模擬実行手段は、受信した装置情報に基づいて、実行命令を模擬実行することを特徴とする。 Further, in the program execution system, the controlled device includes means for transmitting device information indicating the specifications of the controlled device to the control device, and the simulation execution device included in the control device executes a simulation based on the received device information. , is characterized in that it executes an execution command in a simulated manner.
更に、本願記載の制御装置は、被制御装置を制御するコンピュータプログラムの実行が可能な制御装置であって、表示部に画像を表示させる手段と、コンピュータプログラムを実行して前記被制御装置を制御する実行命令を、前記被制御装置へ送信する手段と、前記被制御装置を制御する実行命令を模擬実行して、前記被制御装置の状態を前記表示部に表示させる手段と、実行しているコンピュータプログラムを前記表示部に表示させる手段とを備えることを特徴とする。 Further, the control device described in the present application is a control device capable of executing a computer program for controlling a controlled device, and includes means for displaying an image on a display unit, and a means for displaying an image on a display unit, and a means for executing a computer program to control the controlled device. means for transmitting, to the controlled device, an execution command to control the controlled device; and means for displaying the state of the controlled device on the display unit by mock-executing the execution command to control the controlled device; and means for displaying a computer program on the display section.
更に、本願記載の制御プログラムは、被制御装置を制御するコンピュータプログラムの実行が可能で、表示部に画像を表示させることが可能なコンピュータにて実行される制御プログラムであって、コンピュータに、コンピュータプログラムを実行して前記被制御装置を制御する実行命令を、前記被制御装置へ送信するステップと、前記被制御装置を制御する実行命令を模擬実行して、前記被制御装置の状態を前記表示部に表示させるステップと、実行しているコンピュータプログラムを前記表示部に表示させるステップとを実行させることを特徴とする。 Furthermore, the control program described in the present application is a control program executed on a computer capable of executing a computer program for controlling a controlled device and displaying an image on a display unit, Sending an execution command for controlling the controlled device by executing a program to the controlled device; and displaying the state of the controlled device by executing the execution command for controlling the controlled device in a simulated manner. and displaying a computer program being executed on the display unit.
本発明に係るプログラム実行システム、制御装置及び制御プログラムは、コンピュータプログラムに基づいて、被制御装置に実行命令を送信し、実行命令を模擬実行して被制御装置の状態を表示させ、実行しているコンピュータプログラムを表示させる。これにより、コンピュータプログラムの確認が容易である等、優れた効果を奏する。 A program execution system, a control device, and a control program according to the present invention transmit an execution command to a controlled device based on a computer program, simulate execute the execution command to display the state of the controlled device, and execute the command. display the computer program that is running. This provides excellent effects such as easy confirmation of computer programs.
以下、本発明の実施形態について詳述する。なお、以下の実施形態は、本発明を具現化した一例であって、本発明の技術範囲を限定する性格のものではない。 Embodiments of the present invention will be described in detail below. Note that the following embodiment is an example of embodying the present invention, and is not intended to limit the technical scope of the present invention.
<適用例>
本願記載のプログラム実行システムは、例えば、コンピュータプログラミング(以下、プログラミングという)の学習として使用可能なシステムである。プログラム実行システムでは、コンピュータプログラムを実行する制御装置及び制御装置にて制御される被制御装置を用いる。以下では、図を用いて、制御装置1及び被制御装置2を備えるプログラム実行システムの例について説明する。
<Application example>
The program execution system described in the present application is a system that can be used for learning computer programming (hereinafter referred to as programming), for example. A program execution system uses a control device that executes a computer program and a controlled device that is controlled by the control device. In the following, an example of a program execution system including a
<システム構成例>
図1は、本願記載のプログラム実行システムの構成例を概念的に示す説明図である。制御装置1は、タブレット型コンピュータ、高機能携帯電話(所謂、スマートフォン)、ノート型コンピュータ、デスクトップ型コンピュータ等のコンピュータを用いて構成される。ここでは、制御装置1として、タブレット型コンピュータを用いた例について説明する。被制御装置2は、コンピュータプログラムを実行する制御装置1にて制御される装置である。被制御装置2は、制御装置1にて認識可能な所定の規格に準拠していれば様々な装置を用いることが可能である。ここでは、LED(Light Emitting Diode)等の発光素子を8×8のマトリクス状に配置したLEDボードを、マイコンボードに取り付けた被制御装置2を用いる例について説明する。なお、被制御装置2としては、LEDボードに限らず、8セグメントのLED、命令に基づく画像を表示する装置、命令に基づく音声を出力する装置、命令に基づく動作を行う玩具用又は産業用ロボット等の様々な装置を被制御装置2として用いることが可能である。制御装置1及び被制御装置2は、有線又は無線の通信方法で通信することが可能である。有線通信としては、例えば、USB(Universal Serial Bus)、IEEE(Institute of Electrical and Electronics Engineers)1394等の様々な規格に準拠した通信方法を用いることが可能である。無線通信としては、IEEE802.11(所謂、Wi-Fi)等の様々な規格に準拠した通信方法を用いることが可能である。
<System configuration example>
FIG. 1 is an explanatory diagram conceptually showing a configuration example of a program execution system described in the present application. The
<各種装置のハードウェア構成>
次に、本願記載のプログラム実行システムにて用いられる各種装置のハードウェア構成の例について説明する。図2は、本願記載のプログラム実行システムにて用いられる各種装置の構成例を示す概略ブロック図である。
<Hardware configuration of various devices>
Next, examples of hardware configurations of various devices used in the program execution system described in the present application will be described. FIG. 2 is a schematic block diagram showing configuration examples of various devices used in the program execution system described in the present application.
制御装置1は、制御部10、記録部11、表示部12、入力部13、通信部14等の各種構成を備えている。
The
制御部10は、装置全体を制御する処理を実行するCPU(Central Processing Unit )等のプロセッサであり、情報処理回路、計時回路、レジスタ回路等の各種回路を備えている。
The
記録部11は、ハードディスクドライブ、ソリッドステートドライブ、フラッシュメモリ等の不揮発性メモリ、及び各種RAM(Random Access Memory)等の揮発性メモリを用いて構成される回路である。記録部11には、基本プログラム(OS:Operating System)、基本プログラム上で動作する応用プログラム(アプリケーションプログラム)等のプログラムが記録されている。応用プログラムとしては、本願記載の制御装置1を実現するための制御プログラム110、被制御装置2を制御するために入力されたコンピュータプログラム(以下、入力プログラム110dという)等の各種プログラムが記録される。
The
制御装置1の記録部11に記録された制御プログラム110は、アプリケーションモジュール110a、シミュレーションモジュール110b、エディタモジュール110c等の各種モジュールを含んでいる。アプリケーションモジュール110aは、入力プログラム110dを実行し、被制御装置2を制御する実行命令を送信するモジュールである。シミュレーションモジュール110bは、実行命令を模擬実行(シミュレート)し、被制御装置2の状態を表示させるモジュールである。エディタモジュール110cは、入力プログラム110dの入力、編集等の処理を受け付けるモジュールである。
The
制御装置1の記録部11に記録された入力プログラム110dは、被制御装置2を制御するためのプログラムであり、複数の命令を順次実行するインタプリタ型言語にて示されている。入力プログラム110dは、ソースコードとして入力を受け付け、被制御装置2にて実行可能な形式に、命令単位で適宜変換される。本願でいう命令単位とは、被制御装置2を制御するために順次送信される命令の単位である。例えば、命令単位は、「所定のLEDを点灯」等の1つのステップを規定した命令でもよく、また、「所定のLEDを点灯」し、「1000ミリ秒停止」等の実質的に一つの処理として実行される複数の連続した命令群であってもよい。
The
表示部12は、画像を表示する液晶ディスプレイ等のデバイスである。入力部13は、使用者(プログラマ)の操作入力を受け付けるタッチパネル等のデバイスである。ここでは、表示部12及び入力部13として、薄板状をなすタッチパネル及び液晶ディスプレイを積層して一体化した液晶タッチパネルを用いた例について説明する。なお、入力部13としては、制御装置1に接続されるキーボード、マウス等のデバイスを用いてもよく、更には、記録媒体又は他の装置に記録されている入力プログラム110dを読み取る各種ポートを用いてもよい。
The
通信部14は、有線又は無線にて被制御装置2と通信するUSBポート、アンテナ等のハードウェア及び制御回路を用いたデバイスである。
The communication unit 14 is a device that uses hardware such as a USB port and an antenna and a control circuit to communicate with the controlled
以上のように構成されたタブレット型コンピュータ等のコンピュータは、記録部11に記録されている制御プログラム110に含まれる各種ステップを、制御部10の制御にて実行することにより、制御装置1として動作する。
A computer such as a tablet computer configured as described above operates as the
被制御装置2は、制御部20、出力部21、通信部22等の各種構成を備えている。
The controlled
制御部20は、装置全体を制御するマイコンボード等のマイクロコンピュータ、その他各種制御回路を用いて構成される。制御部20は、制御装置1から送信される実行命令を受信し、受信した実行命令を実行することにより、出力部21を制御する。
The
出力部21は、LED等の発光素子を8×8のマトリクス状に配置したLEDボードである。
The
通信部22は、有線又は無線にて制御装置1と通信する回路であり、例えば、制御部20であるマイコンボードに付属の回路を用いて構成される。
The
本願では、マイコンボードにLEDボードを組み合わせた被制御装置2を例示して説明するが、前述のように、被制御装置2としては、他の配置のLED、画像を表示する装置、音声を出力する装置、ロボット等の各種装置を被制御装置2として用いることが可能である。例えば、画像を表示する装置を被制御装置2として用いる場合、モニタが出力部21となる。音声を出力する装置を被制御装置2として用いる場合、スピーカが出力部21となる。ロボットを被制御装置2として用いる場合、モータ、モニタ、スピーカ等の出力デバイスだけでなく、センサ、カメラ、マイク等の入力デバイスを出力部21としてもよい。
In this application, a controlled
<各種装置のソフトウェア処理>
次に、本願記載のプログラム実行システムにて用いられる各種装置の処理について説明する。図3は、本願記載のプログラム実行システムが備える制御装置1及び被制御装置2の処理の一例を示すフローチャートである。制御装置1は、制御プログラム110を実行する制御部10の制御により、各種処理を実行する。制御装置1は、制御プログラム110を実行することにより、アプリケーションモジュール110a、シミュレーションモジュール110b、エディタモジュール110c等の各種モジュールが起動し、制御部10の制御により、制御プログラム110に含まれる各種モジュールが実行される。
<Software processing of various devices>
Next, processing of various devices used in the program execution system described in the present application will be explained. FIG. 3 is a flowchart showing an example of the processing of the
制御装置1及び被制御装置2の間の通信が確立することにより、以降の処理が開始される。制御装置1及び被制御装置2の間の通信は、例えば、制御装置1及び被制御装置2の間を、所定の通信規格に準拠した通信線で接続したことをトリガとし、通信に関するペアリング等の処理を実行することで確立される。制御装置1との通信が確立した被制御装置2の制御部20は、通信部22から装置に関する仕様、その他被制御装置2の制御に必要な事項を示す装置情報を、制御装置1へ送信する(ステップS1)。
The subsequent processing is started by establishing communication between the
制御装置1の制御部10は、被制御装置2から送信された装置情報を通信部14にて受信し、アプリケーションモジュール110aの実行により、装置情報を認識し、更に、装置情報をシミュレーションモジュール110bに渡す(ステップS2)。
The
シミュレーションモジュール110bの実行により、制御部10は、装置情報に基づいて、被制御装置2の状態を模擬表示するシミュレータを表示部12に表示させる(ステップS3)。ステップS3にて表示されるシミュレータとは、被制御装置2の状態を模擬表示する画像であり、例えば、8×8のマトリクス状に配列されたLEDの画像が表示部12に表示される。
By executing the
使用者は、表示部12に表示された画像を確認し、制御装置1を操作して入力プログラム110dを入力する。
The user checks the image displayed on the
図4は、本願記載の制御装置1が備える表示部12から表示される画像の一例を示す説明図である。図4は、入力プログラム110dを入力している状態を示している。図4に例示する入力プログラム110dは、学習用に構成された専用のプログラム言語にて記述されている。図4に例示するプログラム言語では、実行する命令を抽象化した画像ブロックを組み合わせて入力プログラム110dを構成する。入力プログラム110dの入力は、新たな入力プログラム110dの入力、記録部11に記録されている入力プログラム110dの読込、読み込んだ入力プログラム110dの編集等の方法にて行われる。更に、入力プログラム110dの入力は、USBメモリ等の記録媒体、通信部14にて接続される他の装置等の外部に記録されている入力プログラム110dの読取、読み取った入力プログラム110dの編集等の方法であってもよい。また、入力プログラム110dは、文字、数字、符号等のテキストデータにて構成されるプログラム言語にて記述されていてもよい。
FIG. 4 is an explanatory diagram showing an example of an image displayed from the
図4に例示する入力プログラム110dは、被制御装置2の出力部21であるLEDボードを構成する発行素子のうち「○」の表示に用いられる12個の発光素子を点灯し、1000ミリ秒停止し、「×」の表示に用いられる8個の発光素子を点灯し、1000ミリ秒停止し、発光素子を消灯する処理を10回繰り返す処理を記述している。本願記載のプログラム実行システムにおいて、入力プログラム110dは、発光素子の表示等の命令の直後に、「XXXXミリ秒停止」等の待機命令を追加することにより、全体の実行速度を調整して入力プログラム110dの実行状況を確認しやすくすることが可能である。
The
図3のフローチャートに戻り、エディタモジュール110cの実行により、制御部10は、入力部13から入力プログラム110dの入力を受け付ける(ステップS4)。使用者は、入力プログラム110dの入力を終了後、入力プログラム110dの入力が終了したことを示す所定の操作を行う。
Returning to the flowchart of FIG. 3, by executing the
入力プログラム110dの入力が終了後、アプリケーションモジュール110aの実行により、制御部10は、入力された入力プログラム110dを要求し、エディタモジュール110cから入力プログラム110dを受け取る(ステップS5)。ステップS5にて受け取る入力プログラム110dは、画像ブロック形式で入力されたソースコードである。
After inputting the
アプリケーションモジュール110aの実行により、制御部10は、入力プログラム110dのソースコードの形式を変換する(ステップS6)。ステップS6では、画像ブロック形式のソースコードを、アプリケーションモジュール110aにて実行可能なテキスト形式のソースコードに変換する。ソースコードに変換された入力プログラム110dは、複数の命令を順次実行するインタプリタ型言語にて示される。ステップS6のソースコードの形式変換処理は、アプリケーションモジュール110aの処理として実行してもよく、また、エディタモジュール110cの処理として実行してもよい。
By executing the
アプリケーションモジュール110aの実行により、制御部10は、変換後のソースコードにて記述された入力プログラム110dの命令を読み込む(ステップS7)。ステップS7では、複数の命令にて構成される入力プログラム110dのうち、最初に実行する命令単位を読み込む。前述のように、命令単位とは、被制御装置2を制御するために逐次送信される命令の単位である。例えば、図4に例示した入力プログラム110dであれば、「『○』の表示に用いられる12個の発光素子を点灯」させる一つの命令を命令単位としてもよく、「『○』の表示に用いられる12個の発光素子を点灯」し、「1000ミリ秒停止」する2つの命令の組み合わせを命令単位としてもよい。
By executing the
アプリケーションモジュール110aの実行により、制御部10は、命令単位で読み込んだ命令をエディタモジュール110cに渡す(ステップS8)。
By executing the
エディタモジュール110cの実行により、制御部10は、表示部12に表示されている入力された入力プログラム110dのうち、受け取った命令にて実行される箇所の命令の表示を変更する(ステップS9)。ステップS9の表示の変更とは、例えば、対応する命令を示す画像ブロックの表示色の変更、点滅等の処理である。
By executing the
ステップS8にて、命令を渡した後、アプリケーションモジュール110aを実行する制御部10は、ステップS7にて読み込んだ命令を、被制御装置2にて実行することが可能な実行命令に変換する(ステップS10)。
After passing the command in step S8, the
アプリケーションモジュール110aの実行により、制御部10は、ステップS10にて変換した実行命令を通信部14から被制御装置2へ送信する(ステップS11)。
By executing the
通信部22にて実行命令を受信した被制御装置2の制御部20は、受信した制御命令を出力部21で実行する(ステップS12)。例えば、「『○』の表示に用いられる12個の発光素子を点灯」させるという実行命令を受信した場合、被制御装置2は、ステップS12として、出力部21である8×8のLEDボードが備える発光素子のうち命令された12個の発光素子を点灯させる。また、実行命令として2つの命令の組み合わせである「『○』の表示に用いられる12個の発光素子を点灯」及び「1000ミリ秒停止」という実行命令を受信した場合、被制御装置2は、ステップS12の処理として、12個の発光素子を点灯した状態で1000ミリ秒待機する。
The
ステップS11にて、実行命令を送信した後、アプリケーションモジュール110aを実行する制御部10は、ステップS10にて変換した実行命令をシミュレーションモジュール110bに渡す(ステップS13)。
After transmitting the execution command in step S11, the
シミュレーションモジュール110bの実行により、制御部10は、受け取った実行命令を模擬実行し、ステップS3で表示部12に表示しているシミュレータ上に、被制御装置2の状態を模擬表示する(ステップS14)。ステップS14では、例えば、表示部12に模擬表示した8×8のマトリクス状に配列されたLEDの画像のうち、「○」の表示に用いられる12個の発光素子に対応する画像を、発光を示す画像に変更する。
By executing the
図5は、本願記載の制御装置1が備える表示部12から表示される画像の一例を示す説明図である。図5は、ステップS9の表示変更及びステップS14の模擬表示をした段階で表示部12に表示される画像の一例を示している。図5に例示する画像では、図5に向かって左側に、エディタモジュール110cがステップS9にて表示変更した画像が表示されており、右側にシミュレーションモジュール110bがステップS14にて模擬表示した被制御装置2の状態を示す画像が表示されている。
FIG. 5 is an explanatory diagram showing an example of an image displayed from the
エディタモジュール110cによる左側の画像は、順次実行される複数の命令のうち、「○」の表示に用いられる12個の発光素子を点灯させる命令を示す画像ブロックの表示色が変更されている。エディタモジュール110cにて表示される画像から、被制御装置2にて現在実行されている命令が12個の発光素子を点灯させる命令であることが確認できる。なお、実際には、発光素子を点灯させる命令を実行後、すぐに1000ミリ秒停止の命令に遷移するが、例えば、点灯命令及び待機命令を命令単位として実行させる場合には、1000ミリ秒停止中の状態であっても、点灯命令が実行されているとして表示変更してもよい。また、点灯命令及び待機命令をそれぞれ別の命令単位として実行させる場合であっても、待機命令を実行中は、直前の点灯命令が実行されているとして表示変更してもよい。
In the left image created by the
シミュレーションモジュール110bによる右側の画像は、被制御装置2の出力部21の状態として、模擬表示した8×8の発光素子のうち「○」の表示に用いられる12個の発光素子が点灯している画像を表示している。
The image on the right side produced by the
図6は、本願記載のプログラム実行システムにて用いられる被制御装置2が備える出力部21の状態を示す概略説明図である。図6は、ステップS12にて制御命令を実行した状態の出力部21を示している。図6では、出力部21である8×8のLEDボードが備える発光素子のうち命令された12個の発光素子が点灯している状態を示している。
FIG. 6 is a schematic explanatory diagram showing the state of the
図5に例示した制御装置1の表示部12に表示される画像及び図6に例示した被制御装置2の出力部21を比較することにより、本願記載のプログラム実行システムでは、入力プログラム110dのうちの実行中の命令の確認、被制御装置2がどのように制御されているかという実機での確認及びシミュレータでの確認をリアルタイムで行うことができる。リアルタイムで比較しながら確認することにより、入力プログラム110dの実行状況の把握が容易であり、プログラミングの学習効果を高めることが可能となる。
By comparing the image displayed on the
図3のフローチャートに戻り、ステップS13にて実行命令を渡した後、アプリケーションモジュール110aを実行する制御部10は、次に実行すべき命令の有無を判定する(ステップS15)。
Returning to the flowchart of FIG. 3, after passing the execution command in step S13, the
ステップS15において、次に実行すべき命令があると判定した場合(ステップS15:YES)、アプリケーションモジュール110aを実行する制御部10は、ステップS7へ戻り、複数の命令にて構成される入力プログラム110dのうち、次に実行する命令を読み込み(ステップS7)、以降の処理を繰り返す。
If it is determined in step S15 that there is an instruction to be executed next (step S15: YES), the
ステップS7~S15の処理を繰り返し実行することにより、アプリケーションモジュール110aを実行する制御部10は、ソースコードから変換された実行命令を被制御装置2へ順次送信する。また、シミュレーションモジュール110bを実行する制御部10は、実行命令を送信する毎に、被制御装置2の状態を表示部12に模擬表示する。更に、エディタモジュール110cを実行する制御部10は、実行中の命令を変更表示する。従って、本願記載のプログラム実行システムは、複数の命令を順次実行するインタプリタ型言語で記述される入力プログラム110dを、実行中の命令を確認しながら状況を把握することが可能である。
By repeatedly executing the processes of steps S7 to S15, the
ステップS15において、次に実行すべき命令がないと判定した場合(ステップS15:NO)、アプリケーションモジュール110aを実行する制御部10は、処理を終了する。
If it is determined in step S15 that there is no next instruction to be executed (step S15: NO), the
被制御装置2が、センサ、カメラ、マイク等の入力デバイスを伴う出力部21を備える場合は、出力部21に情報を取得する実行命令を送信し、命令実行に伴い取得した情報の取得及びシミュレーションモジュール110bへの反映が必要なときがある。例えば、被制御装置2がカメラ及びモニタを含む出力部21を備えている場合に、被制御装置2に、カメラの撮影による画像情報の取得及び取得した画像情報に基づくモニタへの画像表示という命令単位の実行命令を実行させる場合である。このような場合、制御装置1のシミュレータに撮影を行ったことだけでなく、取得した画像情報を表示させる必要が生じる。次に、情報取得を伴う実行命令を実行する場合の例について説明する。
When the controlled
図7は、本願記載のプログラム実行システムが備える制御装置1及び被制御装置2の処理の一例を示すフローチャートである。図7は、図3のフローチャートにおいて、ステップS10にて変換した実行命令が、情報取得及び取得した情報の使用を含む命令単位の命令であると判定した場合の処理を例示している。
FIG. 7 is a flowchart showing an example of the processing of the
ステップS11にて通信部22にて実行命令を受信した被制御装置2の制御部20は、受信した実行命令を出力部21で実行し(ステップS12)、実行した実行命令に伴い情報を取得する(ステップS16)。ステップS12にて実行する命令が情報取得及び取得情報の使用を含む命令である場合、ステップS16にて情報を取得する処理を実行する。ステップS16では、例えば、センサによる検出対象の情報の取得、カメラの撮影よる画像情報の取得、マイクによる音声情報の取得等の処理が実行される。
The
被制御装置2の制御部20は、ステップS16にて取得した取得情報を通信部22から制御装置1へ送信する(ステップS17)。
The
アプリケーションモジュール110aの実行により、通信部14にて取得情報を受信した制御装置1の制御部10は、必要に応じて、受信した取得情報を、ステップS10で変換した実行命令に付加する(ステップS18)。例えば、カメラの撮影にて画像情報を取得し、取得した画像情報をモニタに表示するという実行命令に、取得情報としての画像情報を付加する。
The
そして、制御装置1の制御部10は、アプリケーションモジュール110aが取得情報を付加した実行命令をシミュレーションモジュール110bに渡し、シミュレーションモジュール110bが受け取った実行命令を模擬実行し、シミュレータ上に、被制御装置2の状態を模擬表示するという図3を用いて説明したステップS13以降の処理を実行する。
Then, the
このように、実行命令が命令取得を伴う命令単位の命令である場合、被制御装置2が取得した取得情報を制御装置1へ送信することにより、シミュレーションモジュール110bに反映させることが可能となる。例えば、被制御装置2に取得した画像を表示させると共に、シミュレータにも同様の画像を表示させるという処理を実現することができる。なお、実行命令が情報取得のみの命令であり、取得した情報をすぐに使用することがない場合、アプリケーションモジュール110aは、ステップS17にて取得情報を受信した後、取得情報を記録部11に記録し、実行命令への付加は行わずに以降の処理を行うことになる。
In this way, when the execution command is an instruction-based command that involves command acquisition, by transmitting the acquisition information acquired by the controlled
以上詳述した如く、本願記載のプログラム実行システムは、順次実行される複数の命令を含む入力プログラム110dを実行し、入力プログラム110dのうちの実行中の命令の確認、被制御装置2実機での確認及びシミュレータでの模擬表示の確認をリアルタイムで行うことができる。リアルタイムで比較しながら確認することにより、入力プログラム110dの実行状況の把握が容易であり、プログラミングの学習効果を高めることが可能となる等、優れた効果を奏する。しかも、これらの確認は、順次実行される命令単位で行うことが可能であるので、プログラミングの学習効果を高めることができる。しかも、本願記載のプログラム実行システムは、プログラミングの学習に限らず、入力プログラム110dのデバッグ、入力プログラム110dの実行内容の確認等、プログラミングに関する様々な確認に適用することが可能である等、優れた効果を奏する。
As described in detail above, the program execution system described in the present application executes the
また、本願記載のプログラム実行システムでは、入力プログラム110dに対し、発光素子の表示等の命令の直後に、待機命令を追加することにより、全体の実行速度を調整して、更に様々な確認を容易にすることが可能である等、優れた効果を奏する。更に、本願記載のプログラム実行システムは、インタプリタ型言語の入力プログラム110dを扱うので、入力プログラム110dの実行中に、一時停止、再開等の割込処理が可能であり、様々な確認を容易にすることが可能である等、優れた効果を奏する。
Furthermore, in the program execution system described in the present application, by adding a standby command to the
本発明は、以上説明した実施形態に限定されるものではなく、他のいろいろな形態で実施することが可能である。そのため、かかる実施形態はあらゆる点で単なる例示にすぎず、限定的に解釈してはならない。本発明の範囲は請求の範囲によって示すものであって、明細書本文には、なんら拘束されない。更に、請求の範囲の均等範囲に属する変形や変更は、全て本発明の範囲内のものである。 The present invention is not limited to the embodiments described above, and can be implemented in various other forms. Therefore, such embodiments are merely illustrative in all respects, and should not be interpreted in a limiting manner. The scope of the present invention is indicated by the claims, and is not restricted in any way by the main text of the specification. Furthermore, all modifications and changes that come within the scope of equivalents of the claims are intended to be within the scope of the present invention.
例えば、前記実施形態では、実行する命令を抽象化した画像ブロックを組み合わせたインタプリタ型言語の入力プログラム110dに適用する形態を例示したが、本発明はこれに限るものではなく、様々な入力プログラム110dに適用することが可能である。例えば、テキスト形式で記述された入力プログラム110dに適用する形態、更には、コンパイラ型の言語で記述された入力プログラム110dを受け付け、インタプリタ型言語のソースコードで記述されたソースコードに変換する形態等、様々な形態に展開することが可能である。
For example, in the embodiment described above, the application is applied to the
また、前記実施形態では、制御装置1及び被制御装置2が別体として構成された形態を示したが、本発明はこれに限らず、制御装置1及び被制御装置2が一体化した形態等、様々な形態に展開することが可能である。更には、制御装置1を複数台のコンピュータにて構成し、アプリケーションモジュール110aと、シミュレーションモジュール110b及びエディタモジュール110cとをそれぞれ異なるコンピュータにて実行する等、様々な形態に展開することが可能である。
Further, in the embodiment, the
1 制御装置
10 制御部
11 記録部
110 制御プログラム
110a アプリケーションモジュール
110b シミュレーションモジュール
110c エディタモジュール
110d 入力プログラム(コンピュータプログラム)
12 表示部
13 入力部
14 通信部
2 被制御装置
20 制御部
21 出力部
22 通信部
1
12
Claims (5)
前記制御装置は、
画像を表示可能な表示部と、
前記コンピュータプログラムを実行して前記被制御装置を制御するために逐次送信される命令の単位で、1以上の命令の組み合わせである実行命令を、前記被制御装置へ送信する命令実行手段と、
前記被制御装置を制御する実行命令を模擬実行して、前記被制御装置の状態を前記表示部に表示させる模擬実行手段と、
前記コンピュータプログラムを実行して前記被制御装置を制御する実行命令を、前記発光素子の点灯または消灯を表現した画像ブロックとして前記表示部に表示させる実行表示手段と
を備え、
前記被制御装置は、
前記制御装置から受信した実行命令を実行する手段を備える
ことを特徴とするプログラム実行システム。 A program execution system comprising a controlled device including a display board on which a plurality of light emitting elements are arranged , and a control device capable of executing a computer program for controlling the controlled device,
The control device includes:
a display section that can display images;
an instruction execution means for transmitting an execution command, which is a combination of one or more instructions, to the controlled device, which is a unit of instructions sequentially transmitted in order to execute the computer program and control the controlled device;
simulating execution means for simulating execution of an execution command for controlling the controlled device and displaying the state of the controlled device on the display unit;
Execution display means for displaying an execution command for controlling the controlled device by executing the computer program on the display unit as an image block representing lighting or extinguishing of the light emitting element ;
The controlled device is
A program execution system comprising: means for executing an execution command received from the control device.
前記実行表示手段は、
前記被制御装置にて実行されている実行命令に該当する前記画像ブロックの表示色を変更して表示する
ことを特徴とするプログラム実行システム。 The program execution system according to claim 1,
The execution display means includes:
changing the display color of the image block corresponding to the execution command being executed by the controlled device and displaying it;
A program execution system characterized by:
前記被制御装置は、画像情報を取得するカメラと前記画像情報を表示するモニタとを備え、
前記制御装置は、
前記実行命令が画像情報取得および取得した画像情報の使用を含む命令単位の命令である場合に、前記カメラに画像情報を取得させると共に、前記取得した画像情報を前記実行命令に付加し、
前記模擬実行手段は、前記実行命令を模擬実行して、前記画像情報を前記表示部に表示させると共に、前記被制御装置の状態を前記表示部に表示させ、
前記被制御装置は、前記制御装置から受信した実行命令を実行すると共に、前記モニタに前記画像情報を表示させる
ことを特徴とするプログラム実行システム。 The program execution system according to claim 1,
The controlled device includes a camera that acquires image information and a monitor that displays the image information,
The control device includes:
When the execution command is a command-based command that includes acquiring image information and using the acquired image information, causing the camera to acquire image information and adding the acquired image information to the execution command;
The simulation execution means simulates execution of the execution command, displays the image information on the display unit, and displays the state of the controlled device on the display unit,
The controlled device executes the execution command received from the control device and causes the monitor to display the image information.
A program execution system characterized by:
表示部に画像を表示させる手段と、
前記コンピュータプログラムを実行して前記被制御装置を制御するために逐次送信される命令の単位で、1以上の命令の組み合わせである実行命令を、前記被制御装置へ送信する手段と、
前記被制御装置を制御する実行命令を模擬実行して、前記被制御装置の状態を前記表示部に表示させる手段と、
前記コンピュータプログラムを実行して前記被制御装置を制御する実行命令を、前記発光素子の点灯または消灯を表現した画像ブロックとして前記表示部に表示させる手段と
を備えることを特徴とする制御装置。 A control device capable of executing a computer program for controlling a controlled device including a display board on which a plurality of light emitting elements are arranged ,
means for displaying an image on a display unit;
means for transmitting an execution command, which is a combination of one or more commands, to the controlled device, which is a unit of commands that are sequentially transmitted in order to execute the computer program and control the controlled device;
means for displaying the state of the controlled device on the display unit by performing a simulated execution of an execution command for controlling the controlled device;
A control device comprising: means for displaying an execution command for controlling the controlled device by executing the computer program on the display unit as an image block representing turning on or turning off the light emitting element .
コンピュータに、
前記コンピュータプログラムを実行して前記被制御装置を制御するために逐次送信される命令の単位で、1以上の命令の組み合わせである実行命令を、前記被制御装置へ送信するステップと、
前記被制御装置を制御する実行命令を模擬実行して、前記被制御装置の状態を前記表示部に表示させるステップと、
前記コンピュータプログラムを実行して前記被制御装置を制御する実行命令を、前記発光素子の点灯または消灯を表現した画像ブロックとして前記表示部に表示させるステップと
を実行させることを特徴とする制御プログラム。
A control program executed by a computer capable of executing a computer program for controlling a controlled device equipped with a display board on which a plurality of light emitting elements are arranged, and capable of displaying an image on a display unit,
to the computer,
transmitting an execution command, which is a combination of one or more commands, to the controlled device in units of commands that are sequentially transmitted to execute the computer program and control the controlled device;
displaying the state of the controlled device on the display unit by performing a mock execution command for controlling the controlled device;
and displaying an execution command for controlling the controlled device by executing the computer program on the display unit as an image block representing turning on or turning off the light emitting element .
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2020214624A JP7444407B2 (en) | 2020-12-24 | 2020-12-24 | Program execution system, control device and control program |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2020214624A JP7444407B2 (en) | 2020-12-24 | 2020-12-24 | Program execution system, control device and control program |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2022100572A JP2022100572A (en) | 2022-07-06 |
JP7444407B2 true JP7444407B2 (en) | 2024-03-06 |
Family
ID=82271269
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2020214624A Active JP7444407B2 (en) | 2020-12-24 | 2020-12-24 | Program execution system, control device and control program |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP7444407B2 (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2023032995A1 (en) | 2021-08-31 | 2023-03-09 | 富士フイルム株式会社 | Compound and labeled biomaterial using same |
Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2002120174A (en) | 2000-10-11 | 2002-04-23 | Sony Corp | Authoring system, authoring method and storage medium |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH0962537A (en) * | 1995-08-28 | 1997-03-07 | Matsushita Electric Works Ltd | Simulator for confirming operation of display device |
-
2020
- 2020-12-24 JP JP2020214624A patent/JP7444407B2/en active Active
Patent Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2002120174A (en) | 2000-10-11 | 2002-04-23 | Sony Corp | Authoring system, authoring method and storage medium |
Non-Patent Citations (1)
Title |
---|
石井モルナ ほか著,"第1章 ちいさなマイコンmicor:bit"及び"第2章 MakeCodeでらくらくプログラミング",かしこくカワイイmicro:bit入門,第1版,株式会社リックテレコム,2018年,pp. 1-38,ISBN 978-4-86594-137-1 |
Also Published As
Publication number | Publication date |
---|---|
JP2022100572A (en) | 2022-07-06 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
KR102069096B1 (en) | Apparatus for direct remote control of physical device | |
KR200468597Y1 (en) | Training apparatus for android and arduino | |
CN109848985B (en) | Robot graphic programming method and device and intelligent terminal | |
US10456910B2 (en) | Educational systems comprising programmable controllers and methods of teaching therewith | |
JP7444407B2 (en) | Program execution system, control device and control program | |
KR101676676B1 (en) | Robot programing kit using card key and board having resistor and magnet and method thereof | |
KR101452359B1 (en) | Method for providing of toy assembly video | |
CN105940384B (en) | The universal serial bus of peripheral equipment emulates | |
JP2008299068A (en) | Operation training system and operation training method | |
KR102416890B1 (en) | Learning kit for coding and ai education | |
US11908337B2 (en) | Information processing device, intermediation device, simulation system, and information processing method | |
KR102186719B1 (en) | Block type apparatus for wirelessly inputting coding command and method using thereof | |
CN108961979B (en) | Teaching robot system and assembling method | |
KR20200074340A (en) | Smart Toy System Capable of Controlling Multiple Coding Sources | |
KR20190042421A (en) | System for Open Hardware Programming and Mobile Programming | |
KR102251867B1 (en) | System and method for providing coding education using star topology in Internet of things | |
KR102137273B1 (en) | Smart Toy System For Coding Training By Using RFID Tag | |
KR20210029731A (en) | system for managing foreign language learning in mobile environment | |
US20200241851A1 (en) | Information processing apparatus, information processing method, information processing system, program production method, and program | |
CN112598970A (en) | Graphic programming block suite system | |
KR102655327B1 (en) | Educational tool system for improving thinking skills for young children's english and mathematical coding | |
CN112382142A (en) | Graphic programming block suite system | |
KR101572501B1 (en) | Device and method for training wired and wireless communication interface programs for internet of things | |
KR20070025126A (en) | Programming system for educational robot | |
EP3895771A1 (en) | Information processing system |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
RD01 | Notification of change of attorney |
Free format text: JAPANESE INTERMEDIATE CODE: A7421 Effective date: 20221207 |
|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20221212 |
|
A871 | Explanation of circumstances concerning accelerated examination |
Free format text: JAPANESE INTERMEDIATE CODE: A871 Effective date: 20221212 |
|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A821 Effective date: 20221207 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20230404 |
|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20230524 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20230816 |
|
A601 | Written request for extension of time |
Free format text: JAPANESE INTERMEDIATE CODE: A601 Effective date: 20231012 |
|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20231122 |
|
TRDD | Decision of grant or rejection written | ||
A01 | Written decision to grant a patent or to grant a registration (utility model) |
Free format text: JAPANESE INTERMEDIATE CODE: A01 Effective date: 20240214 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20240214 |
|
R150 | Certificate of patent or registration of utility model |
Ref document number: 7444407 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 |