EUPURS and AP5 Cable(s)

for bbc micro/electron hardware, peripherals & programming issues (NOT emulators!)
User avatar
Elminster
Posts: 2920
Joined: Wed Jun 20, 2012 8:09 am
Location: Essex, UK
Contact:

Re: EUPURS and AP5 Cable(s)

Post by Elminster » Thu Jul 05, 2018 11:52 am

MartinB wrote:
Thu Jul 05, 2018 11:26 am
On the FTDI adaptors & modules front, I have only ever used the complete adaptor as shown above and not those modules. Ian S and a suggestion on Sparkfun have convinced me that the modules, such as the one you have, require their output levels to be inverted but I haven't tested the postulation.
Sounds right although from what I saw it is rs232 that is the inverted and USB not inverted.
RS232 refers to a specific set of voltage levels, inverted polarity, and (nowadays) a DB9 connector.

A USB-to-serial chip (like the FT232) outputs asynchronous serial at 3V or 5V level, not inverted. A MAX232 or similar chip is used to convert this to RS232 level.
Edit: I am assuming if I took this Serial cable apart (the black one you recommend) it would have the same FTDI chipset in it as my little board, but also the max232 or equiv.
Last edited by Elminster on Thu Jul 05, 2018 11:54 am, edited 2 times in total.

User avatar
MartinB
Posts: 4905
Joined: Mon Mar 31, 2008 9:04 pm
Location: Obscurity
Contact:

Re: EUPURS and AP5 Cable(s)

Post by MartinB » Thu Jul 05, 2018 12:12 pm

Duncan wrote:Edit: I am assuming if I took this Serial cable apart (the black one you recommend) it would have the same FTDI chipset in it as my little board, but also the max232 or equiv.
That would be my assumption, yes.

In fact, I have a couple of first-generation FTDI USB-Serial adaptors from way-back, one for RS232 and one for RS422 as per the piccie below. When I've previously opened them up as we do (why do we do that? :-k ), I remember there being two or three surface-mount chips inside and presumambly one of those will be the early equivalent of a Max223. The later one that Tronisoft sells (my recommendation above) is likely the same but further miniaturised.


FTDI.jpg
FTDI.jpg (5.38 KiB) Viewed 441 times


.
Last edited by MartinB on Thu Jul 05, 2018 12:19 pm, edited 2 times in total.

User avatar
Elminster
Posts: 2920
Joined: Wed Jun 20, 2012 8:09 am
Location: Essex, UK
Contact:

Re: EUPURS and AP5 Cable(s)

Post by Elminster » Thu Jul 05, 2018 12:33 pm

Sounds like I have 3 upurs cable projects.

1. Put missing wire on existing cable
2. Create way of connecting usb serial converter to pin pin header
3. Create a direct connection from usb to pin header.

Probably in that order. Or persuade Ian to do item 3. :-)

User avatar
1024MAK
Posts: 7787
Joined: Mon Apr 18, 2011 4:46 pm
Location: Looking forward to summer in Somerset, UK...
Contact:

Re: EUPURS and AP5 Cable(s)

Post by 1024MAK » Thu Jul 05, 2018 3:38 pm

RS232 is not really inverted, as the TTL level signal in the past was an internal card signal (that was not supposed to be exposed to the outside world). So really, it's the TTL level signal that is inverted! :lol:

It's no different to arguing that a non-inverting buffer is really a double inverter, because in practice, bipolar transistor circuits invert the signal by their nature in the most useful amplifier configuration (common emitter).

It is possible to reprogram a genuine FTDI chip to invert it's TTL RS232 inputs and outputs. But you are then restricted to that particular module. And if not labelled, could cause confusion at a later date. It is also not something that I have done, as it requires using software downloaded from FTDI's web site. Have a read of the datasheet if you are interested in this.

Mark
For a "Complete BBC Games Archive" visit www.bbcmicro.co.uk NOW!
BeebWiki‬ - for answers to many questions...

User avatar
Elminster
Posts: 2920
Joined: Wed Jun 20, 2012 8:09 am
Location: Essex, UK
Contact:

Re: EUPURS and AP5 Cable(s)

