Simple test program for FRDM-KL25Z and Adafruit 2.8" TFT display. For the touch sensor, only polling mode is implemented.

Dependencies:   MMA8451Q SPI_STMPE610 TSI UniGraphic mbed

This program was to test Adafruit 2.8" TFT with touch with FRDM-KL25Z.
After download the binary to the FRDM-KL25Z and push the reset button ,
a simple welcome message will be displayed.

このプログラムは私が秋月で購入した Adafruit 2.8" TFT
http://akizukidenshi.com/catalog/g/gM-07747/
をFRDM-KL25Z で試すために書いたものです。
ダウンロード後にFRDM-KL25Zのリセットスイッチを押すと
最初の画面が表示されます。

Now using UniGraphic library.
And the problem of remaining previous screen is gone. ;-)
For a little bonus, TS_Eyes and Maze are also included.

UniGraphic ライブラリ版になり、画面にごみが残るバグが治りました。
おまけに TS_Eyes と Maze も追加してあります。 (^ ^)v

/media/uploads/Rhyme/img_0984_ss.jpg

If you push and keep the right side of the screen,
the screen will advance to the page2, which is a simple graph sample.

ここで画面の右側をしばらく押していると、次のページに移行します。
このページでは、簡単なグラフを表示する例を描画しています。

/media/uploads/Rhyme/img_0985_ss.jpg

And if you do the same again, the program advances to the page3,
which is a data display page of MMA8451Q accelerometer mounted on
the FRDM-KL25Z.

さらに画面の右側をしばらく押していると、次のページに移行します。
ここでは、FRDM-KL25Zに搭載されている MMA8451Q という3軸の
加速度センサの値を表示しています。

/media/uploads/Rhyme/img_0986_ss.jpg

And this is the last page of this program, so far, so if you
try to advance page, it will return to the first page.

このページが最後のページになっているので、さらにページ送りをすると
最初のページに戻ります。

Committer:
Rhyme
Date:
Sat Aug 08 12:27:57 2015 +0000
Revision:
4:8c3681dc676f
Parent:
3:34d8706e1614
Now using UniGraphic library. The annoying incomplete cls problem is gone.

Who changed what in which revision?

UserRevisionLine numberNew contents of line
Rhyme 3:34d8706e1614 1 #ifndef _MAZE_H_
Rhyme 3:34d8706e1614 2 #define _MAZE_H_ defined
Rhyme 3:34d8706e1614 3
Rhyme 3:34d8706e1614 4 #define MAZE_W 20
Rhyme 3:34d8706e1614 5 #define MAZE_H 20
Rhyme 3:34d8706e1614 6
Rhyme 3:34d8706e1614 7 #define POS_PATH 0
Rhyme 3:34d8706e1614 8 #define POS_WALL 1
Rhyme 3:34d8706e1614 9 #define POS_START 2
Rhyme 3:34d8706e1614 10 #define POS_GOAL 3
Rhyme 3:34d8706e1614 11
Rhyme 3:34d8706e1614 12 uint8_t maze[MAZE_H][MAZE_W] = {
Rhyme 3:34d8706e1614 13 {1,2,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1},
Rhyme 3:34d8706e1614 14 {1,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1},
Rhyme 3:34d8706e1614 15 {1,0,1,0,1,0,1,1,1,1,0,1,1,1,1,1,1,1,0,1},
Rhyme 3:34d8706e1614 16 {1,0,0,0,1,0,1,0,0,0,0,0,0,0,0,0,1,1,0,1},
Rhyme 3:34d8706e1614 17 {1,1,1,1,1,0,1,0,1,1,1,1,1,1,1,0,1,1,0,1},
Rhyme 3:34d8706e1614 18 {1,0,0,0,1,0,1,0,1,0,0,0,0,0,1,0,1,1,0,1},
Rhyme 3:34d8706e1614 19 {1,0,1,1,1,0,1,0,1,1,0,1,0,1,1,0,1,1,0,1},
Rhyme 3:34d8706e1614 20 {1,0,1,0,0,0,1,0,1,1,0,1,0,1,0,0,1,1,0,1},
Rhyme 3:34d8706e1614 21 {1,0,1,0,1,1,1,0,0,1,0,1,0,1,0,1,1,1,0,1},
Rhyme 3:34d8706e1614 22 {1,0,1,0,1,1,1,1,1,1,0,1,0,1,0,0,0,1,0,1},
Rhyme 3:34d8706e1614 23 {1,0,0,0,0,0,0,0,0,0,0,1,0,1,1,1,0,1,0,1},
Rhyme 3:34d8706e1614 24 {1,0,1,1,1,1,1,1,1,1,1,1,0,1,1,1,1,1,0,1},
Rhyme 3:34d8706e1614 25 {1,0,1,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,1},
Rhyme 3:34d8706e1614 26 {1,0,1,0,1,1,1,1,1,1,1,1,1,1,0,1,1,1,1,1},
Rhyme 3:34d8706e1614 27 {1,0,1,0,1,0,0,0,1,0,0,0,0,0,0,1,1,1,1,1},
Rhyme 3:34d8706e1614 28 {1,0,1,0,1,1,1,0,1,0,1,1,1,1,1,1,1,1,1,1},
Rhyme 3:34d8706e1614 29 {1,0,1,0,0,0,1,0,1,0,0,0,0,0,0,0,0,0,0,1},
Rhyme 3:34d8706e1614 30 {1,0,1,1,1,1,1,0,1,1,1,1,1,1,1,1,1,1,0,1},
Rhyme 3:34d8706e1614 31 {1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1},
Rhyme 3:34d8706e1614 32 {1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,3,1}
Rhyme 3:34d8706e1614 33 } ;
Rhyme 3:34d8706e1614 34
Rhyme 3:34d8706e1614 35 extern void doMaze(void) ;
Rhyme 3:34d8706e1614 36 #endif // _MAZE_H_