Skip to main content
. 2020 Oct 3;22(10):1119. doi: 10.3390/e22101119
Algorithm 1 The microcontroller-based main program
Initialize the microcontroller and configure the output pins;
Set the length N of sequences, the Number M of interpolation;
Set intermediate variables step1,2,3,4, temp1,2,3,4 and value1,2,3,4;
while true
 Set four sets of (ai, bi, xi,0, yi,0) (i = 1,2,3,4);
for i = 1 to N
   //system equation
   x1,i+1 = 1 − a1|x1,i| + y1,i; y1,i+1 = b1×1,i;
   …
   x4,i+1 = 1 − a4|x4,i| + y4,i; y4,i+1 = b4×4,i;
   //interpolation
   step1 = (x1,i+1x1,i)/M; … step4 = (x4,i+1x4,i)/M;
   for j = 0 to M − 1
    temp1 = x1,i + jstep1; value1 = (temp1 + 15)*4096/30;
    …
    temp4 = x4,i + jstep4; value4 = (temp4 + 15)*4096/30;
    Transfer the value1,2,3,4 to TLV5618;
   end
end