Post by Elminster » Thu Jul 05, 2018 3:54 pm

Is it just as simple as using one of these between the FTDI and the AP5?

https://www.sparkfun.com/products/11189

User avatar
1024MAK
Posts: 7787
Joined: Mon Apr 18, 2011 4:46 pm
Location: Looking forward to summer in Somerset, UK...
Contact:

Re: EUPURS and AP5 Cable(s)

Post by 1024MAK » Thu Jul 05, 2018 4:46 pm

Yep, or similar modules on eBay...

Mark
For a "Complete BBC Games Archive" visit www.bbcmicro.co.uk NOW!
BeebWiki‬ - for answers to many questions...

User avatar
Elminster
Posts: 2920
Joined: Wed Jun 20, 2012 8:09 am
Location: Essex, UK
Contact:

Re: EUPURS and AP5 Cable(s)

Post by Elminster » Thu Jul 05, 2018 4:52 pm

Right will order one of them, and a level shifter for IC2 as well then (tried to repurpose tube silencer but it odesnt seem to work properly, doesnt surprise me as it never worked very well for pitubedirect, I had to swap it for sundby one).

User avatar
MartinB
Posts: 4905
Joined: Mon Mar 31, 2008 9:04 pm
Location: Obscurity
Contact:

Re: EUPURS and AP5 Cable(s)

Post by MartinB » Thu Jul 05, 2018 5:53 pm

Duncan wrote:...and a level shifter for I2C
Don't forget that many of the I2C modules and gadgets out there are happily 5v tolerant - I think I only used the 3.3v level shifter for the Wii Nunchuck. Obviously always check first and if you don't know, default to using the shifter but virtually all my modules are 5v.



.
Last edited by MartinB on Thu Jul 05, 2018 5:54 pm, edited 1 time in total.

User avatar
Elminster
Posts: 2920
Joined: Wed Jun 20, 2012 8:09 am
Location: Essex, UK
Contact:

Re: EUPURS and AP5 Cable(s)

Post by Elminster » Thu Jul 05, 2018 7:04 pm

Ah jolly good thanks. 5volt tolerate is our friend.

User avatar
daveejhitchins
Posts: 4347
Joined: Wed Jun 13, 2012 5:23 pm
Location: Newton Aycliffe, County Durham
Contact:

Re: EUPURS and AP5 Cable(s)

Post by daveejhitchins » Sun Jul 08, 2018 7:58 am

For anyone else listening-in: I can supply the correct AP5-to-USB cables - just contact me . . .

Dave H :D
Parts: UM6502CE, GAL22V10D, GAL16V8D, AS6C62256A, TC514400AZ, WD1772, R6522, TMS27C512, AT28C256
Products: ARA II, ABR, ATI, AP6, MGC, AP5 . . .
For a price list, contact me at: Retro Hardware AT dave ej hitchins DOT plus DOT com

User avatar
Elminster
Posts: 2920
Joined: Wed Jun 20, 2012 8:09 am
Location: Essex, UK
Contact:

Re: EUPURS and AP5 Cable(s)

Post by Elminster » Sun Jul 08, 2018 9:51 am

As a matter of interest Do the cables you supply connect to user port 2 Idc or the pin header?

I couldn’t find a 7 pin housing so probably use a 4 and a 2 and skip one of the pins that is linked on the board.

User avatar
daveejhitchins
Posts: 4347
Joined: Wed Jun 13, 2012 5:23 pm
Location: Newton Aycliffe, County Durham
Contact:

Re: EUPURS and AP5 Cable(s)

Post by daveejhitchins » Thu Jul 12, 2018 8:09 am

Elminster wrote:
Sun Jul 08, 2018 9:51 am
As a matter of interest Do the cables you supply connect to user port 2 Idc or the pin header?
I'm supplying the USB to Serial leads, the one recommended by MartinB, along with a 9 pin 'D' to 7 pin connector for the header pins - I epoxy a 4 and 3 way together and 'mark' pin 1.
IMG_2632.jpg
Dave H :D
Parts: UM6502CE, GAL22V10D, GAL16V8D, AS6C62256A, TC514400AZ, WD1772, R6522, TMS27C512, AT28C256
Products: ARA II, ABR, ATI, AP6, MGC, AP5 . . .
For a price list, contact me at: Retro Hardware AT dave ej hitchins DOT plus DOT com

