This is for capstone 2014

Dependencies:   TFTLCD

display.h

Committer:
jmoffat
Date:
2014-04-24
Revision:
5:ef6655e8160c
Parent:
3:ee53c9811f62

File content as of revision 5:ef6655e8160c:

#include "st7735.h"

class display
{
    ST7735_LCD *lcd;
    char *debugstr;
    char *strength;
    char *dist;
    
    public:
    
    display(ST7735_LCD *disp);
    
    /**
    *Debug print that prints text in center of screen.
    *Will overwrite old text.
    */
    void print(char *str);
    /**
    *Displays a calibration screen, prompting user to place beacon certain distance, and press the button. str is the distance displayed on screen.
    */
    void calibrationdist(char *str);
    /**
    *Displays a calbration screen, prompting the user to turn the beacon off and press the button
    */
    void calibrationunl(void);
    /**
    *Test function that prints a string repeatedly in a rainbow fashion.
    */
    void printrb(const char *str);
    /**
    *Debug function that blinks text.
    */
    void blinktext(const char *str);
    
    /**
    *Displays the the strength on the screen, on the first line.
    *newStrength is the number in the form of a string, with units as
    *desired. Prints in format "Strength:newStrength". Will overwrite old
    *value automatically.
    */
    void displayStr(char *newStrength);
    
    /**
    *Works identically to displayStrength, but on second line with distance.
    *Prints in format "Dist:newDist". Units must be in string as desired.
    *Will overwrite old value automatically.
    */
    void displayDist(char * newDist);
};