Main Flow

The kernel is composed of 6 modules: video, strings, sound, maths, ports and main.

The main function invokes to following tasks:

          -initialize the video mode 640x480x16
          -draw the rotatable logo
          -draw the no rotatable logo
          -print the screen messages
          -read the password
          -if the password is correct, then fill the screen with "babel"
          -else restart the pc
 
Because we do not have threads to synchronize the rotation of the squares we need to do a pseudo synchronization.


The Bucle

while( continue ){
    
     if( beginstage1 < clockangle < endstage1 ){
          draw_square(
                         angle = anglestage1,
                        size = sizesquare1 * (anglestage1/endstage1)
                          );
          anglestage1 += clockincrease;
     }

     if( beginstage2 < clockangle < endstage2 ){
          draw_square(
                         angle = anglestage2,
                        size = sizesquare2 * (anglestage2/endstage2)
                          );
          anglestage2 += clockincrease;
     }

     if( beginstage3 < clockangle < endstage3 ){
          draw_square(
                         angle = anglestage3,
                        size = sizesquare3 * (anglestage3/endstage3)
                          );
          anglestage3 += clockincrease;
     }else{
          continue = false;
     }

     clockangle += clockincrease;

}