tcCreateHandle, tcChangeFilter, tcStartTrace, tcStopTrace, tcProductionTrace, tcQuarityTrace, tcMarking |
メモリ管理 | tcAllocateRtMemory, tcFreeRtMemory, tcCreateRtMemoryHandle, tcDeleteRtMemoryHandle, tcMapRtSharedMemory |
リアルタイム プロセス管理 |
tcCreateRtProcess, tcExitRtProcess, tcWaitForRtProcess, tcDeleteRtProcess, tcTerminateRtProcess, tcSetRtProcessMaxPriority |
オブジェクト名 管理 |
tcCatalogRtHandle, tcLookupRtHandle, tcUncatalogRtHandle |
リアルタイム スレッド管理 |
tcCreateRtThread, tcDeleteRtThread, tcGetRtThreadHandles, tcSetRtThreadPriority, tcRtSleep, tcRtSleepEx, tcSuspendRtThread, tcResumeRtThread, tcknRtSleep |
セマフォ管理 | tcCreateRtSemaphore, tcDeleteRtSemaphore, tcWaitForRtSemaphore, tcReleaseRtSemaphore |
メールボックス 管理 |
tcCreateRtMailbox, tcDeleteRtMailbox, tcSendRtHandle, tcReceiveRtHandle, tcSendRtData, tcReceiveRtData |
リージョン管理 | tcCreateRtRegion, tcDeleteRtRegion, tcAcceptRtControl, tcWaitForRtControl, tcReleaseRtControl |
ハードウェア 割り込み管理 |
tcSetRtInterruptHandlerEx, tcResetRtInterruptHandler, tcSignalRtInterruptThread, tcWaitForRtInterrupt |
アラーム管理 | tcCreateRtAlarm, tcWaitForRtAlarm, tcResetRtAlarm, tcDeleteRtAlarm |
グローバル オブジェクト |
tcGetRtNodeStatus, tcGetRemoteRootRtProcess, tcGetRtNodeLocationByName, tcGetRtNodeInfo |
補助 | tcCopyRtSystemInfo, tcWaitForRtIoService, tcGetLastRtError |
データアクセス 制御 |
RTTlib::open, RTTlib::close, RTTlib::seek |
データレコード 制御 |
RTTlib::next, RTTlib::filter |
データパーサー | RTTParser::Parse |
RSI-001 | トレース付RS-232C/422/485通信 |
RSI-008i | トレース付高速多CHシリアル通信 |
RSI-040 | トレース付FL-netバス通信 |
RSI-CCIE | トレース付CC-Link IEバス通信 |
RSI-ECAT | トレース付EtherCAT®マスター |
RSI-CAN | トレース付CANバス通信 |
// 温度センサを監視して異常判定するスレッド
void ThreadTemperatureWarning(void)
{
RTHANDLE hIntval; // 処理サイクル
BYTE buf[128]; // 受信バッファ
TCHANDLE hT = TC_ON; // トレースをアクティブ
hIntval = tcCreateRtAlarm(hT ,10); // サイクル生成
while (1)
{
// 処理サイクル待ち
hIntval = tcWaitForRtAlarm(hT ,hIntval ,100MS);
// 温度センサユニットとCOM1で通信
tc_rs_transmit(hT ,COM1 ,"GET" ,3);
tc_rs_receive(hT ,COM1 ,buf ,10);
// 設計温度上限判定
fTemp1 = atol(buf);
if (fTemp1 > TempUpLim)
{
// 温度異常発生イベントを発行
tcReleaseRtSemaphore(hT ,hWarning ,1);
tcMarking(hT ,"温度異常障害");
}
}
}
13:10:10.238,200,3ee0,3ee8,tcWaitForRtAlarm(i),0x3eec,100
13:10:10.338,200,3ee0,3ee8,tcWaitForRtAlarm(o),ret=TRUE,E_OK
13:10:10.339,200,3ee0,3ee8,tc_rs_transmit(i),COM1,msg="GET",len=3
13:10:10.340,200,3ee0,3ee8,tc_rs_transmit(o),E_OK
13:10:10.341,200,3ee0,3ee8,tc_rs_receive(i),COM1,0x410050,len=10
13:10:10.346,200,3ee0,3ee8,tc_rs_receive(o),msg="132.5",len=5,E_OK
13:10:10.348,200,3ee0,3ee8,tcReleaseRtSemaphore(i),3f00,unit=1
13:10:10.349,200,3ee0,3ee8,tcReleaseRtSemaphore(o),ret=TRUE,E_OK
13:10:10.350,200,3ee0,3ee8,tcMarking,"温度異常障害"