--- taqoz.spin2.orig 2021-09-16 08:15:48.946156999 +1000 +++ taqoz.spin2 2021-09-16 10:46:34.805354426 +1000 @@ -1,11 +1,11 @@ CON -_clkfreq = 200_000_000 -_xinfreq = 20_000_000 -XIN = _xinfreq +_xtlfreq = 25_000_000 +_clkfreq = 180_000_000 +XIN = _xtlfreq xmode = 3 ' 2 for xtal, 3 for osc' CPUHZ = _clkfreq '200_000_000 ' desired CPU clock frequency' -baud_rate = 921600 ' console baud rate - timing value calculated at startup' -morestops = 2 ' extra stop bits for USB or terminal esp. at higher baud rates +baud_rate = 115200 ' console baud rate - timing value calculated at startup' +morestops = 0 ' extra stop bits for USB or terminal esp. at higher baud rates bootms = 1000 '#######################################################################' @@ -14,8 +14,8 @@ CON { -_XTALFREQ = 20_000_000 ' crystal frequency - _XDIV = 4 '\ '\ crystal divider to give 5.0MHz +_XTALFREQ = 25_000_000 ' crystal frequency + _XDIV = 5 '\ '\ crystal divider to give 5.0MHz _XMUL = 72 '| 180MHz '| crystal / div * mul to give 360MHz _XDIVP = 2 '/ '/ crystal / div * mul /divp to give 180MHz _XOSC = %10 'OSC ' %00=OFF, %01=OSC, %10=15pF, %11=30pF @@ -47,7 +47,7 @@ -baudval = (cpuhz/baud_rate)<<16 +baudval = (CPUHZ/baud_rate)<<16 @@ -232,7 +232,7 @@ _CLKCFG long CLKCFG '$012C_B3FF $014CB3FC ' ' *** SERIAL/VGA/KEYBOARD *** ' -_BAUD long baud_rate +_baud long baud_rate _VGACFG long $03020100 '$33323130 ' VGA RGBH pins on P48..P52 (set long to 0 to disable vga) long $04 ' VSYNCH' _VGAINIT long @vgainit ' VGA code ' @@ -491,7 +491,7 @@ { DBINIT rdlong hr0,#@_CPUHZ - rdlong hr1,#@_BAUD + rdlong hr1,#@_baud qdiv hr0,hr1 getqx hr0 shl hr0,#16 @@ -570,7 +570,7 @@ orgh taqoz_version long 2_8 -taqoz_time long 210401_1230 +taqoz_time long 210916_1045 taqoz_name byte "CHIP" ' use exactly 4 characters = 1 long' { @@ -739,7 +739,7 @@ res 2 ' word count mrd res 4 ' memory read' athen res 4 -endreg res 0 +endreg res 1 ' defs for TAQOZ variables ' '#######################################################################' ' kernel.p2a @@ -3310,15 +3310,15 @@ InitSerial drvh #tx_pin ' force high ' wrpin #$7C,#tx_pin ' asynchronous transmit wrpin #$3E,#rx_pin ' asynchronous receive -'SETBAUD ' calculate baud timing at runtime' + ' SETBAUD ' calculate baud timing at runtime' rdlong r0,#@_CPUHZ ' read from config table in low hub' - rdlong r1,#@_BAUD + rdlong r1,#@_baud qdiv r0,r1 ' cpuhz/baud' getqx r0 shl r0,#16 ' (cpuhz/baud)<<16' add r0,#7 ' add 8 data bits wxpin r0,#rx_pin ' write config baud ticks and 8 data - add r0,#morestops ' ADD 2 MORE STOP BITS FOR TX 191120 ' + add r0,#morestops ' ADD MORE STOP BITS FOR TX 191120 ' wxpin r0,#tx_pin ' baud 8 data wypin #$0D,#tx_pin ' kick off transmit empty flag' @@ -4071,7 +4071,7 @@ PRTVER word PRTSTR '12345678901234567890123456789012345678901234567890123456789011' - byte " Parallax P2 *TAQOZ RELOADED sIDE* V",0 + byte " Parallax P2 *TAQOZ RELOADED SIDE* V",0 word _WORD,@taqoz_version,FETCH word PRTAST byte "#~#.# '",0