The class itself has 12 cases in the constructor for each printable digit: 0-9 and the °
sign and the C
Celcius sign.
For the constructor of the DrawSegment class I was inspired by the repository from SK-SpeedBit.
The Drawsegment method is the method which takes care of printing the digit
Is the top segment of the array.
Is the middle segment of the array.
Is the bottom segment of the array.
Generated using TypeDoc
A Class created to make a 7-bit display. This class uses 2 classed named:
This class takes in a number from 0-9 and then prints the number out in 7-segment form.
import DrawSegment from './DrawSegment' const segment = new DrawSegment(1); //Selects that we want to draw 1 segment.drawLines(); // Actually draws the 1 in the console.
This class has been used in the DrawBigSegment and Temperature Class.