User Tools

Site Tools




void csgPrintDot(u8 csgSlaveAdr, u8 dot0, u8 dot1, u8 dot2, u8 dot3, char *formatString[,arg0, …, argn])

csgSlaveAdr: Slave address of the CSG device
dot0: Dot 1st from the left (0=Off, 1=On)
dot1: Dot 2nd from the left (0=Off, 1=On)
dot2: Dot 3rd from the left (0=Off, 1=On)
dot3: Dot 4th from the left (0=Off, 1=On)

arg0,…,argn: An optional set of arguments to be used by format specifiers. |

Prints any or all of the 4 dots (dot0~dot3) on the CSG device on address csgSlaveAddress, along with a character string, formatStrng. formatString can contain format specifiers just like the printf function. See the printf function for more details.

int a = 123;
csgPrintDot(0, 1,0,0,0, "%04d", a);

int a = 123;
csgPrintDot(0, 0,0,1,0, "%04d", a);

CSG (7 Segment module)

The CSG library is used to display information on Comfile Technology's 7-segment display devices. Each CSG device must have a unique I2C slave address configured by a dipswitch on the back of the device.

Up to 4 CSG devices can be daisy-chained together to make a longer composite display. Each device must have a different slave address.

go MOACON home

moacon/csgprintdot/index.txt · Last modified: 2016/04/14 11:07 (external edit)