Author Topic: SPI Communication Start Byte  (Read 2497 times)

neiljhs

  • Newbie
  • *
  • Posts: 4
  • Karma: 0
    • View Profile
SPI Communication Start Byte
« on: July 28, 2015, 04:37:37 PM »
Hello,

I am working with New Haven's NHD-0220CW-AG3 display and looking for clarification with regard to the "start byte". In order to help keep this post generalizable/helpful to as many people as possible, this should be directly applicable to any of New Haven's OLED's that use the US2066 driver. The data sheet says that:

Quote
To transfer several bytes continuously without changing D/C bit and R/W bit, start byte transfer is needed only at first starting time. Namely, after first start byte is transferred, real data can be transferred succeeding.

What I understand from that is that after the initial 3-byte long package establishing command or data mode (one start byte followed by two command/data bytes), that you can just send 2-byte long packages provided that you stick with the same mode of transmission (without the start byte). I am wondering, however, if it would also be valid to keep sending 3-byte long packages even when not switching from command to data (or vice-versa).

For example if I wanted to 'clear the display' and then 'return home' are both of these transmissions valid ways of instructing the screen to do that:

[0xF8][0x80][0x00]  [0xC0][0x00]
[0xF8][0x80][0x00]  [0xF8][0xC0][0x00]

Thank you in advance

neiljhs

  • Newbie
  • *
  • Posts: 4
  • Karma: 0
    • View Profile
Re: SPI Communication Start Byte
« Reply #1 on: July 28, 2015, 07:22:18 PM »
For follow-up clarification I've attached an image found in the US2066 driver datasheet (on page 11). My original question revolves around whether I can associate a 'start byte' with every command/data sequence.

A follow up, second question I have is how long the 'wait' drawn on the attached image should last? What is a minimum, safe delay time before transmitting the next command/data sequence?

Saurabh_B

  • Administrator
  • Hero Member
  • *****
  • Posts: 356
  • Karma: 10
    • View Profile
Re: SPI Communication Start Byte
« Reply #2 on: July 30, 2015, 11:05:12 AM »
You should be able to send continuous commands as well.

The minimum wait time should be about 40 ns. For the clock rise time, and the clock rise time plus hold time.

neiljhs

  • Newbie
  • *
  • Posts: 4
  • Karma: 0
    • View Profile
Re: SPI Communication Start Byte
« Reply #3 on: August 04, 2015, 09:13:20 PM »
Sarah,

Thank you for the prompt response! Just looking to confirm I'm interpreting what you wrote correctly: you are saying that it is okay to send start bytes with each/all command/data messages?

Saurabh_B

  • Administrator
  • Hero Member
  • *****
  • Posts: 356
  • Karma: 10
    • View Profile
Re: SPI Communication Start Byte
« Reply #4 on: August 05, 2015, 08:18:51 AM »
According to the datasheet you should be able to. The start byte dictates whether the following chain of instructions are commands or not.

 

NHD-4.3-480272EF-ATXL#-CTP How to Start?:

Started by npnBoard TFTs

Replies: 1
Views: 2842
Last post May 06, 2014, 12:06:15 PM
by Michael_L