Skip to content

Commit

Permalink
Move wiki into doc directory. (#50)
Browse files Browse the repository at this point in the history
* Subtree-merge wiki repository.
* Fix links in the documents.
  • Loading branch information
at-wat authored Nov 10, 2017
1 parent 3b24c7f commit e60da98
Show file tree
Hide file tree
Showing 20 changed files with 312 additions and 1 deletion.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ YP-Spur is a mobile robot motion control software with coordinate frame based co

## Getting Started

Learn to use YP-Spur at our [wiki pages](https://github.com/openspur/yp-spur/wiki).
Learn to use YP-Spur at the [documentation pages](./doc/README.md).

## Install
```
Expand Down
8 changes: 8 additions & 0 deletions doc/Auxiliary-Files.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
## Files

* [移動ロボットのモータ制御と走行制御 (Vehicle and motion control of mobile robots)](https://at-wat.github.io/ROS-quick-start-up/lecture_1.html)
* 制御則の解説
* パラメータファイルの設定方法概要

* [libypspur コマンド一覧](https://github.com/openspur/yp-spur/wiki/files/libypspur_cheatsheet.pdf)
* known issue: `Spur_set_pos_FS` が記載されているが実際には存在しない
13 changes: 13 additions & 0 deletions doc/Control-Architecture.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
The following figure shows a control diagram of YP-Spur.

![Spur control system](https://github.com/openspur/yp-spur/wiki/images/spur_system_en.png)

Trajectory tracking controller is expressed by:

![Spur line following control](https://github.com/openspur/yp-spur/wiki/images/spurline_en.png)

The original idea of the control approach is reported in [1-3].

* [1] S. Yuta, Y. Kanayama. An implementation of MICHI - A locomotion command system for intelligent mobile robot, in Proc. of International Conference on Advanced Robotics, pp. 127-134, 1985
* [2] S. Iida, S. Yuta, Control of Vehicle with Power Wheeled Steerings Using Feed-forward Dynamics Compensation , in Proc. of Annual Conference on the IEEE Industrial Electronics Society, pp. 2264-2269, 1991
* [3] 飯田重喜, 油田信一. 車輪型移動ロボットのための走行制御コマンド系と軌跡制御方式, in Proc. of 第1 回日本ロボット学会ロボットシンポジウム, pp. 85-90, 1991
41 changes: 41 additions & 0 deletions doc/Embedding-Parameters.ja.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
YP-Spur対応のモータドライバには、パラメータファイルの情報や、パラメータを埋め込める物があります。(T-frogプロジェクト TF-2MD3-R4/R6など)

# パラメータ名の指定

モータドライバのデバイスに、ターミナルソフト(Unix系の場合 `cat /dev/ttyACM? & cat - > /dev/ttyACM?` コマンド、Windowsの場合 TeraTermなど)で下記のコマンドを送ります。
```
$SETNAME[name_of_the_parameter_file]
$EEPROMSAVE
```

ypspur-coordinatorは、パラメータファイルが指定されていない場合、`[name_of_the_parameter_file].param` を読み込もうとします。
`[name_of_the_parameter_file]``embedded` の場合、ドライバに埋め込まれたパラメータファイルを読み込みます。

# パラメータファイルの埋め込み

まず、パラメータ名を `embedded` に指定します。
```
$SETNAMEembedded
$EEPROMSAVE
```

パラメータファイルの内容を書き込みます。
```
SETEMBEDDEDPARAM
parameter: value
parameter: value
parameter: value
parameter: value
parameter: value
```

パラメータの最後に、連続する改行を入力して下さい。
途中に改行が連続しないように注意します。
TF-2MD3-R4/R6の場合、最大のサイズは 512 bytes です。

# パラメータファイルの読み込み

```
GETEMBEDDEDPARAM
```
42 changes: 42 additions & 0 deletions doc/Embedding-Parameters.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
Motor controllers like TF-2MD3-R4/R6 by T-frog Project can have embedded parameter file on the controller board.

# Setting parameter name

Open device port to send following commands.
(On Unix/unix-like, `cat /dev/ttyACM? & cat - > /dev/ttyACM?`. On Windows, use TeraTerm)
```
$SETNAME[name_of_the_parameter_file]
$EEPROMSAVE
```

If `-p` option is not specified, ypspur-coordinator uses `[name_of_the_parameter_file].param`.
If `[name_of_the_parameter_file]` is `embedded`, ypspur-coordinator uses controller embedded parameter file.


# Embedding parameter file

Change parameter name to `embedded`.
```
$SETNAMEembedded
$EEPROMSAVE
```

Embed desired parameter file.
```
SETEMBEDDEDPARAM
parameter: value
parameter: value
parameter: value
parameter: value
parameter: value
```

Consecutive two line-feeds indicates the end of the parameter file.
In the case of TF-2MD3-R4/R6, a maximum number of characters is 512 bytes.

# Reading embedded parameter file

```
GETEMBEDDEDPARAM
```
83 changes: 83 additions & 0 deletions doc/Manpage.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
# libypspur

## Initialization

### Name

Spur_init, Spur_initex, Spur_init_socket - Initialization of YP-Spur library

### Synopsis

```
int Spur_init( void )
int Spur_initex( int msq_id )
int Spur_init_socket( const char *ip, int port )
```

### Description

* **msq_id** Message queue id
* **ip** IP address
* **port** TCP/IP port number

### Return value

On success, zero is returned. On error, -1 is returned.

***

## Basic parameter settings

### Name

Spur_set_vel, Spur_set_angvel, Spur_set_accel, Spur_set_angaccel - parameter settings

### Synopsis

```
int Spur_set_vel( double vel )
int Spur_set_angvel( double angvel )
int Spur_set_accel( double accel )
int Spur_set_angaccel( double angaccel )
```

### Description

* **vel** Maximum linear velocity of the robot _[m/s]_
* **angvel** Maximum angular velocity _[rad/s]_
* **accel** Maximum linear acceleration _[m/ss]_
* **angaccel** Maximum angular acceleration _[rad/ss]_

### Return value

On success, zero is returned. On error, -1 is returned.

***

## Line following

### Name

Spur_line_GL, Spur_line_LC, Spur_line_FS - Line following

### Synopsis

```
int Spur_line_GL( double x, double y, double yaw )
int Spur_line_LC( double x, double y, double yaw )
int Spur_line_FS( double x, double y, double yaw )
```

### Description

* **x** x-coordinate of a point where the desired line passing through _[m]_
* **y** y-coordinate of the point _[m]_
* **yaw** orientation of the line _[rad]_

![Parameters for line following control](https://github.com/openspur/yp-spur/wiki/images/commands/line.png)

### Return value

On success, zero is returned. On error, -1 is returned.

***
9 changes: 9 additions & 0 deletions doc/Parameter-File.ja.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# パラメータファイルの作成方法

下記URLのパラメータ生成ツールを使用すると、基本的なパラメータを作成できます。
* http://t-frog.com/products/motor_driver/parameter.php

パラメータの意味や、制御の概念については、下記資料を参照して下さい。
* https://at-wat.github.io/ROS-quick-start-up/lecture_1.html

(stub)
58 changes: 58 additions & 0 deletions doc/README.ja.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
# YP-Spurとは?

YP-Spurは、移動ロボットの走行制御と座標系ベースのコマンドシステムを提供するソフトウェアです。詳細な制御のアーキテクチャについては、[Control Architecture](./Control-Architecture.md)を参照して下さい。

[![Build Status](https://travis-ci.org/openspur/yp-spur.svg?branch=master)](https://travis-ci.org/openspur/yp-spur)


# Index

[English version is here.](README.md)

* [Home](README.ja.md)
* [Parameter File](Parameter-File.ja.md)
* [Control Architecture (en)](Control-Architecture.md)
* [Manpage (en)](Manpage.md)
* [Embedding Parameters](Embedding-Parameters.ja.md)
* [Auxiliary Files](Auxiliary-Files.md)


# Quick Start Guide

## インストール

* gcc, 標準Cライブラリをインストール
* 下記のコマンドでYP-Spurをビルド、インストール
```
$ git clone https://github.com/openspur/yp-spur
$ cd yp-spur
$ mkdir build
$ cd build
$ ../configure
$ make
$ sudo make install
$ sudo ldconfig
```

## ブランチしているバージョンを試す

(Gitの使い方を理解している前提です)

* 下記ページから、試したいブランチ名またはタグ名を探す
https://github.com/openspur/yp-spur/branches, https://github.com/openspur/yp-spur/releases.
* インストール手順で git clone した、yp-spurディレクトリに移動
* 所望のブランチまたはタグをチェックアウト
```
$ git fetch origin
$ git checkout -b [ブランチ名] origin/[ブランチ名]
```
* インストール手順と同様、build ディレクトリで make, make install を実行

## 使い方

* 端末(Terminal)を2つ起動
* ypspur-coordinatorを、端末1で実行
```
$ ypspur-coordinator -p PARAMETER_FILE.param -d /path/to/device
```
* ユーザプログラムを、端末2で実行
57 changes: 57 additions & 0 deletions doc/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
# What is YP-Spur?

YP-Spur is a mobile robot motion control software with coordinate frame based commands.
See [Control Architecture](./Control-Architecture.md) to learn the detail of the control system.

[![Build Status](https://travis-ci.org/openspur/yp-spur.svg?branch=master)](https://travis-ci.org/openspur/yp-spur)


# Index

[Japanese version is here.](README.ja.md)

* [Home](README.md)
* [Parameter File (ja)](Parameter-File.ja.md)
* [Control Architecture](Control-Architecture.md)
* [Manpage](Manpage.md)
* [Embedding Parameters](Embedding-Parameters.md)
* [Auxiliary Files (ja)](Auxiliary-Files.md)


# Quick Start Guide

## Install

* Install gcc and C standard libraries
* Build and install YP-Spur
```
$ git clone https://github.com/openspur/yp-spur
$ cd yp-spur
$ mkdir build
$ cd build
$ ../configure
$ make
$ sudo make install
$ sudo ldconfig
```

## Try branched version

* **First of all, learn Git!**
* Find a branch or tag name at https://github.com/openspur/yp-spur/branches or https://github.com/openspur/yp-spur/releases.
* Go to yp-spur directory where you have cloned.
* Checkout the desired version.
```
$ git fetch origin
$ git checkout -b [branch name] origin/[branch name]
```
* Then, make and make install in the build directory.

## Use YP-Spur

* Open two terminals
* Run ypspur-coordinator in terminal 1 and keep it running
```
$ ypspur-coordinator -p PARAMETER_FILE.param -d /path/to/device
```
* Run user program in terminal 2
Binary file added doc/files/libypspur_cheatsheet.pdf
Binary file not shown.
Binary file added doc/images/commands/circle.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/images/commands/line.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/images/commands/near_angle.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/images/commands/near_pos.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/images/commands/orient.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/images/commands/over_line.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/images/commands/spin.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/images/commands/stop_line.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/images/spur_system_en.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/images/spurline_en.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit e60da98

Please sign in to comment.