User avatar
Elminster
Posts: 2920
Joined: Wed Jun 20, 2012 8:09 am
Location: Essex, UK
Contact:

Re: EUPURS and AP5 Cable(s)

Post by Elminster » Thu Jul 12, 2018 9:20 am

Great thanks. So you are using the header on your cable.

I am still waiting for my max3232 board (the one I have currently on has rin1 and rout1 wired, and need 1 & 2 for EUPURS (I assume so anyway)) so I can use my FTDI cable. The above type of cable is plan B if I dont get it working.

For the man in the street is there any advantage over using the pin header overt he idc port, other than it allows you to potentially have 2 cables plugged in at once, although only be able to use one at a time obviously.

User avatar
Elminster
Posts: 2920
Joined: Wed Jun 20, 2012 8:09 am
Location: Essex, UK
Contact:

Re: EUPURS and AP5 Cable(s)

Post by Elminster » Tue Jul 17, 2018 8:48 am

I had some success using the max3232 board. I can transmit form Electron to Mac (if I cheat and ground RTS) the other doesn't. Electron moans no rX data. All looks connected correctly, so I think I shall break out scope to see if what I think it should be doing it is.

User avatar
Elminster
Posts: 2920
Joined: Wed Jun 20, 2012 8:09 am
Location: Essex, UK
Contact:

Re: EUPURS and AP5 Cable(s)

Post by Elminster » Tue Jul 17, 2018 10:40 am

Success. Seems to be working both ways using pin header, a standard TTL FTDI Serial device (running through a max3232) and hooked up to a Mac.

Sent files and ROMS to mac. And created an SSD on Mac. I havent really tested the validaty of what is going where, but at least the right bits of wire seem to be talking to each other. Whether this is a reliable way of doing it is another thing.

This is how it ended wired up
Max3232_ftdi_eupurs.jpg

User avatar
Elminster
Posts: 2920
Joined: Wed Jun 20, 2012 8:09 am
Location: Essex, UK
Contact:

Re: EUPURS and AP5 Cable(s)

Post by Elminster » Tue Jul 17, 2018 11:03 am

Being [Edit: On no there is a being in my mind] in mind that the max3232 can do 120kbps if a custom cable for UPURS was created using the max3237 could you increase the rate or is the bottle neck the Electron/Beeb?

'The MAX3237 is guaranteed to run at data rates of 250kbps in the normal operating mode and 1Mbps in the MegaBaud™ operating mode, while maintaining RS-232 output levels.'
Last edited by Elminster on Tue Jul 17, 2018 1:17 pm, edited 1 time in total.

User avatar
MartinB
Posts: 4905
Joined: Mon Mar 31, 2008 9:04 pm
Location: Obscurity
Contact:

Re: EUPURS and AP5 Cable(s)

Post by MartinB » Tue Jul 17, 2018 12:44 pm

Duncan wrote:Being in mind that the max3232 can do 120kbps if a custom cable for UPURS was created using the max3237 could you increase the rate or is the bottle neck the Electron/Beeb?
UPURS constructs RS232 through software bit-banging and so creates one's and nought's on the wires through 6502 instructions performing parallel<>serial conversion on the data and translating this bit stream into 6522 I/O commands. Thus, the hard edge is the speed at which these 6502 instructions are performed and at our 2MHz, we consequently top out at maximums of 115k baud receive and 230k baud transmit but I necessarily also limited the latter to 115k for RS232 protocol symmetry.


.
Last edited by MartinB on Tue Jul 17, 2018 12:45 pm, edited 2 times in total.

User avatar
Elminster
Posts: 2920
Joined: Wed Jun 20, 2012 8:09 am
Location: Essex, UK
Contact:

Re: EUPURS and AP5 Cable(s)

Post by Elminster » Tue Jul 17, 2018 2:01 pm

