on Sunday, February 27, 2011
Bonjour tout le monde,
J'ai toujours aimé un journal lumineux dans ma petite chambre.
Pour cela j'ai commencé à travailler au sein de mon club mécatronique sur ce projet.
Liste de composants:
64 leds                                               pour chaque module
un registre à décalage 74HC595          ,,                  ,,
une interface de puissance ULN2803   ,,                 ,,
pic 16F877
Principe de fonctionnement:
le microcontreleur 16F877 fait partie de la carte de commande il envoie les données à afficher via le protocole série spi vers le pin DS du registre à décalage, si les données en entrés sont supérieurs à 8 bit le registre fait décaler les données via le pin Q7' qui transmit les données vers le pin DS de registre suivant.
la scrutation des lignes du journal lumineux est active en permanence.
Code en mikroc:

const unsigned short ASCII[] = {
        0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // code por espace
        0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // code por espace
        0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // code por espace
        0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // code por espace
        0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // code por espace
        0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // code por espace
        0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // code por espace
        0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // code por espace
        0x00, 0x0F, 0x30, 0xC0, 0xC0, 0x30, 0x0F, 0x00,  // Code pour char V
        0x00, 0xFF, 0x89, 0x89, 0x89, 0x81, 0x81, 0x00,  // Code pour char E
        0x00, 0xFF, 0x03, 0x0C, 0x30, 0xC0, 0xFF, 0x00,  // Code pour char N
        0x00, 0x00, 0x01, 0x01, 0xFF, 0x01, 0x01, 0x00,  // Code pour char T
        0x00, 0xFF, 0x89, 0x89, 0x89, 0x81, 0x81, 0x00,  // Code pour char E
        0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // code por espace
        0x00, 0x00, 0x01, 0x01, 0xFF, 0x01, 0x01, 0x00,  // Code pour char T
        0x00, 0x00, 0x81, 0xFF, 0x81, 0x00, 0x00, 0x00,  // Code pour char I
        0x00, 0x7E, 0x81, 0x81, 0x81, 0x81, 0x42, 0x00,  // Code pour char C
        0x00, 0xFF, 0x08, 0x18, 0x24, 0x42, 0x81, 0x00,  // Code pour char K
        0x00, 0xFF, 0x89, 0x89, 0x89, 0x81, 0x81, 0x00,  // Code pour char E
        0x00, 0x00, 0x01, 0x01, 0xFF, 0x01, 0x01, 0x00,  // Code pour char T
        0x00, 0x46, 0x89, 0x89, 0x89, 0x89, 0x72, 0x00,  // Code pour char S
        0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // code por espace
        0x00, 0xFF, 0x02, 0x0C, 0x0C, 0x02, 0xFF, 0x00,  // Code pour char M
        0x00, 0xE0, 0x1C, 0x13, 0x13, 0x1C, 0xE0, 0x00,  // Code pour char A
        0x00, 0x46, 0x89, 0x89, 0x89, 0x89, 0x72, 0x00,  // Code pour char S
        0x00, 0x7E, 0x81, 0x81, 0x81, 0x81, 0x42, 0x00,  // Code pour char C
        0x00, 0x7E, 0x81, 0x81, 0x81, 0x81, 0x7E, 0x00,  // Code pour char O
        0x00, 0x00, 0x01, 0x01, 0xFF, 0x01, 0x01, 0x00,  // Code pour char T
        0x00, 0x00, 0x01, 0x01, 0xFF, 0x01, 0x01, 0x00,  // Code pour char T
        0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // code por espace
        0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // code por espace
        0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // code por espace
        0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // code por espace
        0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // code por espace
        0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // code por espace
        0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // code por espace
        0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,  // code por espace
  };

unsigned char index[8]={0X01,0X02,0X04,0X08,0X10,0X20,0X40,0X80};
unsigned char i=0,j=0,t=0;
 void balayage(){
      for(t=0;t<300;t++){
       for(i=0;i<8;i++){
         portb=~index[i];
         spi1_write(ASCII[t+i]);
         spi1_write(ASCII[t+i+8]);
         spi1_write(ASCII[t+i+16]);
         spi1_write(ASCII[t+i+32]);
         spi1_write(ASCII[t+i+40]);
         spi1_write(ASCII[t+i+48]);
         spi1_write(ASCII[t+i+56]);
         portc.RC6=0;
         portc.RC6=1;
         delay_us(8000);
       }
      }
 }
 }
