Changes for page API контроллеров AZ®
Last modified by Max on 2025/03/02 15:18
Summary
-
Page properties (1 modified, 0 added, 0 removed)
Details
- Page properties
-
- Content
-
... ... @@ -862,57 +862,57 @@ 862 862 An example of a polling cycle to get time from the network 863 863 864 864 {{code language="assembler"}} 865 -; дата-время865 +; date-time 866 866 mov #S_DateTime_0,R3; "Lan Date:" 867 867 trap 10 868 - mov #20,R4; количествоцикловожидания869 -$datry: trap 62; отослализапроскNTPсерверу870 - mov #110,@#AZ$CSR; включимсеть871 - trap 47; ожидание872 - trap 47; ожидание868 + mov #20,R4; number of wait cycles 869 +$datry: trap 62; sent a request to the NTP server 870 + mov #110,@#AZ$CSR; enable the network 871 + trap 47; waiting 872 + trap 47; waiting 873 873 mov #ADRTMPSTR,R3 874 - trap 60; считаливбуфер дату-время875 - trap 63; проверилидату-время874 + trap 60; read the date-time into the buffer 875 + trap 63; checked the date-time 876 876 tst R3 877 877 bne $ok 878 878 $sob: sob R4,$datry 879 - mov #S_DateTime_2,R3; печатьошибки879 + mov #S_DateTime_2,R3; print error 880 880 trap 7 881 881 br $go 882 882 883 883 $ok: mov #ADRTMPSTR,R3 884 - trap 24; печатьдаты885 - trap 25; времени886 -$go: mov #110,@#AZ$CSR; включимсеть884 + trap 24; print date 885 + trap 25; time 886 +$go: mov #110,@#AZ$CSR; let's turn on the network 887 887 {{/code}} 888 888 889 - ТутмыявноотсылаемзапроскNTPсерверу,затемвключаемработусетииждемрезультата,периодическиопрашиваяипроверяякорректностьрезультата.889 +Here we explicitly send a request to the NTP server, then turn on the network and wait for the result, periodically polling and checking the correctness of the result. 890 890 891 -== **036:УстановкаRTCнаоснованиичасовTCP/IPстека**==891 +== 036: Setting RTC based on TCP/IP stack clock == 892 892 893 - Кодкоманды036,даннаякомандаустанавливаетRTCнаоснованиичасоввTCP/IPстека.Предварительнонадоустановить часывTCP/IP -команда036.893 +Command code 036, this command sets the RTC based on the clock in the TCP/IP stack. You must first set the clock in TCP/IP - command 036. 894 894 895 - Примерпрограммы:895 +Example program: 896 896 897 897 {{code language="assembler"}} 898 -; trap 64 - установкавремениRTCнаоснованиивременистека899 -; R1 - результат900 -SetDateNETtoRTC:call AZreset; сбросим898 +; trap 64 - set RTC time based on stack time 899 +; R1 - result R1=0 - OK 900 +SetDateNETtoRTC:call AZreset; reset 901 901 tst R1 902 902 bne 0ERR$ 903 903 MOV #AZ$CSR,R1 904 904 mov #36,(R1) 905 -0$: TSTB (R1); проверяемрезультатвыполнения906 - BPL 0$; ждем905 +0$: TSTB (R1); check execution result 906 + BPL 0$; wait 907 907 clr R1 908 908 0ERR$: return 909 909 {{/code}} 910 910 911 -== **042:ПолучитьвремяизчасовTCP/IPстекавбуферtimestamp**==911 +== 042: Get time from TCP/IP stack clock into timestamp buffer == 912 912 913 - Кодкоманды042,даннаякомандаиспользуетчасыTCP/IPстекакакисточникзаполнениябуфераtimestamp.913 +Command code 042, this command uses the TCP/IP stack clock as a source for filling the timestamp buffer. 914 914 915 - Примерпрограммы:915 +Example program: 916 916 917 917 {{code language="assembler"}} 918 918 ; работа с часами