It all works in theory but generally things get corrupted just enough that the result isnt usable. I suspect that is todo with the 4 inch jumpers between ftdi and max3232 and then 4inch jumpers between max3232 and AP5 header. One would expect the TTL bit would be less reliable than the RS232 bit.

User avatar
danielj
Posts: 6482
Joined: Thu Oct 02, 2008 4:51 pm
Location: Manchester
Contact:

Re: EUPURS and AP5 Cable(s)

Post by danielj » Tue Jul 17, 2018 2:25 pm

Experience suggests those cheap ftdi boards don't use real ftdi chips... The signal out of mine (I have 3) isn't too clean...

User avatar
Elminster
Posts: 2920
Joined: Wed Jun 20, 2012 8:09 am
Location: Essex, UK
Contact:

Re: EUPURS and AP5 Cable(s)

Post by Elminster » Tue Jul 17, 2018 2:43 pm

danielj wrote:
Tue Jul 17, 2018 2:25 pm
Experience suggests those cheap ftdi boards don't use real ftdi chips... The signal out of mine (I have 3) isn't too clean...
Maybe. But I use this one all the time with other TTL serial stuff without issue (same jumper wires as well come to think of it), but obviously I dont usually put it through a max3232.

User avatar
Elminster
Posts: 2920
Joined: Wed Jun 20, 2012 8:09 am
Location: Essex, UK
Contact:

Re: EUPURS and AP5 Cable(s)

Post by Elminster » Tue Jul 17, 2018 2:59 pm

Seem to have broken Electron anyway, wonder if the EEPROM has got corrupted, was lcoked so shouldnt have. Just hangs on boot now. Uploading Workign Mac CoolTerm settings for reference.
Attachments
EUPURS_Coolterm.jpg

User avatar
danielj
Posts: 6482
Joined: Thu Oct 02, 2008 4:51 pm
Location: Manchester
Contact:

Re: EUPURS and AP5 Cable(s)

Post by danielj » Tue Jul 17, 2018 3:08 pm

Elminster wrote:
Tue Jul 17, 2018 2:43 pm
Maybe. But I use this one all the time with other TTL serial stuff without issue (same jumper wires as well come to think of it), but obviously I dont usually put it through a max3232.
Likewise (although it did need an extra pullup on the FreeFi232) - but upurs was/is (afaik) particularly persnickety about genuine FTDI cables... Martin can probably attest to this!

d.

User avatar
Elminster
Posts: 2920
Joined: Wed Jun 20, 2012 8:09 am
Location: Essex, UK
Contact:

Re: EUPURS and AP5 Cable(s)

Post by Elminster » Tue Jul 17, 2018 3:13 pm

danielj wrote:
Tue Jul 17, 2018 3:08 pm
Elminster wrote:
Tue Jul 17, 2018 2:43 pm
Maybe. But I use this one all the time with other TTL serial stuff without issue (same jumper wires as well come to think of it), but obviously I dont usually put it through a max3232.
Likewise (although it did need an extra pullup on the FreeFi232) - but upurs was/is (afaik) particularly persnickety about genuine FTDI cables... Martin can probably attest to this!

d.
I assume you mean genuine FTDI chips, ebay one is probably genuine fake. My hookup wires are genuine bits of wire.

But it could also be due to the 5v supply as I am driving it at the limit, or it could be because the Electron was dying, as now it is not well.
Attachments
IMG_4073.jpg
Last edited by Elminster on Tue Jul 17, 2018 3:15 pm, edited 2 times in total.

User avatar
danielj
Posts: 6482
Joined: Thu Oct 02, 2008 4:51 pm
Location: Manchester
Contact:

Re: EUPURS and AP5 Cable(s)

Post by danielj » Tue Jul 17, 2018 3:21 pm

Elminster wrote:
Tue Jul 17, 2018 3:13 pm

I assume you mean genuine FTDI chips, ebay one is probably genuine fake. My hookup wires are genuine bits of wire.

But it could also be due to the 5v supply as I am driving it at the limit, or it could be because the Electron was dying, as now it is not well.
Yes, I do mean the IC. I'm fairly convinced those ones are fake having looked at a few. They work well enough for most things though.

