Minor fixes.

This commit is contained in:
marqs 2016-12-27 11:16:08 +02:00
parent 03bf4c2c9a
commit 79f215d41e
2 changed files with 10 additions and 5 deletions

View File

@ -153,10 +153,10 @@ assign pclk_out_3x_h4x = pclk_3x_h4x;
assign pclk_out_3x_h5x = pclk_3x_h5x;
//Scanline generation
function [8:0] apply_scanlines;
function [7:0] apply_scanlines;
input [1:0] mode;
input [8:0] data;
input [8:0] str;
input [7:0] data;
input [7:0] str;
input [1:0] actid;
input [1:0] lineid;
input pixid;
@ -174,9 +174,9 @@ function [8:0] apply_scanlines;
endfunction
//Border masking
function [8:0] apply_mask;
function [7:0] apply_mask;
input enable;
input [8:0] data;
input [7:0] data;
input [11:0] hoffset;
input [11:0] hstart;
input [11:0] hend;

View File

@ -28,6 +28,7 @@
#define DEFAULT_PRE_COAST 1
#define DEFAULT_POST_COAST 0
#define DEFAULT_SAMPLER_PHASE 16
#define DEFAULT_SYNC_LPF 3
#define DEFAULT_SYNC_VTH 11
#define DEFAULT_FINE_GAIN 26
#define DEFAULT_FINE_OFFSET 0x80
@ -45,10 +46,12 @@ const avconfig_t tc_default = {
.sync_vth = DEFAULT_SYNC_VTH,
.linelen_tol = DEFAULT_LINELEN_TOL,
.vsync_thold = DEFAULT_VSYNC_THOLD,
.sync_lpf = DEFAULT_SYNC_LPF,
.pre_coast = DEFAULT_PRE_COAST,
.post_coast = DEFAULT_POST_COAST,
#ifdef DIY_AUDIO
.audio_dw_sampl = DEFAULT_ON,
.tx_mode = TX_HDMI,
#endif
.col = {
.r_f_gain = DEFAULT_FINE_GAIN,
@ -63,7 +66,9 @@ const avconfig_t tc_default = {
int set_default_avconfig()
{
memcpy(&tc, &tc_default, sizeof(avconfig_t));
#ifndef DIY_AUDIO
tc.tx_mode = !!(IORD_ALTERA_AVALON_PIO_DATA(PIO_1_BASE) & HDMITX_MODE_MASK);
#endif
memcpy(video_modes, video_modes_def, video_mode_cnt*sizeof(mode_data_t));
update_cur_vm = 1;