forked from brstu/TMAU-2024
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
dfsfafe Co-authored-by: Yana Sitkovets <[email protected]>
- Loading branch information
1 parent
08ccc31
commit 356d638
Showing
3 changed files
with
41 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
<p align="center">Ìèíèñòåðñòâî îáðàçîâàíèÿ Ðåñïóáëèêè Áåëàðóñü</p> | ||
<p align="center">Ó÷ðåæäåíèå îáðàçîâàíèÿ</p> | ||
<p align="center">“Áðåñòñêèé Ãîñóäàðñòâåííûé òåõíè÷åñêèé óíèâåðñèòåò”</p> | ||
<p align="center">Êàôåäðà ÈÈÒ</p> | ||
<br><br><br><br><br><br> | ||
<p align="center"><strong>Ëàáîðàòîðíàÿ ðàáîòà ¹5</strong></p> | ||
<p align="center"><strong>Ïî äèñöèïëèíå</strong> “Òåîðèÿ è ìåòîäû àâòîìàòè÷åñêîãî óïðàâëåíèÿ”</p> | ||
<p align="center"><strong>Òåìà:</strong> “Ðàáîòà ñ êîíòðîëëåðîì AXC F 2152”</p> | ||
<br><br><br><br><br><br> | ||
<p align="right"><strong>Âûïîëíèë</strong>:</p> | ||
<p align="right">Ñòóäåíò 3 êóðñà</p> | ||
<p align="right">Ãðóïïû ÀÑ-63</p> | ||
<p align="right">Ñòåëüìàøóê È.À.</p> | ||
<p align="right"><strong>Ïðîâåðèë:</strong></p> | ||
<p align="right">Èâàíþê Ä. Ñ.</p> | ||
<br><br><br><br><br> | ||
<p align="center"><strong>Áðåñò 2024</strong></p> | ||
|
||
--- | ||
|
||
### Õîä ðàáîòû: | ||
|
||
 ôóíêöèþ "user_eval" ôàéëà main.plua áûë äîáàâëåí ñëåäóþùèé êîä: | ||
```bash | ||
function user_init() | ||
local DELTA = 200 | ||
A5HL8_info.start_time = get_millisec() | ||
A5HL6_info.start_time = A5HL8_info.start_time - DELTA | ||
A5HL4_info.start_time = A5HL6_info.start_time - DELTA | ||
A5HL2_info.start_time = A5HL4_info.start_time - DELTA | ||
A5HL7_info.start_time = A5HL2_info.start_time - DELTA | ||
A5HL5_info.start_time = A5HL7_info.start_time - DELTA | ||
A5HL3_info.start_time = A5HL5_info.start_time - DELTA | ||
A5HL1_info.start_time = A5HL3_info.start_time - DELTA | ||
end | ||
``` | ||
|
||
## Ðåçóëüòàò | ||
|
||
Óñòàíàâëèâàåòñÿ èíòåðâàë â 200 ìñ ìåæäó ñòàðòîâûìè âðåìåíàìè îáúåêòîâ, çàòåì óñòàíàâëèâàåòñÿ ñòàðòîâîå âðåìÿ äëÿ A5HL8_info â êà÷åñòâå òåêóùåãî âðåìåíè â ìèëëèñåêóíäàõ. Äàëåå ðàçíèöà âî âðåìåíè ìåæäó íèìè ñîñòàâëÿåò 200 ìñ. Òàêèì îáðàçîì, ïðè ðàáîòå êîäà ìåíÿåòñÿ ïîðÿäîê ñâå÷åíèÿ äèîäîâ. |