d.

User avatar
MartinB
Posts: 4905
Joined: Mon Mar 31, 2008 9:04 pm
Location: Obscurity
Contact:

Re: EUPURS and AP5 Cable(s)

Post by MartinB » Tue Jul 17, 2018 6:58 pm

Daniel wrote:...but upurs was/is (afaik) particularly persnickety about genuine FTDI cables...
UPURS' pernickityness about genuine FTDI devices is only in relation to whether or not RTS/CTS handshaking is correctly driven. My experience during development of the bit-banging engine showed that many non-FTDI USB-RS232 adaptors did not handshake properly. Indeed, I didn't reject all other types, I simply chose to strongly recommend FTDI since I knew these were consistently conformant to the RS232 standard even at the highest speeds.

So, in relation to signal levels, the rise and fall times thereof and edge-cleanliness etc., this isn't really anything to do with UPURS, it's all down to the 6522 because UPURS is merely a consumer of that device. If the 6522 it isn't happy with any of those parameters, corrupted UPURS data will surely follow.

User avatar
Elminster
Posts: 2920
Joined: Wed Jun 20, 2012 8:09 am
Location: Essex, UK
Contact:

Re: EUPURS and AP5 Cable(s)

Post by Elminster » Tue Jul 17, 2018 8:56 pm

Unclear at present. I need to do same test on original user port cable. Also supply better power source, shorter jump leads etc.. But first fix Electron.

Handshaking did seem to be working, as far as I could tell.
Last edited by Elminster on Tue Jul 17, 2018 8:57 pm, edited 1 time in total.

User avatar
MartinB
Posts: 4905
Joined: Mon Mar 31, 2008 9:04 pm
Location: Obscurity
Contact:

Re: EUPURS and AP5 Cable(s)

Post by MartinB » Tue Jul 17, 2018 9:21 pm

Duncan wrote:Handshaking did seem to be working, as far as I could tell.

That’s where I was in the early days with my non-FTDI adaptors until I looked more closely with a scope.....

User avatar
Elminster
Posts: 2920
Joined: Wed Jun 20, 2012 8:09 am
Location: Essex, UK
Contact:

Re: EUPURS and AP5 Cable(s)

Post by Elminster » Tue Jul 17, 2018 10:07 pm

MartinB wrote:
Tue Jul 17, 2018 9:21 pm
Duncan wrote:Handshaking did seem to be working, as far as I could tell.

That’s where I was in the early days with my non-FTDI adaptors until I looked more closely with a scope.....
Not the end of the world. Could still get a real one.

I thought someone would have put up a kicad design of a FTDI chip with usb hooked up to a max3232 but not found one yet. Could then just plug straight into electron header with a few tweaks.

User avatar
Elminster
Posts: 2920
Joined: Wed Jun 20, 2012 8:09 am
Location: Essex, UK
Contact:

Re: EUPURS and AP5 Cable(s)

Post by Elminster » Fri Jul 20, 2018 9:00 pm

Okay Electron sort of fixed. I soldered up the 2nd AP6 I got from Dave a couple of years ago and fitted in my Pres+1. (So now have fully loaded Acorn +1 with AP5, Pres+1 AP6 unpopulated except ROM, and an vanilla acorn +1). And boots fine. So assume somehting, probably EEPROM is stuffed in other Electron. So can cross off build second AP5 off my list.

I will probably order a real FTDI232 chip to my forth coming monster order.

Edit: typo, I am forever fixing up AP5 and AP6. Should be even more fun when we get an AP3,4 and 34 sorted.
Last edited by Elminster on Fri Jul 20, 2018 9:01 pm, edited 1 time in total.

User avatar
Elminster
Posts: 2920
Joined: Wed Jun 20, 2012 8:09 am
Location: Essex, UK
Contact:

Re: EUPURS and AP5 Cable(s)

Post by Elminster » Sat Jul 21, 2018 12:47 am

Odd not sure how I killed the EEPROM but it refuses to even erase in a Batronix programmer, dies consistantly at 91% erased.

It doesnt really need to be an eeprom any way so just programmed a normal 16K rom. Alive again.

Post Reply