dsair2_basic
差分
このページの2つのバージョン間の差分を表示します。
両方とも前のリビジョン前のリビジョン次のリビジョン | 前のリビジョン次のリビジョン両方とも次のリビジョン | ||
dsair2_basic [2019/03/03 11:05] – [Function] yaasan | dsair2_basic [2019/03/19 07:39] – [BASIC functions] yaasan | ||
---|---|---|---|
行 8: | 行 8: | ||
DSbasicは、スマートフォン(Android, | DSbasicは、スマートフォン(Android, | ||
- | {{http:// | + | {{http:// |
- | [[http:// | + | [[http:// |
行 22: | 行 22: | ||
* Support Locomotive and Turnouts control via BASIC language | * Support Locomotive and Turnouts control via BASIC language | ||
* MP3 Play suported in MP3 files of FlashAir SD card. | * MP3 Play suported in MP3 files of FlashAir SD card. | ||
- | ===== Function ===== | + | ===== BASIC Function ===== |
+ | |||
+ | ==== DSair2 Unique Functions | ||
LocAddr is Locomotive address. Default protocol is DCC. If you want to control Marklin' | LocAddr is Locomotive address. Default protocol is DCC. If you want to control Marklin' | ||
行 32: | 行 34: | ||
|ACC| AccAddr, Direction| diverse=0, straight=1 | | |ACC| AccAddr, Direction| diverse=0, straight=1 | | ||
|DIR| LocAddr, Direction| FWD=1, REV=2 | | |DIR| LocAddr, Direction| FWD=1, REV=2 | | ||
- | |FNC| LocAddr, FuncNo, FuncON/OFF| FuncNo=0-28 | | + | |FNC| LocAddr, FuncNo, FuncON/OFF| FuncNo=0-28, FuncON/ |
- | |FNX| LocAddr, FuncNo| FuncNo=0-28 | | + | |FNX| LocAddr, FuncNo| FuncNo=0-28, |
|MP3PLAY| FileName with Path | MP3PLAY " | |MP3PLAY| FileName with Path | MP3PLAY " | ||
|MP3STOP| - | MP3STOP | | |MP3STOP| - | MP3STOP | | ||
行 42: | 行 44: | ||
|getslotfnc| SlotNo(0-3), | |getslotfnc| SlotNo(0-3), | ||
|getslotfncw| SlotNo(0-3) | 4つのユーザー指定アドレススロットからファンクション状態を29bit分返します。 | | |getslotfncw| SlotNo(0-3) | 4つのユーザー指定アドレススロットからファンクション状態を29bit分返します。 | | ||
- | |S88START| - | | | + | |S88START| - | S88機能を有効にします。S88の関数を使う場合は必ずBASICプログラムの最初に記述して下さい。括弧はつけないでください。 |
|S88GET, | |S88GET, | ||
|GETS88W| S88Sensor address(1-16) | S88センサーの値を16bit分返します。 | | |GETS88W| S88Sensor address(1-16) | S88センサーの値を16bit分返します。 | | ||
行 59: | 行 61: | ||
BASIC functions are described in [[https:// | BASIC functions are described in [[https:// | ||
- | ==== BASIC functions ==== | + | ==== Main functions ==== |
FOR, | FOR, | ||
- | PRINT, | ||
- | RND, | ||
+ | ==== Drawing functions ==== | ||
+ | |||
+ | |||
+ | * COLOR | ||
+ | * LOCATE | ||
+ | * LINE | ||
+ | * PAINT | ||
+ | * CIRCLE | ||
+ | * PUT | ||
+ | * SCREEN | ||
+ | * CLS | ||
+ | * WIDTH | ||
+ | * PALETTE | ||
+ | * | ||
+ | |||
+ | ==== Math functions ==== | ||
+ | |||
+ | asc, sqr, int, cint | ||
+ | abs, cos, sin, tan | ||
+ | atn, exp, log, rnd, atan2 | ||
+ | |||
+ | ==== Text functions ==== | ||
+ | |||
+ | * val 文字を数値に変換 | ||
+ | * str$ 数値を文字列に変換 | ||
+ | * ltrim$ 左側文字列を抜き出す | ||
+ | * rtrim$ 右側文字列を抜き出す | ||
+ | * left$ | ||
+ | * right$ | ||
+ | * mid$ | ||
+ | * string$ | ||
+ | * space$ スペースを抜き出す | ||
+ | * tab | ||
+ | * ucase$ 英字を大文字にする | ||
+ | * lcase$ 英字を小文字にする | ||
+ | * mid$ | ||
+ | * | ||
+ | |||
+ | |||
+ | |||
+ | ==== Key Input functions ==== | ||
+ | |||
+ | * inkey$ | ||
+ | * input | ||
+ | |||
+ | ==== Mouse Input functions ==== | ||
+ | |||
+ | * getmouse | ||
+ | * | ||
+ | |||
+ | ==== Etc functions ==== | ||
+ | |||
+ | * timer | ||
+ | * SLEEP | ||
+ | * swap | ||
+ | * | ||
===== Examples ===== | ===== Examples ===== | ||
dsair2_basic.txt · 最終更新: 2023/09/02 11:01 by yaasan