Knowledge Base

In SPLat MMi201 controllers with dialect 16 and later, the OBLCD is fully buffered. That means that instruction that display to the LCD actually write to a buffer memory in the processor. This happens very fast. After that the processor updates the LCD in the background. That takes longer but does not block your program. It is still advisable to not do LCD display instructions too often, as they still place an additional burden on the processor, especially numeric display instructions and very especially the OBLCD_fDispW instruction.

The following applies to all boards with dialects before 16 and to all versions of the MS12:

Transferring data and commands to the LCD module takes time.

The first instruction you send to the LCD will have no significant timing impact on your program. It simply gets passed to the LCD handler on the SPLat board, and from then on it is quietly sent to the LCD in the background. However, if your program tries to send a second instruction before the first one has been sent to the LCD, it will get held up, and will prevent the SPLat processor from doing anything else, until the first one is fully sent. Each subsequent instruction must wait for the previous one to be completed (this happens automatically).

There are several ways to manage this:

  1. Avoid redundant LCD updates. For example update readings once per second rather than 10 times per second. You can also skip the update if the value hasn’t changed. Update the changing number but not the fixed text.
  2. Update the LCD only when your program is not doing something very time critical.
  3. Study the WaitForLCD, OBLCD_GoIfBusy and OBLCD_GoIfIdle instructions so you only send stuff to the LCD when it is known to be idle.

Similarly, the OBLCD_fDispW instruction requires a lot of calculation, so if you do it too frequently your program will slow down significantly.

Custom controllers with OBLCD

Please consult SPLat Controls to establish if your controller has a fully buffered display driver.