// on the first scan, call subroutine 0
LD SM0.1
CALL SBR_0
NETWORK 1 // Subroutine 0
LD SM0.0
MOVB 100 SMB34 // Set the interval for the timed interrupt 0 to 100 ms
ATCH INT_0 10 // Attach timed interrupt 0 (Event 10) to INT_0
ENI // Global interrupt enable
NETWORK 1 // Interrupt 0
// Read the value of AIW4 every 100 ms
LD SM0.0
MOVW AIW4 VW100
I think it is wright, but if i want to measure the AIW4 every 5 seconds what shall i do?
Because SMB34 Timed Interrupt 0: Time interval value (in 1 ms increments from 1 ms to 255 ms).
2nd question
How can i store 1000 values of AIW4 every 5 sec?
p.s: sorry for my English
bye
LD SM0.1
CALL SBR_0
NETWORK 1 // Subroutine 0
LD SM0.0
MOVB 100 SMB34 // Set the interval for the timed interrupt 0 to 100 ms
ATCH INT_0 10 // Attach timed interrupt 0 (Event 10) to INT_0
ENI // Global interrupt enable
NETWORK 1 // Interrupt 0
// Read the value of AIW4 every 100 ms
LD SM0.0
MOVW AIW4 VW100
I think it is wright, but if i want to measure the AIW4 every 5 seconds what shall i do?
Because SMB34 Timed Interrupt 0: Time interval value (in 1 ms increments from 1 ms to 255 ms).
2nd question
How can i store 1000 values of AIW4 every 5 sec?
p.s: sorry for my English
bye