diff --git a/CoCo3.qsf b/CoCo3.qsf index 30b979b..60dfda4 100644 --- a/CoCo3.qsf +++ b/CoCo3.qsf @@ -317,7 +317,6 @@ set_global_assignment -name VHDL_FILE rtl/rom/coco_rom_8K.vhd set_global_assignment -name VHDL_FILE rtl/rom/coco_rom_16.vhd set_global_assignment -name SDC_FILE rtl/CoCo3FPGA.sdc -set_global_assignment -name ENABLE_SIGNALTAP ON set_global_assignment -name SIGNALTAP_FILE Video_Explorer.stp set_global_assignment -name SIGNALTAP_FILE rom_Exploror.stp1 set_global_assignment -name SOURCE_FILE rom_Exploror.stp1 @@ -333,7 +332,6 @@ set_global_assignment -name VERILOG_FILE rtl/mc6809glb/mc6809glb.v set_global_assignment -name SIGNALTAP_FILE Video_Explorer2.stp set_global_assignment -name SLD_NODE_CREATOR_ID 110 -section_id auto_signaltap_0 set_global_assignment -name SLD_NODE_ENTITY_NAME sld_signaltap -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_clk -to "emu:emu|coco3fpga:coco3|CLK_14" -section_id auto_signaltap_0 set_global_assignment -name SLD_NODE_PARAMETER_ASSIGNMENT "SLD_RAM_BLOCK_TYPE=AUTO" -section_id auto_signaltap_0 set_global_assignment -name SLD_NODE_PARAMETER_ASSIGNMENT "SLD_NODE_INFO=805334528" -section_id auto_signaltap_0 set_global_assignment -name SLD_NODE_PARAMETER_ASSIGNMENT "SLD_POWER_UP_TRIGGER=0" -section_id auto_signaltap_0 @@ -348,18 +346,12 @@ set_global_assignment -name SLD_NODE_PARAMETER_ASSIGNMENT "SLD_INCREMENTAL_ROUTI set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[0] -to auto_signaltap_0|gnd -section_id auto_signaltap_0 set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[3] -to auto_signaltap_0|gnd -section_id auto_signaltap_0 set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[5] -to auto_signaltap_0|vcc -section_id auto_signaltap_0 -set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[6] -to auto_signaltap_0|gnd -section_id auto_signaltap_0 set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[7] -to auto_signaltap_0|vcc -section_id auto_signaltap_0 set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[8] -to auto_signaltap_0|vcc -section_id auto_signaltap_0 set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[10] -to auto_signaltap_0|vcc -section_id auto_signaltap_0 -set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[12] -to auto_signaltap_0|vcc -section_id auto_signaltap_0 set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[14] -to auto_signaltap_0|vcc -section_id auto_signaltap_0 -set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[15] -to auto_signaltap_0|vcc -section_id auto_signaltap_0 -set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[16] -to auto_signaltap_0|vcc -section_id auto_signaltap_0 -set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[17] -to auto_signaltap_0|vcc -section_id auto_signaltap_0 set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[24] -to auto_signaltap_0|vcc -section_id auto_signaltap_0 set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[25] -to auto_signaltap_0|gnd -section_id auto_signaltap_0 -set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[28] -to auto_signaltap_0|vcc -section_id auto_signaltap_0 set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[31] -to auto_signaltap_0|gnd -section_id auto_signaltap_0 set_global_assignment -name SLD_NODE_PARAMETER_ASSIGNMENT "SLD_TRIGGER_LEVEL=3" -section_id auto_signaltap_0 set_global_assignment -name SLD_NODE_PARAMETER_ASSIGNMENT "SLD_SAMPLE_DEPTH=1024" -section_id auto_signaltap_0 @@ -369,51 +361,86 @@ set_global_assignment -name SLD_NODE_PARAMETER_ASSIGNMENT "SLD_COUNTER_PIPELINE= set_global_assignment -name SLD_NODE_PARAMETER_ASSIGNMENT "SLD_ADVANCED_TRIGGER_ENTITY=basic,1,basic,1,basic,1," -section_id auto_signaltap_0 set_global_assignment -name SLD_NODE_PARAMETER_ASSIGNMENT "SLD_TRIGGER_LEVEL_PIPELINE=1" -section_id auto_signaltap_0 set_global_assignment -name SLD_NODE_PARAMETER_ASSIGNMENT "SLD_ENABLE_ADVANCED_TRIGGER=0" -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[0] -to "emu:emu|coco3fpga:coco3|COCO3VIDEO_GIMEX:MISTER_COCOVID|HBLANKING" -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[1] -to "emu:emu|coco3fpga:coco3|COCO3VIDEO_GIMEX:MISTER_COCOVID|VBLANKING" -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[0] -to "emu:emu|coco3fpga:coco3|COCO3VIDEO_GIMEX:MISTER_COCOVID|HBLANKING" -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[1] -to "emu:emu|coco3fpga:coco3|COCO3VIDEO_GIMEX:MISTER_COCOVID|VBLANKING" -section_id auto_signaltap_0 set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[1] -to auto_signaltap_0|vcc -section_id auto_signaltap_0 -set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[2] -to auto_signaltap_0|gnd -section_id auto_signaltap_0 set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[4] -to auto_signaltap_0|gnd -section_id auto_signaltap_0 -set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[9] -to auto_signaltap_0|vcc -section_id auto_signaltap_0 set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[13] -to auto_signaltap_0|gnd -section_id auto_signaltap_0 -set_global_assignment -name SLD_NODE_PARAMETER_ASSIGNMENT "SLD_RAM_PIPELINE=2" -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[2] -to "emu:emu|coco3fpga:coco3|coco_mem_fetch:video_fetch|BUFF_ADD[0]" -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[3] -to "emu:emu|coco3fpga:coco3|coco_mem_fetch:video_fetch|BUFF_ADD[1]" -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[4] -to "emu:emu|coco3fpga:coco3|coco_mem_fetch:video_fetch|BUFF_ADD[2]" -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[5] -to "emu:emu|coco3fpga:coco3|coco_mem_fetch:video_fetch|BUFF_ADD[3]" -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[6] -to "emu:emu|coco3fpga:coco3|coco_mem_fetch:video_fetch|BUFF_ADD[4]" -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[7] -to "emu:emu|coco3fpga:coco3|coco_mem_fetch:video_fetch|BUFF_ADD[5]" -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[8] -to "emu:emu|coco3fpga:coco3|coco_mem_fetch:video_fetch|BUFF_ADD[6]" -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[9] -to "emu:emu|coco3fpga:coco3|coco_mem_fetch:video_fetch|BUFF_ADD[7]" -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[10] -to "emu:emu|coco3fpga:coco3|coco_mem_fetch:video_fetch|BUFF_ADD[8]" -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[11] -to "emu:emu|coco3fpga:coco3|coco_mem_fetch:video_fetch|HBORDER" -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[2] -to "emu:emu|coco3fpga:coco3|coco_mem_fetch:video_fetch|BUFF_ADD[0]" -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[3] -to "emu:emu|coco3fpga:coco3|coco_mem_fetch:video_fetch|BUFF_ADD[1]" -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[4] -to "emu:emu|coco3fpga:coco3|coco_mem_fetch:video_fetch|BUFF_ADD[2]" -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[5] -to "emu:emu|coco3fpga:coco3|coco_mem_fetch:video_fetch|BUFF_ADD[3]" -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[6] -to "emu:emu|coco3fpga:coco3|coco_mem_fetch:video_fetch|BUFF_ADD[4]" -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[7] -to "emu:emu|coco3fpga:coco3|coco_mem_fetch:video_fetch|BUFF_ADD[5]" -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[8] -to "emu:emu|coco3fpga:coco3|coco_mem_fetch:video_fetch|BUFF_ADD[6]" -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[9] -to "emu:emu|coco3fpga:coco3|coco_mem_fetch:video_fetch|BUFF_ADD[7]" -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[10] -to "emu:emu|coco3fpga:coco3|coco_mem_fetch:video_fetch|BUFF_ADD[8]" -section_id auto_signaltap_0 -set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[11] -to "emu:emu|coco3fpga:coco3|coco_mem_fetch:video_fetch|HBORDER" -section_id auto_signaltap_0 -set_global_assignment -name SLD_NODE_PARAMETER_ASSIGNMENT "SLD_DATA_BITS=12" -section_id auto_signaltap_0 -set_global_assignment -name SLD_NODE_PARAMETER_ASSIGNMENT "SLD_TRIGGER_BITS=12" -section_id auto_signaltap_0 -set_global_assignment -name SLD_NODE_PARAMETER_ASSIGNMENT "SLD_STORAGE_QUALIFIER_BITS=12" -section_id auto_signaltap_0 -set_global_assignment -name SLD_NODE_PARAMETER_ASSIGNMENT "SLD_INVERSION_MASK=000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000" -section_id auto_signaltap_0 -set_global_assignment -name SLD_NODE_PARAMETER_ASSIGNMENT "SLD_INVERSION_MASK_LENGTH=132" -section_id auto_signaltap_0 -set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[11] -to auto_signaltap_0|vcc -section_id auto_signaltap_0 -set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[18] -to auto_signaltap_0|vcc -section_id auto_signaltap_0 set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[19] -to auto_signaltap_0|gnd -section_id auto_signaltap_0 set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[20] -to auto_signaltap_0|gnd -section_id auto_signaltap_0 set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[21] -to auto_signaltap_0|gnd -section_id auto_signaltap_0 -set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[22] -to auto_signaltap_0|gnd -section_id auto_signaltap_0 set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[23] -to auto_signaltap_0|gnd -section_id auto_signaltap_0 set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[26] -to auto_signaltap_0|gnd -section_id auto_signaltap_0 set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[27] -to auto_signaltap_0|vcc -section_id auto_signaltap_0 -set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[29] -to auto_signaltap_0|gnd -section_id auto_signaltap_0 set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[30] -to auto_signaltap_0|gnd -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_clk -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|clk_sample" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[0] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|CASS_REWIND_RECORD" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[1] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|DTOA_CODE[0]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[2] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|DTOA_CODE[1]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[3] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|DTOA_CODE[2]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[4] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|DTOA_CODE[3]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[5] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|DTOA_CODE[4]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[6] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|DTOA_CODE[5]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[7] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|MOTOR_ON" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[8] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|buf_write" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[9] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|byte_clk" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[10] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[0]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[11] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[10]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[12] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[11]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[13] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[12]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[14] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[13]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[15] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[14]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[16] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[15]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[17] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[1]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[18] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[2]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[19] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[3]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[20] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[4]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[21] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[5]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[22] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[6]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[23] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[7]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[24] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[8]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_trigger_in[25] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[9]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[0] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|CASS_REWIND_RECORD" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[1] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|DTOA_CODE[0]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[2] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|DTOA_CODE[1]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[3] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|DTOA_CODE[2]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[4] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|DTOA_CODE[3]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[5] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|DTOA_CODE[4]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[6] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|DTOA_CODE[5]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[7] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|MOTOR_ON" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[8] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|buf_write" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[9] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|byte_clk" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[10] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[0]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[11] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[10]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[12] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[11]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[13] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[12]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[14] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[13]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[15] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[14]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[16] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[15]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[17] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[1]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[18] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[2]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[19] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[3]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[20] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[4]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[21] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[5]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[22] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[6]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[23] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[7]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[24] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[8]" -section_id auto_signaltap_0 +set_instance_assignment -name CONNECT_TO_SLD_NODE_ENTITY_PORT acq_data_in[25] -to "emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|incomming_reg[9]" -section_id auto_signaltap_0 +set_global_assignment -name SLD_NODE_PARAMETER_ASSIGNMENT "SLD_DATA_BITS=26" -section_id auto_signaltap_0 +set_global_assignment -name SLD_NODE_PARAMETER_ASSIGNMENT "SLD_TRIGGER_BITS=26" -section_id auto_signaltap_0 +set_global_assignment -name SLD_NODE_PARAMETER_ASSIGNMENT "SLD_STORAGE_QUALIFIER_BITS=26" -section_id auto_signaltap_0 +set_global_assignment -name SLD_NODE_PARAMETER_ASSIGNMENT "SLD_INVERSION_MASK=000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000" -section_id auto_signaltap_0 +set_global_assignment -name SLD_NODE_PARAMETER_ASSIGNMENT "SLD_INVERSION_MASK_LENGTH=258" -section_id auto_signaltap_0 +set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[2] -to auto_signaltap_0|vcc -section_id auto_signaltap_0 +set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[6] -to auto_signaltap_0|vcc -section_id auto_signaltap_0 +set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[9] -to auto_signaltap_0|gnd -section_id auto_signaltap_0 +set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[11] -to auto_signaltap_0|gnd -section_id auto_signaltap_0 +set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[12] -to auto_signaltap_0|gnd -section_id auto_signaltap_0 +set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[15] -to auto_signaltap_0|gnd -section_id auto_signaltap_0 +set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[16] -to auto_signaltap_0|gnd -section_id auto_signaltap_0 +set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[17] -to auto_signaltap_0|gnd -section_id auto_signaltap_0 +set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[18] -to auto_signaltap_0|gnd -section_id auto_signaltap_0 +set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[22] -to auto_signaltap_0|vcc -section_id auto_signaltap_0 +set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[28] -to auto_signaltap_0|gnd -section_id auto_signaltap_0 +set_instance_assignment -name POST_FIT_CONNECT_TO_SLD_NODE_ENTITY_PORT crc[29] -to auto_signaltap_0|vcc -section_id auto_signaltap_0 +set_global_assignment -name SLD_NODE_PARAMETER_ASSIGNMENT "SLD_RAM_PIPELINE=1" -section_id auto_signaltap_0 set_global_assignment -name SLD_FILE db/Video_Explorer2_auto_stripped.stp set_instance_assignment -name PARTITION_HIERARCHY root_partition -to | -section_id Top \ No newline at end of file diff --git a/CoCo3.sv b/CoCo3.sv index 2c61de4..c2034e8 100644 --- a/CoCo3.sv +++ b/CoCo3.sv @@ -213,8 +213,11 @@ localparam CONF_STR = { "F2,CAS,Load Cassette;", "TF,Stop & Rewind;", "OH,Monitor Tape Sound,No,Yes;", - "-;", + "S76,CAS,Save Cassette;", + "OE,Cass Rwd=0 / Rec=1,0,1;", + "-;", + "P1,Video Settings;", "P1-;", "P1-, -= Video Settings =-;", @@ -261,9 +264,9 @@ localparam CONF_STR = { // 0123456789ABCDEFGHIJKLMNOPQRSTUV 0123456789ABCDEFGHIJKLMNOPQRSTUV // -// R OOOO OOR OO TOOOOOOROOOOOO ooo oo oo +// R OOOO OOR OOOTOOOOOOROOOOOO ooo oo oo //F FF -//S SSSSSS +//S SSSSSS S //////////////////// CLOCKS /////////////////// @@ -315,8 +318,8 @@ assign CLK_VIDEO = clk_sys; wire [64:0] RTC; -// SD - 6 drives [4 fdc and 2 sdc] 512 size blocks [the wd1793 translates to a 256 byte sector size] -hps_io #(.CONF_STR(CONF_STR),.PS2DIV(2400), .VDNUM(6), .BLKSZ(2)) hps_io +// SD - 7 drives [4 fdc, 2 sdc and 1 cass_wr] 512 size blocks [the wd1793 translates to a 256 byte sector size] +hps_io #(.CONF_STR(CONF_STR),.PS2DIV(2400), .VDNUM(7), .BLKSZ(2)) hps_io ( .clk_sys(clk_sys), .HPS_BUS(HPS_BUS), @@ -373,21 +376,21 @@ hps_io #(.CONF_STR(CONF_STR),.PS2DIV(2400), .VDNUM(6), .BLKSZ(2)) hps_io ); // SD block level interface -wire [5:0] img_mounted; +wire [6:0] img_mounted; wire img_readonly; wire [63:0] img_size; -wire [31:0] sd_lba[6]; -wire [5:0] sd_blk_cnt[6]; +wire [31:0] sd_lba[7]; +wire [5:0] sd_blk_cnt[7]; -wire [5:0] sd_rd; -wire [5:0] sd_wr; -wire [5:0] sd_ack; +wire [6:0] sd_rd; +wire [6:0] sd_wr; +wire [6:0] sd_ack; // SD byte level access. Signals for 2-PORT altsyncram. wire [8:0] sd_buff_addr; wire [7:0] sd_buff_dout; -wire [7:0] sd_buff_din[6]; +wire [7:0] sd_buff_din[7]; wire sd_buff_wr; @@ -604,10 +607,11 @@ wire [1:0] Auto_Mode = status[41:40]; wire AMW_ACK; -wire cpu_speed = status[11]; +//wire cpu_speed = status[11]; wire [1:0] mpi = status[13:12] + 1'b1; -wire video=status[14]; +//wire video=status[14]; +wire CASS_REW_RECORD=status[14]; wire cartint=status[16]; wire sg4v6 = status[21]; @@ -655,7 +659,7 @@ begin end // Set bit 9 to swap serial ports... -wire [9:0] switch = { 2'b10,art,sg4v6,cartint,video,mpi,cpu_speed} ; +wire [9:0] switch = { 2'b10,art,sg4v6,cartint,CASS_REW_RECORD,mpi,1'b0}; wire reset = RESET | status[0] | buttons[1]; diff --git a/Video_Explorer2.stp b/Video_Explorer2.stp index 65b7816..4fb1154 100644 --- a/Video_Explorer2.stp +++ b/Video_Explorer2.stp @@ -1,11 +1,11 @@ - + - + - + @@ -15,110 +15,200 @@ - - - + + + - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + - 'emu:emu|coco3fpga:coco3|coco_mem_fetch:video_fetch|HBORDER' == rising edge + 'emu:emu|coco3fpga:coco3|Cassette_Write:CoCo3_Cassette_Write|MOTOR_ON' == rising edge @@ -137,8 +227,8 @@ - 111111111111 - 111111111111 + 11111111111111111111111111 + 11111111111111111111111111 @@ -156,10 +246,6 @@ - - 100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000001100000000001100100000001100010000001100110000001100001000001100101000001100011000001100111000001100000100001101100100001100110100001100001100001100101100001100011100001100111100001100000010001101100010001100110010001100001010001100101010001100011010001100111010001100000110001101100110001100110110001100001110001100101110001100011110001100111110001100000001001101100001001100110001001100001001001100101001001100011001001100111001001100000101001100100101001100010101001100110101001100001101001100101101001101011101001100000011001100100011001100010011001100110011001100001011001100101011001101011011001100000111001100100111001100100111001100010111001101110111001100101111001100011111001100111111001100000000101100100000101100010000101101110000101100101000101100101000101100011000101100111000101100000100101100100100101100010100101101110100101100101100101100011100101100111100101100000010101100100010101100010010101101110010101100101010101100011010101100111010101100000110101100100110101100010110101101110110101100101110101100011110101100111110101100000001101100100001101100010001101101110001101100101001101100011001101100111001101100000101101100100101101100010101101101110101101100101101101100011101101100111101101100000011101100100011101100010011101101110011101100101011101100011011101100111011101100000111101100100111101100010111101101110111101100101111101100011111101100111111101100000000011100100000011000010000011001110000011000101000011000011000011000111000011000000100011000100100011000010100011001110100011000101100011000011100011000111100011000000010011000100010011000010010011000110010011000001010011000101010011000011010011000111010011001000110011000010110011000110110011000001110011000101110011000011110011000111110011001000001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011000100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001011100100001010100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000100000000000 - 11111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111T1111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111 - @@ -169,13 +255,13 @@ + - - + + - diff --git a/files.qip b/files.qip index d275f1a..bff3037 100644 --- a/files.qip +++ b/files.qip @@ -17,6 +17,7 @@ set_global_assignment -name SYSTEMVERILOG_FILE rtl/coco3fpga.sv set_global_assignment -name VERILOG_FILE rtl/pll.v set_global_assignment -name VERILOG_FILE rtl/pll/pll_0002.v set_global_assignment -name VERILOG_FILE rtl/cassette.v +set_global_assignment -name SYSTEMVERILOG_FILE rtl/Cassette_Write.sv set_global_assignment -name VERILOG_FILE rtl/rtc.sv set_global_assignment -name VERILOG_FILE rtl/AMW.v set_global_assignment -name VERILOG_FILE rtl/square_gen.v diff --git a/rtl/Cassette_Write.sv b/rtl/Cassette_Write.sv new file mode 100644 index 0000000..db09a52 --- /dev/null +++ b/rtl/Cassette_Write.sv @@ -0,0 +1,533 @@ +//////////////////////////////////////////////////////////////////////////////// +// Project Name: CoCo3FPGA Version 5.x.x +// File Name: Cassette_Write.sv +// +// CoCo3 in an FPGA +// +//////////////////////////////////////////////////////////////////////////////// +// +//////////////////////////////////////////////////////////////////////////////// +// +// Color Computer 3 compatible system on a chip +// +// +// Copyright (c) 2008 Gary Becker (gary_l_becker@yahoo.com) +// +// All rights reserved +// +// Redistribution and use in source and synthezised forms, with or without +// modification, are permitted provided that the following conditions are met: +// +// Redistributions of source code must retain the above copyright notice, +// this list of conditions and the following disclaimer. +// +// Redistributions in synthesized form must reproduce the above copyright +// notice, this list of conditions and the following disclaimer in the +// documentation and/or other materials provided with the distribution. +// +// Neither the name of the author nor the names of other contributors may +// be used to endorse or promote products derived from this software without +// specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +// AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +// THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +// PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE +// LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +// CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF +// SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN +// CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) +// ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +// POSSIBILITY OF SUCH DAMAGE. +// +// Please report bugs to the author, but before you do so, please +// make sure that this is not a derivative work and that +// you have the latest version of this file. +// +// +//////////////////////////////////////////////////////////////////////////////// +// Stan Hodge +// +// Cassette_Write by Stan Hodge 03/18/24 +//////////////////////////////////////////////////////////////////////////////// + + +module Cassette_Write( + input RESET_N, + input CLK, + input CLK_1_78, + + input CASS_REWIND_RECORD, + input MOTOR_ON, + input [5:0] DTOA_CODE, + +// SD block level interface + + input img_mounted, // signaling that new image has been mounted + input img_readonly, // mounted as read only. valid only for active bit in img_mounted + input [63:0] img_size, // size of image in bytes. + + output [31:0] sd_lba, + output [5:0] sd_blk_cnt, // number of blocks-1, total size ((sd_blk_cnt+1)*(1<<(BLKSZ+7))) must be <= 16384! + output reg sd_rd, + output reg sd_wr, + input sd_ack, + +// SD byte level access. Signals for 2-PORT altsyncram. + input [8:0] sd_buff_addr, + input [7:0] sd_buff_dout, + output [7:0] sd_buff_din, + input sd_buff_wr + +); + +assign sd_blk_cnt = 6'd0; + + +// Create 16x sample clock for the 2400 Baud rate... +// ~26us based on 1.78Mhz [562 ns]- divide by 46.... +// Generate 1.78 Mhz [enable] GP clk +reg clk_sample; +reg [5:0] clk_sample_ctr; + +localparam Divide_Rate = 6'd45; + +always @ (negedge CLK or negedge RESET_N) +begin + if(!RESET_N) + begin + clk_sample <= 1'b0; + clk_sample_ctr <= 6'b000000; + end + else + begin + clk_sample <= 1'b0; + if (CLK_1_78) + begin + clk_sample_ctr <= clk_sample_ctr + 1'b1; + if (clk_sample_ctr == Divide_Rate) + begin + clk_sample <= 1'b1; + clk_sample_ctr <= 6'b000000; + end + end + end +end + +// Mounted SD Image [for the cass] + +reg drive_wp; +reg [31:0] drive_size; + +always @(negedge img_mounted) +begin + drive_wp <= img_readonly; + drive_size <= img_size[31:0]; //Size / 256 on [31:8] +end + + +// Byte Receiver + +reg [15:0] incomming_reg; + +reg [5:0] bit_time; +reg [2:0] bit_count; +reg wave_negative; + +localparam time_out = 6'h3f; +localparam wave_zero_level = 6'd32; +localparam bit_time_1 = 6'd21; +localparam sync = 15'b010_1010_1001_1110; // Pre shift $553C +localparam sync_proper = 8'h3C; +localparam leader = 8'hFF; +localparam pre_rollover = 9'h1FF; +localparam rollover = 9'h000; + +reg byte_clk; +reg look_for_sync; +reg flush_end; +reg sd_hold; +reg pre_roll; +reg [7:0] blk_type; + +wire [8:0] buf_address; +wire [7:0] buf_data_in; +wire [7:0] buf_data_out; +wire buf_write; + +reg [7:0] protocol_data_count; + +localparam st_beg0 = 4'd0; +localparam st_start = 4'd1; +localparam st_st1 = 4'd2; +localparam st_st2 = 4'd3; +localparam st_st3 = 4'd4; +localparam st_wr = 4'd5; +localparam st_wr1 = 4'd6; + +reg [3:0] st_state; +reg [3:0] state_stack; + +localparam p_sync = 3'd0; +localparam p_blk_type = 3'd1; +localparam p_len = 3'd2; +localparam p_dta = 3'd3; +localparam p_cksum = 3'd4; + +reg [2:0] p_state; + +localparam sd_wr_st = 2'd0; +localparam sd_wr_st1 = 2'd1; +localparam sd_wr_st2 = 2'd2; + +reg [1:0] sd_wr_state; + + +always @ (negedge CLK or negedge RESET_N) +begin + if(!RESET_N) + begin + buf_address <= 9'b000000000; + byte_clk <= 1'b0; + bit_count <= 3'b000; + incomming_reg <= 16'h0000; + bit_time <= 6'b000000; + wave_negative <= 1'b0; + look_for_sync <= 1'b1; + + buf_write <= 1'b0; + st_state <= st_beg0; + p_state <= p_sync; + flush_end <= 1'b0; + + sd_lba <= 32'd0; + sd_wr <= 1'b0; + sd_rd <= 1'b0; + + sd_wr_state <= sd_wr_st; + sd_hold <= 1'b0; + pre_roll <= 1'b0; + end + else + begin +// Synchronus Clears + if (!MOTOR_ON) + begin +// Receiver Resets + byte_clk <= 1'b0; + bit_count <= 3'b000; + incomming_reg <= 16'h0000; + bit_time <= 6'b000000; + wave_negative <= 1'b0; + look_for_sync <= 1'b1; + end + + if (!CASS_REWIND_RECORD) + begin +// Eject Tape + byte_clk <= 1'b0; + bit_count <= 3'b000; + incomming_reg <= 16'h0000; + bit_time <= 6'b000000; + wave_negative <= 1'b0; + look_for_sync <= 1'b1; + + st_state <= st_beg0; + p_state <= p_sync; + buf_write <= 1'b0; + flush_end <= 1'b0; + + sd_lba <= 32'd0; + sd_wr <= 1'b0; + sd_rd <= 1'b0; + + sd_wr_state <= sd_wr_st; + sd_hold <= 1'b0; + pre_roll <= 1'b0; + end + + byte_clk <= 1'b0; + +// 2400/1200 baud receiver + if (clk_sample) + begin + if (DTOA_CODE < wave_zero_level) + wave_negative <= 1'b1; + else + wave_negative <= 1'b0; + bit_time <= bit_time + 1'b1; + +// Zero crossing detect + if ((DTOA_CODE >= wave_zero_level) && wave_negative) + begin +// Initially we are not collecting the leader bytes just collecting them and +// waiting for the sync $$553C. The write to file stage will automatically +// write the 128 leader bytes befor we start transfering data. + if (!look_for_sync) + begin + bit_count <= bit_count + 1'b1; + if (bit_count == 3'b111) + byte_clk <= 1'b1; + end +// Shift + incomming_reg[15:1] <= incomming_reg[14:0]; + if (bit_time < bit_time_1) + incomming_reg[0] <= 1'b1; + else + begin + incomming_reg[0] <= 1'b0; + if (incomming_reg[14:0] == sync) + begin + look_for_sync <= 1'b0; + byte_clk <= 1'b1; + end + end + bit_time <= 6'b000000; + end + end + +// Normal clocking starts here + case(st_state) + + st_beg0: + begin +// When we start we write 128 bytes of leader to the buffer +// before we start with the protocol stuff + if (MOTOR_ON) + begin + buf_address <= 9'b000000000; + buf_data_in <= leader; + protocol_data_count <= 8'h7f; // We will use this to count the 128 bytes + + st_state <= st_start; + end + end + + st_start: + begin + state_stack <= st_start; // We come back here + st_state <= st_wr; // Write a byte + protocol_data_count <= protocol_data_count - 1'b1; + if (protocol_data_count == 8'h00) // 128 bytes + begin + st_state <= st_st1; // No, don't write any more - were done + end + end + + st_st1: + begin + if (byte_clk) + begin + case(p_state) + + p_sync: + begin + if (incomming_reg[7:0] == sync_proper) + begin + buf_data_in <= incomming_reg[7:0]; + state_stack <= st_st1; // We come back here + st_state <= st_wr; // Write a byte + p_state <= p_blk_type; + end + end + + p_blk_type: + begin + buf_data_in <= incomming_reg[7:0]; + blk_type <= incomming_reg[7:0]; + state_stack <= st_st1; // We come back here + st_state <= st_wr; // Write a byte + p_state <= p_len; + end + + p_len: + begin + buf_data_in <= incomming_reg[7:0]; + protocol_data_count <= incomming_reg[7:0]; + state_stack <= st_st1; // We come back here + st_state <= st_wr; // Write a byte + if (incomming_reg[7:0] == 8'h00) + p_state <= p_cksum; + else + p_state <= p_dta; + end + + p_dta: + begin + buf_data_in <= incomming_reg[7:0]; + protocol_data_count <= protocol_data_count - 1'b1; + state_stack <= st_st1; // We come back here + st_state <= st_wr; // Write a byte + p_state <= p_dta; + if (protocol_data_count == 8'h01) + p_state <= p_cksum; + end + + p_cksum: + begin + buf_data_in <= incomming_reg[7:0]; + look_for_sync <= 1'b1; + if (blk_type == 8'hff) + begin + flush_end <= 1'b1; + state_stack <= st_st1; // We come back here [close it] + end + else + state_stack <= st_st2; // We come back here [next block] + st_state <= st_wr; // Write a byte + p_state <= p_sync; + end + + default:; + endcase + end + end + + st_st2: + begin + buf_data_in <= leader; + if (blk_type == 8'h00) + protocol_data_count <= 8'h7f; // We will use this to count the 128 bytes + else + protocol_data_count <= 8'h01; // We will use this to count the 128 bytes + st_state <= st_start; // No, don't write any more - were done + end + + st_st3: + begin + state_stack <= st_st3; // We come back here + st_state <= st_wr; // Write a byte + protocol_data_count <= protocol_data_count - 1'b1; + if (protocol_data_count == 8'h00) // 128 bytes + begin + st_state <= st_st1; // No, don't write any more - were done + end + end + +// Perform the byte writes to the buffer +// This acts like a sub routine.... + st_wr: + begin + if (sd_hold) + begin + buf_write <= 1'b1; + st_state <= st_wr1; + end + end + + st_wr1: + begin + buf_address <= buf_address + 1'b1; + buf_write <= 1'b0; + st_state <= state_stack; + end + + default:; + endcase + +// Handle SD buf clear + case(sd_wr_state) + + sd_wr_st: + begin + if (buf_address == pre_rollover) + pre_roll <= 1'b1; // Stop writing to buffer + if ((buf_address == rollover) & pre_roll) // If buffer full - write it to SD + begin + pre_roll <= 1'b0; + + sd_wr <= 1'b1; + sd_wr_state <= sd_wr_st1; + + sd_hold <= 1'b1; // Hold writes + end + if (flush_end) // Write remainder of the buffer at th end... + begin + sd_wr <= 1'b1; + flush_end <= 1'b0; + sd_hold <= 1'b1; + sd_wr_state <= sd_wr_st1; + end + end + + sd_wr_st1: + begin + if (sd_ack) + begin + sd_wr <= 1'b0; + sd_wr_state <= sd_wr_st2; + end + end + + sd_wr_st2: + begin + if (!sd_ack) + begin + sd_hold <= 1'b0; + sd_lba <= sd_lba + 1'b1; + sd_wr_state <= sd_wr_st; + end + end + + default:; + endcase + + end +end + + +cass_dpram cas_wr_buff +( + .clock(CLK), + .address_a(sd_buff_addr), + .data_a(sd_buff_dout), + .wren_a(sd_buff_wr), + .q_a(sd_buff_din), + + .address_b(buf_address), + .data_b(buf_data_in), + .wren_b(buf_write), + .q_b(buf_data_out) +); + + +endmodule + + +module cass_dpram +( + input clock, + + input [8:0] address_a, + input [7:0] data_a, + input wren_a, + output reg [7:0] q_a, + + input [8:0] address_b, + input [7:0] data_b, + input wren_b, + output reg [7:0] q_b +); + +logic [7:0] ram[0:511]; + +always_ff@(posedge clock) begin + if(wren_a) begin + ram[address_a] <= data_a; + q_a <= data_a; + end else begin + q_a <= ram[address_a]; + end +end + +always_ff@(posedge clock) begin + if(wren_b) begin + ram[address_b] <= data_b; + q_b <= data_b; + end else begin + q_b <= ram[address_b]; + end +end + +endmodule diff --git a/rtl/coco3fpga.sv b/rtl/coco3fpga.sv index bf945e8..45fa79d 100644 --- a/rtl/coco3fpga.sv +++ b/rtl/coco3fpga.sv @@ -146,21 +146,21 @@ input ioctl_wr, input [15:0] ioctl_index, // SD block level interface -input [5:0] img_mounted, // signaling that new image has been mounted +input [6:0] img_mounted, // signaling that new image has been mounted input img_readonly, // mounted as read only. valid only for active bit in img_mounted input [63:0] img_size, // size of image in bytes. 1MB MAX! -output [31:0] sd_lba[6], -output [5:0] sd_blk_cnt[6], // number of blocks-1, total size ((sd_blk_cnt+1)*(1<<(BLKSZ+7))) must be <= 16384! +output [31:0] sd_lba[7], +output [5:0] sd_blk_cnt[7], // number of blocks-1, total size ((sd_blk_cnt+1)*(1<<(BLKSZ+7))) must be <= 16384! -output reg [5:0] sd_rd, -output reg [5:0] sd_wr, -input [5:0] sd_ack, +output reg [6:0] sd_rd, +output reg [6:0] sd_wr, +input [6:0] sd_ack, // SD byte level access. Signals for 2-PORT altsyncram. input [8:0] sd_buff_addr, input [7:0] sd_buff_dout, -output [7:0] sd_buff_din[6], +output [7:0] sd_buff_din[7], input sd_buff_wr, // GPIO @@ -171,7 +171,7 @@ input EE_N, input PHASE, output [31:0] PROBE, -// Cassette +// Cassette Input linkage output clk_Q_out, output cas_relay, input casdout, @@ -3987,4 +3987,32 @@ glb6551 RS232( .DSR(UART_DSR) ); +Cassette_Write CoCo3_Cassette_Write( + .RESET_N(RESET_N), + .CLK(clk_sys), + .CLK_1_78(clk_1_78), + + .CASS_REWIND_RECORD(SWITCH[3]), + .MOTOR_ON(CAS_MTR), + .DTOA_CODE(DTOA_CODE), + +// SD block level interface + .img_mounted(img_mounted[6]), // signaling that new image has been mounted + .img_readonly(img_readonly), // mounted as read only. valid only for active bit in img_mounted + .img_size(img_size), // size of image in bytes. + + .sd_lba(sd_lba[6]), + .sd_blk_cnt(sd_blk_cnt[6]), // number of blocks-1, total size ((sd_blk_cnt+1)*(1<<(BLKSZ+7))) must be <= 16384! + .sd_rd(sd_rd[6]), + .sd_wr(sd_wr[6]), + .sd_ack(sd_ack[6]), + +// SD byte level access. Signals for 2-PORT altsyncram. + .sd_buff_addr(sd_buff_addr), + .sd_buff_dout(sd_buff_dout), + .sd_buff_din(sd_buff_din[6]), + .sd_buff_wr(sd_buff_wr) +); + + endmodule