% 1. Interface Programme 
% 2. Types & variables
/*
Taille
Importance
Utilisation
Syntaxe
*/





% Fonction 1
void setup() {
// put your setup code here, to run once:

}
% Fonction 2
void loop() {
// put your main code here, to run repeatedly:

}
% Types & Variables 
Type Var_nom [=Valeur Init];

bool:

  •   true, false
  •   Exemple: bool LED_etat=false;

byte

  •   0-255
  •   Exemple: byte val;

char

  •   Caractères ASCII
  •   Exemple: char carac_1=’A’;
  •   char carac_2=65;

int

  •   [-2^15, 2^15-1]=[-32768,32767]
  •   Exemple: int ADC_val=1000;

long

  •   [-2^31, 2^31-1]=[-2147483648,2147483647]
  •   Exemple: long ADC_val=1000;

short = unsigned int  (16 bits)

  •   [-2^15, 2^15-1]=[-32768,32767]
  •   Exemple: int ADC_val=1000;

float

  •   Réel simple précision (32 bits)
  •   Exemple: int Temp_val=32.5553;

double

  •   Réel double précision (64 bits)
  •   Exemple: int Poids_val=55.23;

unsigned char 0-255 (-128,127)

unsigned int- word

unsigned long

Click to rate this post!
[Total: 2 Average: 2.5]

Laisser un commentaire

Votre adresse e-mail ne sera pas publiée. Les champs obligatoires sont indiqués avec *

Retour en haut

You have successfully subscribed to the newsletter

There was an error while trying to send your request. Please try again.

FPGA | Arduino | Matlab | Cours will use the information you provide on this form to be in touch with you and to provide updates and marketing.