Landfall

Annotated pkg/devices/lib/lcd/include/lcd-jz4740-panel.h

0:89a1bc19c1fc
2018-05-13 Paul Boddie Added device libraries and programs, configuration files and examples. Also added an installation script and copyright and licensing information.
paul@0 1
/*
paul@0 2
 * LCD panel definitions for the JZ4740 and related SoCs.
paul@0 3
 *
paul@0 4
 * (c) 2018 Paul Boddie <paul@boddie.org.uk>
paul@0 5
 *
paul@0 6
 * This program is free software; you can redistribute it and/or
paul@0 7
 * modify it under the terms of the GNU General Public License as
paul@0 8
 * published by the Free Software Foundation; either version 2 of
paul@0 9
 * the License, or (at your option) any later version.
paul@0 10
 *
paul@0 11
 * This program is distributed in the hope that it will be useful,
paul@0 12
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
paul@0 13
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
paul@0 14
 * GNU General Public License for more details.
paul@0 15
 *
paul@0 16
 * You should have received a copy of the GNU General Public License
paul@0 17
 * along with this program; if not, write to the Free Software
paul@0 18
 * Foundation, Inc., 51 Franklin Street, Fifth Floor,
paul@0 19
 * Boston, MA  02110-1301, USA
paul@0 20
 */
paul@0 21
paul@0 22
#pragma once
paul@0 23
paul@0 24
#include <stdint.h>
paul@0 25
paul@0 26
/* Panel configuration details. */
paul@0 27
paul@0 28
struct Jz4740_lcd_panel
paul@0 29
{
paul@0 30
  uint32_t config;                    /* LCD configuration */
paul@0 31
paul@0 32
  /* Display dimensions in pixels. */
paul@0 33
paul@0 34
  uint32_t width, height;
paul@0 35
  uint32_t bpp;                       /* bits per pixel */
paul@0 36
paul@0 37
  /* Display timing information. */
paul@0 38
paul@0 39
  uint32_t frame_rate;                /* frame clock frequency (Hz) */
paul@0 40
paul@0 41
  /* Horizontal and vertical sync widths. */
paul@0 42
paul@0 43
  uint32_t hsync;                     /* in pixel clock periods */
paul@0 44
  uint32_t vsync;                     /* in line periods */
paul@0 45
paul@0 46
  /* Inactive line region sizes before/after line data (in pixel clock periods). */
paul@0 47
paul@0 48
  uint32_t line_start, line_end;      /* similar to horizontal back porch, front porch */
paul@0 49
paul@0 50
  /* Inactive frame region sizes before/after frame data (in line periods). */
paul@0 51
paul@0 52
  uint32_t frame_start, frame_end;    /* vertical back porch, front porch */
paul@0 53
};