Can't get SPI to communicate with PT6959 IC - Fez Cerberus

Hello, I’ve been on these boards this past few days regarding issues to do with my Fez Cerberus board, all of which have now been sorted, my next obstacle is trying to get SPI code which was previously wrote on my Fez Raptor to work with my Cerberus, basically I’ve tested the output of the SPI1_CLK and SPI1_MOSI pins of socket 6 and I can see with my logic probe that these do indeed pulse when MySPI.Write method is called. So my question is, does the SPI configuration differ slightly for the Cerberus board, obviously I know its using a different socket but I’m at a dead end here, below is my config code as well as link to the datasheet for PT6959

SPI.Configuration DeviceConfigA = new SPI.Configuration(Utility.GetSocketPin(6, 3), false, 1, 1, true, true, 1000, SPI.SPI_module.SPI1);
SPI MySPI = new SPI(DeviceConfigA);

You should be able to use the same configuration. How did you solved your Cerberus issue?

I didnt solve it, I had to buy another board

Figured it out there’s some initialization which needs to be done for PT6959 prior to any write operations, below is the code if it should help anyone in future whose using this IC


var cmd1 = new byte[1] { 0x02 }; // command 1: Disply mode setting
var cmd2 = new byte[1] { 0xC0 }; // command 2 = data setting command
var cmd3_Clear = new byte[15] { 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 };
var cmd4 = new byte[1] { 0xF1 }; // Brightness

//Delay for initial setup
Thread.Sleep(100);

MySPI.Write(cmd2);
MySPI.Write(cmd3_Clear);
MySPI.Write(cmd1);
MySPI.Write(cmd4);
1 Like

@ chillydk147 - Excellent. :clap:

I would share the driver for that IC on codeshare when it is done, so others can benefit.

1 Like