Home » RBC Forums » General Discussion » Debugging a SBC V2-004 (No serial output)
|
Re: Debugging a SBC V2-004 [message #8819 is a reply to message #8817] |
Fri, 09 July 2021 08:56   |
lynchaj
Messages: 1080 Registered: June 2016
|
Senior Member |
|
|
Oy, serial ports always causing problems!
skip the pin numbers for a minute, you need this connection whatever the pin numbers are:
RX -> TX
TX -> RX
RTS -> CTS
CTS -> RTS
GND -> GND
Do you have a logic probe or oscilloscope? put it on the TTL TX line coming out of the UART and press reset. You should see activity on that line as the characters stream out for the initialization screen. You really only need TX -> RX and GND -> GND working initially on your serial port. Try getting those connected properly first. 2 line serial is great for debugging. You can add the other signals later.
Also, have you checked VCC, GND, clock, reset and all the other basic connections? Normally before I insert any ICs I go through and make sure the basics are present and accounted for to ensure a good chance of working. Check the jumpers against the schematic to ensure they are doing what you intend for them to do.
I thought I read somewhere you should be hearing a start up beep on the SBC V2-004. Did you burn the right version of ROMWBW to your Flash chip? Are the jumpers configured correctly for that particular Flash chip?
Good luck! Andrew Lynch
BTW, nice looking board! Congratulations for getting this far. You are very close now
[Updated on: Fri, 09 July 2021 08:59] Report message to a moderator
|
|
|
|
Re: Debugging a SBC V2-004 [message #8830 is a reply to message #8817] |
Sat, 10 July 2021 10:41   |
edzard
Messages: 64 Registered: August 2019
|
Member |
|
|
Hello Guys,
Thanks for helping me out, it's really appreciated!
I've checked al the IC's for the right voltage. Everyone gets 5 Volts.
The Oscillators are working at 4 Mhz and 1.84 Mhz (confirmed by the oscilloscope.
The little one (X1) gives half of the frequency (according to the oscilloscope) but I'm pretty sure that the value is correct.
I noticed the following:
- Al IC's close tot the bus (74LS244/245/243/32/08 etc are getting warm
- Other IC's (ROM/RAM/CPU etc) are cold
- LED stays red all the time
I changed the ROM to a AT27C080 to be consistent with the design.
I programmed the ROM with ROMWBW version v2.9.1 (not the newest to be sure that this is not the problem).
I used the (standard) file SBC_std.rom which comes with the distribution.
Checking pin 7 (TX) of the MAX323 gives no signal ( I see some spikes but no data blocks) when resetting the system). But maybe I'm doing something wrong with my Rigol.
I connected the serial port with only 2 wires (5 -> 2 and 9 -> 5).
I found in the Errata the following message:
Version V - CPU oscillator may not work due to incorrectly placed pull up resistor. A 1k resistor needs to be added between pin 12 and pin 14 of U26 74LS06.
So I placed this resistor on the back of the PCB. Not sure if this is (really) necessary.
Jumpers are as follows
K1=1/2
K6=1/2
K7=1/2
K8=1/2
K9=1/2
K10=1/2
K11=1/2
K12=1/2
K13=2/3
What's strange is that I have no output at all on the screen.
I always wished something like this to happen because al my projects (Zeta V2, easyz80, RC2014, XI8088 worked instantly. Almost boring. Now I'm not so sure anymore...
Thanks again!
Kind regards,
Edzard
[Updated on: Sat, 10 July 2021 10:44] Report message to a moderator
|
|
|
Re: Debugging a SBC V2-004 [message #8831 is a reply to message #8830] |
Sat, 10 July 2021 12:27   |
lynchaj
Messages: 1080 Registered: June 2016
|
Senior Member |
|
|
Hi Edzard,
Check for output on pin 11 of the UART or pin 10 of the MAX232. That's the TTL level UART output. You should see a brief stream of activity on that pin if it is booting the ROM after you press reset. Use your logic probe and you should see bits twiddling as the characters go by
Thanks, Andrew Lynch
PS, if that doesn't work it means your system is not booting. You need to roll back to a minimum build and pull everything not absolutely necessary out of the board sockets. Also burn a new ROM with jploop in it and start from the beginning. You need to see if the CPU is reading the ROM by looking for activity on the RD# line and also the CS_ROM# line. You can pull about half the chips out and still boot a minimum system. You don't need the UART or the PPI at all or the RAM. Just CPU, clock, ROM, & some glue logic. This is the fun part...
[Updated on: Sat, 10 July 2021 12:32] Report message to a moderator
|
|
|
|
|
|
|
|
|
|
|
Re: Debugging a SBC V2-004 [message #8852 is a reply to message #8817] |
Wed, 14 July 2021 11:42   |
edzard
Messages: 64 Registered: August 2019
|
Member |
|
|
Hello Andrew,
The above output is from the (new build) minimal system, as discussed previous.
I was pleased with this outcome too. So I guess I'll continue (too!) with this second board..:)
I forgot my first (defect) board at home so I couldn't measure on that one (scope/logic analyzer are at work).
I will definitely check the max232 output. For the capacitors I used tantal ones. I think I installed them correctly although my eyesight hasn't been what it used to be..and they are small too.
Thanks,
Best regards,
Edzard
[Updated on: Wed, 14 July 2021 11:43] Report message to a moderator
|
|
|
|
|
|
Re: Debugging a SBC V2-004 [message #8859 is a reply to message #8858] |
Sat, 17 July 2021 04:39   |
lynchaj
Messages: 1080 Registered: June 2016
|
Senior Member |
|
|
Hi
Whatever program you decide to use the function is very similar; to send a constant stream of repeating data to the UART so you can track down the chain of devices which have to work to produce serial output. ROM -> CPU -> glue logic -> UART -> MAX232 -> transmitting serial port -> receiving serial port
Here is the source code listing for scream.asm assembles with TASM. Not a great program but reliably does the job. It will tell you if you have basic UART functionality which is helpful
; UART 16C550 SERIAL
UART0: .EQU $68 ; DATA IN/OUT
UART1: .EQU $69 ; CHECK RX
UART2: .EQU $6A ; INTERRUPTS
UART3: .EQU $6B ; LINE CONTROL
UART4: .EQU $6C ; MODEM CONTROL
UART5: .EQU $6D ; LINE STATUS
UART6: .EQU $6E ; MODEM STATUS
UART7: .EQU $6F ; SCRATCH REG.
.ORG $0000
;*********************************************************** *******
; INIT_UART ;
; Function....: Init serial port 8250, 16C450, OR 16C550 ;
; 9600 Baud, 8 bit, 1 stopbit, 0 parity ;
; Output......: ;
; call........: PAUSE test 2 Feb 2007 ;
;*********************************************************** *******
INIT_UART: LD A,$AA
OUT (UART7),A
IN A,(UART7)
CP $AA ; TEST IF YOU COULD STORE AA
JP NZ,INITUART_FAIL ; IF NOT, THE UART CAN'T BE FOUND
LD A,$55
OUT (UART7),A ;
IN A,(UART7)
CP $55 ;
JP NZ,INITUART_FAIL
LD A,$01
JP UART_OK
INITUART_FAIL: ; Handle if initialize UART fails
LD A,1
HALT
UART_OK:
LD A,$80
OUT (UART3),A ; SET DLAB FLAG
LD A,12 ; = 1,843,200 / ( 16 x 9600 
OUT (UART0),A ; Set BAUD rate til 9600
LD A,$00
OUT (UART1),A ; Set BAUD rate til 9600
LD A,$03
OUT (UART3),A ; Set 8 bit data, 1 stopbit
MAIN:
LD A,$00 ; SELECT FIRST SERIAL PORT
LD B,$30 ; LOAD "0" CHARACTER TO PRINT IN REGISTER B
TX_BUSYLP: IN A,(UART5) ; READ Line Status Register
BIT 5,A ; TEST IF UART IS READY TO SEND
JP Z,TX_BUSYLP ; IF NOT REPEAT
LD A,B
OUT (UART0),A ; THEN WRITE THE CHAR TO UART
JP MAIN ; REPEAT FOREVER
.END
|
|
|
|
|
|
Re: Debugging a SBC V2-004 [message #8864 is a reply to message #8862] |
Sat, 17 July 2021 10:02   |
norwestrzh
Messages: 196 Registered: November 2015
|
Senior Member |
|
|
Here's the source for SPEW. I believe that I used this version with the S100 group's serial card? (Z8530 @ 38.4k baud) Very vanilla Z80 code ... ought to assemble with just about any assembler? No calls, so stack not needed.
;
; spew for the S100 group Z80
;
lf equ 10
cr equ 13
past equ 0a0h
pbst equ 0a1h
pbdt equ 0a3h
;
org 0f000h
;
start: LD C,past
LD B,14
LD HL,sinit
OTIR
LD C,pbst
LD B,14
LD HL,sinit
OTIR
JR loop
sinit: db 4,44h
db 3,0c1h
db 5,0eah
db 11,56h
db 12,2
db 13,0
db 14,1
db 15,0
loop: LD C,1FH
cinc: INC C
stck1: IN A,(pbst)
AND 4
JR Z,stck1
LD A,C
OUT (pbdt),A
LD A,C
CP 7FH
JR C,cinc
stck2: IN A,(pbst)
AND 4
JR Z,stck2
LD A,cr
OUT (pbdt),A
stck3: IN A,(pbst)
AND 4
JR Z,stck3
LD A,lf
OUT (pbdt),A
JR loop
end
[Updated on: Sat, 17 July 2021 10:03] Report message to a moderator
|
|
|
|
|
|
Re: Debugging a SBC V2-004 [message #8876 is a reply to message #8875] |
Tue, 20 July 2021 08:47   |
lynchaj
Messages: 1080 Registered: June 2016
|
Senior Member |
|
|
Hi Edzard, this is really good news. Time to use the scream program so you can determine what is happening to the serial character stream. You should be either 9600, n, 8, 1 or 38400, n, 8, 1 comm parameters. Scream or the other one will give you an idea of if problem is consistent (stuck bit) or some random corruption. Compare the bit pattern of what's making it to the screen vs. what is being sent by the program. Scream should give you a consistent string of characters. They may be wrong (other than ASCII 30 '0') but it should be the same character repeating. Good luck!
Thanks, Andrew Lynch
[Updated on: Tue, 20 July 2021 08:47] Report message to a moderator
|
|
|
|
|
|
Re: Debugging a SBC V2-004 [message #8890 is a reply to message #8885] |
Thu, 22 July 2021 11:24   |
coredump
Messages: 33 Registered: January 2020 Location: Germany
|
Member |
|
|
edzard wrote on Wed, 21 July 2021 23:49Hello Detlef,
Both CPU's are bought through Mouser.
Hello Edzard,
I clearly have to apologize.
It did not even come into my mind that it might be possible that those Z80 CPUs in DIP package are still manufactured.
So I have simply taken the wrong train.
Interestingly, the requirements regarding the voltages of the levels on the clock line are identical in the datasheet for NMOS and CMOS Z80.
(<=0.45V Low, >= VCC-0.6V High, the later maybe not exactly met by a 74LS74 output),
but the maximum allowed rise/fall time for the clock signal is 30ns for the 4MHz CPU, 10ns for the 10MHz CPU.
Not that I think the problem will be here, but maybe next time You have the oscilloscope 'on' the board, You may want to check for the levels and the rise/fall times, just for Your (and our) curiosity.
Best Regards
Detlef
|
|
|
|
|
|
|
Re: Debugging a SBC V2-004 [message #8966 is a reply to message #8910] |
Fri, 06 August 2021 12:42   |
edzard
Messages: 64 Registered: August 2019
|
Member |
|
|
Hello All,
I started debugging again. I changed the UART and MAX 232 butting nothing changed.
I burned 3 EPROMS: Beep (Phil), Spew (Roger) and Scream (Andrew).
I didn't have TASM for Spew and Scream at hand so I assembled them with RASM and burned them in a EPROM.
No error's, but both don't give any output. So I must be doing something wrong!
The "Beep" EPROM does give output (garbage on my screen) and (a decent) sound.

Ohh, and yes, the label gets black if you put the EPROM the other way around..
Thanks to the tips on the Zif thread I packed each ROM onto a DIP..

Then I connected most of the UART and Max 232 with my logic analyzer.

Output of the channels when connecting Power.


Best regards,
Edzard
-
Attachment: ROM1.jpg
(Size: 147.88KB, Downloaded 731 times)
-
Attachment: ROM2.jpg
(Size: 158.50KB, Downloaded 739 times)
-
Attachment: Logic.jpg
(Size: 166.95KB, Downloaded 745 times)
-
Attachment: Power ON.PNG
(Size: 235.12KB, Downloaded 744 times)
-
Attachment: Power ON-2.PNG
(Size: 173.58KB, Downloaded 657 times)
|
|
|
|
|
Re: Debugging a SBC V2-004 [message #8975 is a reply to message #8968] |
Sat, 07 August 2021 08:39   |
edzard
Messages: 64 Registered: August 2019
|
Member |
|
|
Hello Phil
b1ackmai1er wrote on Fri, 06 August 2021 19:24cs looks good, output looks to be happening but be being interrupted
The multiple resets seems to be a problem.
Those resets are me (doing so). Each time I hear a beep I reset again. Just to get some info on the lines. After some resets the output gets less and less.
[quote title= I dont think there should be any activity on the int line, so perhaps uart is not being initialized correctly. Check wr and data lines. [/quote]
Will do.
[quote Not understand why this is happening on both your boards though. [/quote]
Me neither. It could be one of the 74XXX is defect, because they come all from the same source (Mouser).
I've build also your latest version SBC V2005 MegaFlash. But I have still to program the Flash.
[quote Do you have a minipro programmer? if so try testing all the ttl logic in the test function.[/quote]
Will do that too.
Thanks,
Edzard
[Updated on: Sat, 07 August 2021 08:40] Report message to a moderator
|
|
|
|
|
Current Time: Sat Oct 11 12:02:12 PDT 2025
Total time taken to generate the page: 0.39700 seconds
|