Mini projet LOO

Dependencies:   mbed APDS_9960 mbed-rtos

Dependents:   MoveYourTetris_OK

Home du projet

Committer:
clementdoreau
Date:
Fri Mar 25 08:21:57 2016 +0000
Revision:
0:b2acac6abf2b
Child:
1:ab5f440f4156
Classe forme cr??e

Who changed what in which revision?

UserRevisionLine numberNew contents of line
clementdoreau 0:b2acac6abf2b 1 #ifndef CFORME_H
clementdoreau 0:b2acac6abf2b 2 #define CFORME_H
clementdoreau 0:b2acac6abf2b 3
clementdoreau 0:b2acac6abf2b 4 class cForme
clementdoreau 0:b2acac6abf2b 5 {
clementdoreau 0:b2acac6abf2b 6
clementdoreau 0:b2acac6abf2b 7 protected:
clementdoreau 0:b2acac6abf2b 8 unsigned char _orientation; // 4 orientations : rotation de 90° --> de 1 à 4
clementdoreau 0:b2acac6abf2b 9 unsigned char _positionX;
clementdoreau 0:b2acac6abf2b 10 unsigned char _positionY;
clementdoreau 0:b2acac6abf2b 11 // LEDS
clementdoreau 0:b2acac6abf2b 12 private:
clementdoreau 0:b2acac6abf2b 13
clementdoreau 0:b2acac6abf2b 14 public:
clementdoreau 0:b2acac6abf2b 15 // CONSTRUCTEURS
clementdoreau 0:b2acac6abf2b 16 cForme();
clementdoreau 0:b2acac6abf2b 17 cForme(unsigned char o, unsigned char x, unsigned char y);
clementdoreau 0:b2acac6abf2b 18 // GETTERS
clementdoreau 0:b2acac6abf2b 19 unsigned char getOrientation();
clementdoreau 0:b2acac6abf2b 20 unsigned char getPositionX();
clementdoreau 0:b2acac6abf2b 21 unsigned char getPositionY();
clementdoreau 0:b2acac6abf2b 22 // SETTERS
clementdoreau 0:b2acac6abf2b 23 void setOrientation(unsigned char orientation);
clementdoreau 0:b2acac6abf2b 24 void setPositionX(unsigned char x);
clementdoreau 0:b2acac6abf2b 25 void setPositionY(unsigned char y);
clementdoreau 0:b2acac6abf2b 26 virtual void afficherForme();
clementdoreau 0:b2acac6abf2b 27
clementdoreau 0:b2acac6abf2b 28
clementdoreau 0:b2acac6abf2b 29 };
clementdoreau 0:b2acac6abf2b 30
clementdoreau 0:b2acac6abf2b 31
clementdoreau 0:b2acac6abf2b 32 #endif