void main() {
 portb=0X00;
 trisb=0X00;
 portc=0X00;
 trisc=0X00;
 spi1_init();
     while(1){
             balayage();
     }
}
Simulation sur isis



on Monday, January 31, 2011


I kind of like it :))
on Tuesday, January 18, 2011
Je vais parler brièvement des langages de programmation les plus utilisés cette année et ouvrir une réflexion sur ce qu'il est utile d'apprendre pour être intéressant(e) sur le marché du travail.
Dans le top 3, on a le C, le Java et le C++. Ce n'est pas du tout une surprise. C et Java se font la bourre depuis des années et ils sont les principales demandes dans les annonces pour du boulot.
En 4ème position on retrouve PHP. Très critiqué mais bizarrement très utilisé. Je pense que sa facilité d'utilisation lui donne tout son charme. L'idée qu'un jour Ruby puisse lui voler la vedette n'est plus d'actualité.
Viennent ensuite VB et C#, puis Pyhton et Perl.
Du coup, si demain on me demandait quels langages il serait intéressant d'apprendre pour être concluant sur le marché du travail, je répondrais JAVA, C et PHP.
Java permet de facilement utiliser les technos .NET : basiquement, si tu sais écrire du JAVA, tu sais écrire en C#.
C n'a plus à prouver quoique ce soit et je n'ai certainement pas les compétences pour le critiquer.
En ce qui concerne PHP, il permet à la fois de développer facilement des sites web dynamique mais également de s'interfacer facilement avec le système (en tout cas, sur un GNU/Linux). En plus, il permet d'appréhender rapidement Perl et Ruby.
J'aimerais terminer sur bon gros troll. Action Script et sa misérable 19ème place ne mériterait même pas que j'en parle, mais c'est tellement bon de voir qu'il est loin derrière le podium et que juste devant, se placent des langages dont je n'ai jamais entendu parler.

on Thursday, December 30, 2010

Tour de Flex is a desktop application for exploring Flex capabilities and resources, including the core Flex components, Adobe AIR, data integration, and a variety of third-party components, effects, skins, and more.
Tour de Flex has three primary goals:
  • Provide non-Flex developers with an overview of what is possible in Flex in a "look and see" environment
  • Provide Flex developers with an illustrated reference tool
  • Provide commercial and non-commercial Flex developers with a place to showcase their work
System requirements:
on Monday, December 27, 2010
Can you believe this little piglet is just a mirage? Me neither! Acctually it isn’t there at all! Instead it’s inside the spheric box, and mirrors inside make it look as 3D hologram. You can watch the video to be sure. I found this optical illusion at Grand Illusions, so if you want to buy Mirage for yourself, jump to their website. The Mirage is one of those classic toys that has been around for several decades now, but never lost its appeal. It produces a small, full-color hologram of natural, lifelike appearance, allowing 360-degree viewing. The little plastic pig seems solid enough, but when you try and touch it, your fingers find that it is just an illusion – there is nothing there. You can find the explanation of this optical illusion inside this post. Also if you enjoy this kind of tricky toys, you might want to visit “Magical Cube Toy”.
Mirage consists of two opposing parabolic mirrors. In overall appearance, Mirage resembles a small 9inch wok with a circular opening in the top. The physical object to be converted to a hologram is placed in the concave centre of the bottom mirror.
A hologram instantly projects up through this aperture, appearing to the viewer as a truly solid object. We supply the little plastic pig, but you can place any object in the Mirage, and instantly convert it into a wonderful optical illusion!
Mirage was originally discovered over 30 years ago, when a member of staff at the University of California at Santa Barbara was cleaning around a stack of searchlight reflectors (which are parabolic reflectors of course!) when he noticed that he was trying to clean off some ‘dust’ that turned out not to actually be there! He showed this to one of the physics professors, and the two of them started making a commercial product, based around the phenomenon that they had accidentally discovered.
Their initial product was made of glass, and was quite expensive. Later an American company called Optigone took out a licence, and started making a version in plastic, which could sell for a third of the price. There have been even cheaper copies made in the Far East, but they tend to have lower quality optics.