Adding a Raspberry Pi Second Processor running PiTubeDirect using KenLowe's Level-Shifter Interface

for bbc micro/electron hardware, peripherals & programming issues (NOT emulators!)
Post Reply
User avatar
Wheel_nut
Posts: 183
Joined: Wed May 01, 2019 12:46 pm
Location: West of Scotland
Contact:

Adding a Raspberry Pi Second Processor running PiTubeDirect using KenLowe's Level-Shifter Interface

Post by Wheel_nut » Sun Mar 22, 2020 12:39 am

I am trying to find the information I need to install a Raspberry Pi (RPi) Co-Processor using:
:arrow: KenLowe's Level Shifter Interface hardware (Tube Interface or 1Mhz Bus Interface)
:arrow: Hoglet67 and BigEd's PiTubeDirect Software implementation for the Raspberry Pi (RPi)

I will come back here and add the definitive answers I receive in this thread.
Questions follow in the next Post...

EDIT 1/4/20: Thanks to Hoglet, KenLowe, BigEd and dp11 for indulging me in this thread.
Below is my abridged collation from this thread to provide a guide to Installation and Use:

You will need:
  1. A Tube Level Shifter - available from KenLowe for £12
  2. A Raspberry Pi - (I am using the RPi 1B - either 256MB or 512MB version)
  3. A MicroSD Card 8GB or higher preferably Class 6 or higher
  4. PiTubeDirect Software (latest level is Fer-De-Lance) from https://github.com/hoglet67/PiTubeDirect
  5. A 40 Pin Tube Port Extender (unless you are using a Rpi Zero which needs no extender) - More about this below
  6. And, of course a Beeb with either DFS1.2 or DFS 2.6 or MMFS which contain the Tube Software,
Preparing the Raspberry Pi 1B:
You will need to remove the Yellow Composite Video Connector as it interferes with the 40 Pin GPIO interface of the Tube Level Shifter and does not allow the RPi 1B to drop low enough into the Connector Well of the Beeb You can either de-solder it or simply cut the pins under the socket. I also removed the Ethernet Socket to gain some more clearance but this isn't essential.
20200328_143720.jpg
Making the 40 Pin Tube Extender:
You can use either:
  1. Two of these 12mm Header Extenders plugged into one another
    40Pin Header.jpg
    - or -
  2. A short Cable extender made up as shown here.
    (Picture to be inserted)
Step By Step Procedure:
  1. Format the MicroSD Card as FAT32 and simply copy all of the contents of the PiTubeDirect zip file into the Root Directory. Place the MicroSD Card in the RPi using a SD Card to MicroSD Card adapter if necessary.
  2. If you have or intend to have the Case Screw in place, put a small piece of insulating tape on the Tube Level Shifter at the contact point.
  3. Plug the Tube Level Shifter into the Extender and plug the Extender into the Tube Port under the Beeb.
  4. Plug the Raspberry Pi into the Tube Level Shifter taking care not to misalign the pins with the Header. The 26 Pins of the RPi 1B go into the Leftmost 26 sockets of the Tube Level Shifter (nearest the Case Wall). BE CAREFUL! Mis-plugging WILL destroy the Raspberry Pi GPIO.
    20200328_143216.jpg
  5. Carefully turn the Beeb over, and Switch On
  6. You will hear the customary Boo .... but NO Bip. This is normal
  7. You should now see this Startup Message on the Screen:
    20200328_142952.jpg
What do you use the Co-Processors for:
Taming the Beast!

The default co-processor is defined by the copro=N parameter in cmdline.txt on your SD Card, (copro=0 copro1_speed=3 copro3_speed=4 tube_delay=0 elk_mode=0)
where N is:
  • 0 for the fastest 65tube based 65C102 Co Processor
  • 1 for a 3MHz 65tube based 65C02 Co Processor
  • 2 for the lFast 65C102 Co Processor
  • 3 for 4MHz 65C102 (Acorn internal 65C102 Co Pro)
  • 4 for the Z80 Co Processor
  • 8 for the 80x86 Co Processor
  • 9 for the 6809 Co Processor
  • 11 for the PDP-11 Co Processor
  • 12 for the ARM2 Co Processor
  • 13 for the 32016 Co Processor
  • 14 for no Co Processor (to save having to power off the Pi)
  • 15 for the fastest native ARM7 Co Processor
  • 16 for the 64KB Normal 65C02 (lib6502) Co Processor
  • 17 for the 256KB Turbo 65C02 (lib6502) Co Processor
  • 20 for the OPC5LS Co Processor
  • 21 for the OPC6 Co Processor
  • 22 for the OPC7 Co Processor
My original quest was to find a way to have the Beeb boot up with Co Processor 14 so that it behaved as a “Standard” Beeb. I could then use *FX 151,230,0 to activate the 65C02 Co Processor to run TUBEELT. However, when I tried changing the cmdline.txt file on the SD Card to (copro=14 copro1_speed=3 copro3_speed=4 tube_delay=0 elk_mode=0, when switched on, the Beeb hung with a flashing Cursor which Hoglet attributed to the RPi booting slower than the Beeb. This could be recovered by a Break.

I decided to leave the RPi SD Card installation as standard and achieve my objective by changing the !BOOT file on Disc 0 of the SD Card to set up the Programmable Function Keys to give me a range of configuration options thus:
F0 Co Processor 14 (Off)
F1 Co Processor 0 (65C102)
F2 Co Processor 0 (65C102 and Start TUBEELT)
F3 Co Processor 1 (65C102 @ 3MHz)
F4 Co Processor 14 (Off and start STH Games Menu)
F5 Switch to Disk 455
F6 Switch to Disk 455
F7 Enable Floppy Drive (*OPT 5,1)
F8 Enable Floppy Drive and Disable MMFS (Useful to Format etc. Floppy Discs)
F9 Disable DFS and Start STH Games Menu (Keeps Page at &0E00)

So, to Boot to STH Games Menu: Switch On; Shift-Break; F0; Shift-Break; F4
To Boot to STH Games Menu with DFS Disabled and Page at &0E00: F9; Ctrl-Break; Shift Break; F4
To Boot to TubeELT: Shift-Break; F2

To do this you first need to Unlock Disc 0 on the SD Card:
*DIN 0
*DOP U
*RENAME !BOOT OLD!BOOT
Now create a new !BOOT File using an editor like View containing:

Code: Select all

*KEY 0 *FX 151,230,14|M
*KEY 1 *FX 151,230,0|M
*KEY 2 *FX 151,230,0|M*DIN45|M*TUBEELT|M
*KEY 3 *FX 151,230,1|M
*KEY 4 *TV255|M*/MENU|M
*KEY 5 *MMFS|M*OPT5,1|M*DIN300|M*RLOAD COP114 11|M
*KEY 6 *OPT5,0|M*DIN456|M*.|M
*KEY 7 *MMFS|M*OPT5,1|M*DISC|M*.|M
*KEY 8 *KILL10|M*KILL15|M*| Ctrl-Break
*KEY 9 *MMFS|M*OPT5,0|M*DIN0|M*KILL06|M*| PRESS F4

*|TOFF TON TELT T3MHz GAME COP 456 DFS NoMMFS NoDFS

Last edited by Wheel_nut on Mon Apr 06, 2020 10:49 am, edited 11 times in total.
#1 BBC Model B Issue 7 + 1770 DFS + Dual TEAC Floppy
#2 BBC Model B Issue 7 + 8271 DFS + Dual Floppy + Speech + PiTubeDirect on KenLowe's Tube Level Shifter
#3 BBC Model B Issue 7 + 8271 DFS + Cumana Single Floppy

User avatar
Wheel_nut
Posts: 183
Joined: Wed May 01, 2019 12:46 pm
Location: West of Scotland
Contact:

Re: Adding a Raspberry Pi Second Processor running PiTubeDirect using KenLowe's Level-Shifter Interface

Post by Wheel_nut » Sun Mar 22, 2020 1:07 am

I am going to try to use a Raspberry Pi 1B on the Tube Interface and have now got on KenLowe's schedule for a "Under" Tube Level Shifter. I will plug the RPI into the Level Shifter and into the Tube Interface Socket on the Beeb

1) Question: Does The RPi 1B have to be the 512MB version or will the 256MB Version work?
2) I have downloaded "PiTubeDirectEggEater.zip" from Hoglet67's Github site. It contains Two Folders and Ten Files
3) Question: Do I simply copy the folders and files to a FAT32 formatted SD Card?
4) Plug the SD Card into the RPi
5) Boot up the Beeb

Question: Have I missed anything?
Question: What do I expect to see?

The Wiki says:
With this project you will have a configurable coprocessor which can be powered by the Beeb and fitted inside it, with a choice of:

274MHz 65C102 (*FX 151,230,0)
3MHz 65C102 (*FX 151,230,1) (for games compatibility)
112MHz Z80 (*FX 151,230,4)
63MHz 80286 (*FX 151,230,8)
27MHz 6809 (*FX 151,230,9)
59MHz ARM2 (*FX 151,230,12)
35MHz 32016 (*FX 151,230,13)
null co-pro (*FX 151,230,14) (to save having to power off the pi)
1000MHz ARMnative (*FX 151,230,15)

What is a simple way to test that it is working?
#1 BBC Model B Issue 7 + 1770 DFS + Dual TEAC Floppy
#2 BBC Model B Issue 7 + 8271 DFS + Dual Floppy + Speech + PiTubeDirect on KenLowe's Tube Level Shifter
#3 BBC Model B Issue 7 + 8271 DFS + Cumana Single Floppy

User avatar
KenLowe
Posts: 967
Joined: Mon Oct 18, 2004 4:35 pm
Location: Scotland
Contact:

Re: Adding a Raspberry Pi Second Processor running PiTubeDirect using KenLowe's Level-Shifter Interface

Post by KenLowe » Sun Mar 22, 2020 1:27 am

Yup. All you need to do is copy the contents of the zip file to the root of the SD card. Pop the card into the RPi and switch on. If you're using a beeb, then the startup message should change to Acorn TUBE 6502 64K. It may take a further BREAK to get this message if the beeb boots up before the RPi has finished initialising. If you don't see the message, then you may need to install a File System ROM that has the Tube Host code included. Most Acorn file systems include it (as does MMFS, if you use that). The next thing to do is download a copy of Elite for the 2nd Processor, and try running it. Switching to a different Co-Pro (using *FX151,230,x) should get you different startup messages.

If you're using a Master, then Tube Host Code is included in the OS, so you don't need to worry about the File System ROMs. However, you may need to enter the following additional commands before you see the startup message:

*CONFIGURE EXTUBE
*CONFIGURE TUBE

User avatar
BigEd
Posts: 2862
Joined: Sun Jan 24, 2010 10:24 am
Location: West
Contact:

Re: Adding a Raspberry Pi Second Processor running PiTubeDirect using KenLowe's Level-Shifter Interface

Post by BigEd » Sun Mar 22, 2020 8:55 am

Indeed, the startup banner will tell you that the second processor is there, if you have a ROM in place with the right support code. With the second processor present, detected, and enabled, you get a single beep at power-on instead of the usual double beep.

If you haven't already got solid state storage, then getting MMFS (for example) with an SD Card dongle is a cheap and easy thing to do, and you can use a pre-loaded MMB file which contains many games as well as Tube Elite:
*DIN 45
*TUBEELT
Press Space
Press F0 to launch
For some examples of how to use the various second processors, see
Examples for each CoPro core

I'm pretty sure you can always power the Pi from the Tube interface itself. And yes, a 256MB Pi will work.

BTW, for technical reasons, it's better to

Code: Select all

*CONFIGURE INTUBE
On most Pi models, the LED will blink/flicker/toggle as you use the Tube: just hit return a few times and watch it toggle each time (if the LED is visible, of course.) I think the next release has this working on more - maybe all - models.

User avatar
KenLowe
Posts: 967
Joined: Mon Oct 18, 2004 4:35 pm
Location: Scotland
Contact:

Re: Adding a Raspberry Pi Second Processor running PiTubeDirect using KenLowe's Level-Shifter Interface

Post by KenLowe » Sun Mar 22, 2020 9:00 am

BigEd wrote:
Sun Mar 22, 2020 8:55 am
BTW, for technical reasons, it's better to

Code: Select all

*CONFIGURE INTUBE
Ah. Okay. I'll update my Installation Notes accordingly.

User avatar
Wheel_nut
Posts: 183
Joined: Wed May 01, 2019 12:46 pm
Location: West of Scotland
Contact:

Re: Adding a Raspberry Pi Second Processor running PiTubeDirect using KenLowe's Level-Shifter Interface

Post by Wheel_nut » Thu Mar 26, 2020 8:07 pm

Firstly, I must own up to being the cause of the flurry of activity on the "Pi-based Co-Pro on the cheap - 100MHz 6502 for £10? (now 274MHz)" thread. I have been communicating with KenLowe by PM to try to get my RPi 1Bs working on his excellent Tube Level Shifter design.

The Tube Level Shifter comes with a very comprehensive Instruction Sheet which probably makes this thread unneccessary =D>

I have installed the RPi 1B "close coupled" to the Tube Level Shifter and connected the Tube Level Shifter on a short cable extender to the Tube Port of my BBC B (Issue 7). The Tube Level Shifter and RPi are powered from the Beeb (Jumper J1 in place).

I downloaded PiTubeDirect_EggEater from Hoglet's Github site and unpacked and copied the zip file contents to a FAT32 MicroSD Card.

My first attempt with a RPi 1B (256) gave just a flashing Cursor on Boot-up. On pressing Break, I sometimes get a varying length string of Characters. After checking everything, I decided to try another RPi ...

My Second attempt with a RPi 1B (512) gave just a flashing Cursor on Boot-up. On pressing Break, it just returned to the Flashing Cursor.

I also tried removing Jumper J1 from the Tube Level Shifter Board and Powering the Pi and Level Shifter externally. No difference.

After an exchange of PMs with KenLowe who coincedentaly was able to see the Flashing Cursor, I mistakenly believed that there might be a problem with the compatibility of the RPi 1B, the Tube Level Shifter and perhaps PiTubeDirect_EggEater. I WAS WRONG!

While Ken was consulting with BigEd and Hoglet on the main thread, I dug out another TWO RPis ... a 256MB and a 512MB and tried them. To my surprise, they BOTH Work!!! ...and the first two still don't. I have tried switching SD Cards to no avail. I now believe that I have TWO defective Pis which I will have to test separately using their original setup with Raspbian.

At Ken's suggestion, I have tried PiTubeDirect_FerDeLance and it works with the two Pis that work with EggEater and fails with the ywo that failed before. I now intend to use FerDeLance for all further testing.

Now, I need to learn how to play Elite!

Thanks to KenLowe, BigEd and Hoglet for this excellent piece of work and my apologies for crying Wolf.
#1 BBC Model B Issue 7 + 1770 DFS + Dual TEAC Floppy
#2 BBC Model B Issue 7 + 8271 DFS + Dual Floppy + Speech + PiTubeDirect on KenLowe's Tube Level Shifter
#3 BBC Model B Issue 7 + 8271 DFS + Cumana Single Floppy

User avatar
BigEd
Posts: 2862
Joined: Sun Jan 24, 2010 10:24 am
Location: West
Contact:

Re: Adding a Raspberry Pi Second Processor running PiTubeDirect using KenLowe's Level-Shifter Interface

Post by BigEd » Thu Mar 26, 2020 8:12 pm

If you're able to hook up the serial port debug to the two uncooperative PiB's, I expect Dave (hoglet) would be interested in seeing what diagnostics you see when you boot with Fer-de-Lance.

User avatar
Wheel_nut
Posts: 183
Joined: Wed May 01, 2019 12:46 pm
Location: West of Scotland
Contact:

Re: Adding a Raspberry Pi Second Processor running PiTubeDirect using KenLowe's Level-Shifter Interface

Post by Wheel_nut » Thu Mar 26, 2020 11:01 pm

BigEd wrote:
Thu Mar 26, 2020 8:12 pm
If you're able to hook up the serial port debug to the two uncooperative PiB's, I expect Dave (hoglet) would be interested in seeing what diagnostics you see when you boot with Fer-de-Lance.
Hi BigEd, If I was able to do that ... and touch type, I would be dangerous.

I have just tested the two failing RPis by booting them in Raspbian and they seem to work perfectly well. I was hoping to find a System Page on Raspbian which would give me the SOC identity and revision data but couldn't find it.

Is the Serial Port debug something that I could easily rig up and extract the data? I am happy to have a go at it but if it would be easier, I could package the two Pis and send them to any one of you by post. I am out in the sticks so fairly easy to drop in the post.

It does look to me as though it isn't a hardware fault and may be worth diagnosing before releasing FerDeLance into the long grass.

Robin
#1 BBC Model B Issue 7 + 1770 DFS + Dual TEAC Floppy
#2 BBC Model B Issue 7 + 8271 DFS + Dual Floppy + Speech + PiTubeDirect on KenLowe's Tube Level Shifter
#3 BBC Model B Issue 7 + 8271 DFS + Cumana Single Floppy

dp11
Posts: 998
Joined: Sun Aug 12, 2012 8:47 pm
Contact:

Re: Adding a Raspberry Pi Second Processor running PiTubeDirect using KenLowe's Level-Shifter Interface

Post by dp11 » Thu Mar 26, 2020 11:19 pm

With raspbian try

cat /proc/info

This should tell us about your pi.

User avatar
Wheel_nut
Posts: 183
Joined: Wed May 01, 2019 12:46 pm
Location: West of Scotland
Contact:

Re: Adding a Raspberry Pi Second Processor running PiTubeDirect using KenLowe's Level-Shifter Interface

Post by Wheel_nut » Fri Mar 27, 2020 12:02 am

The first one is the RPi 1B (256MB) and the second one is the RPI 1B (512MB)
20200326_234334.jpg
20200326_233737.jpg
Is this what you need?

Robin
#1 BBC Model B Issue 7 + 1770 DFS + Dual TEAC Floppy
#2 BBC Model B Issue 7 + 8271 DFS + Dual Floppy + Speech + PiTubeDirect on KenLowe's Tube Level Shifter
#3 BBC Model B Issue 7 + 8271 DFS + Cumana Single Floppy

User avatar
hoglet
Posts: 8949
Joined: Sat Oct 13, 2012 6:21 pm
Location: Bristol
Contact:

Re: Adding a Raspberry Pi Second Processor running PiTubeDirect using KenLowe's Level-Shifter Interface

Post by hoglet » Fri Mar 27, 2020 6:19 am

Wheel_nut wrote:
Thu Mar 26, 2020 11:01 pm
I have just tested the two failing RPis by booting them in Raspbian and they seem to work perfectly well.
I think it's still possible this is a damaged GPIO.

I have a damaged Pi 3 that behaves in exactly the same way: Raspbian will boot fine, but PiTubeDirect no longer boots at all. It got damaged when I plugged it into the level shifter mis-aligned by one row.

(This has now been repurposed as my Kodi Box)
Wheel_nut wrote:
Thu Mar 26, 2020 11:01 pm
I am happy to have a go at it but if it would be easier, I could package the two Pis and send them to any one of you by post. I am out in the sticks so fairly easy to drop in the post.
I'd be happy to take a look.

I'll send you a PM.

Dave

User avatar
KenLowe
Posts: 967
Joined: Mon Oct 18, 2004 4:35 pm
Location: Scotland
Contact:

Re: Adding a Raspberry Pi Second Processor running PiTubeDirect using KenLowe's Level-Shifter Interface

Post by KenLowe » Fri Mar 27, 2020 7:15 am

hoglet wrote:
Fri Mar 27, 2020 6:19 am
Wheel_nut wrote:
Thu Mar 26, 2020 11:01 pm
I am happy to have a go at it but if it would be easier, I could package the two Pis and send them to any one of you by post. I am out in the sticks so fairly easy to drop in the post.
I'd be happy to take a look.
Dave,

I'm thinking it might be appropriate for me to send you one of my tube level shifters to test this with. If you would like one, can you let me know if you'd prefer an underside version, or one that will work remotely with a ribbon cable (I need to put a different connector on the level shifter depending on which option you go for).

Regards
Ken.

User avatar
hoglet
Posts: 8949
Joined: Sat Oct 13, 2012 6:21 pm
Location: Bristol
Contact:

Re: Adding a Raspberry Pi Second Processor running PiTubeDirect using KenLowe's Level-Shifter Interface

Post by hoglet » Fri Mar 27, 2020 10:50 am

Hi Ken,
KenLowe wrote:
Fri Mar 27, 2020 7:15 am
I'm thinking it might be appropriate for me to send you one of my tube level shifters to test this with.
There's no hurry here. Let me test them first with the level shifter that I already have.

I'm not expecting the issue is in any way related to the level shifter. I'm expecting to find one or more of the GPIOs is damaged. It's surprising easy to damage a Pi with static.

Dave

User avatar
Wheel_nut
Posts: 183
Joined: Wed May 01, 2019 12:46 pm
Location: West of Scotland
Contact:

Re: Adding a Raspberry Pi Second Processor running PiTubeDirect using KenLowe's Level-Shifter Interface

Post by Wheel_nut » Fri Mar 27, 2020 12:39 pm

Hi Guys,

Thank you all for your attention and time spent on this. While I cannot recall having mis-plugged the RPI into the Level Shifter, it is highly probable that I have done so.

I am currently using a makeshift Pin extender to plug the RPi 1B directly under the Beeb, and fiddling with it in confined space and light leads me to hold up my hand and take responsibility for mis-aligning the extender.

I have PM'd Dave to say that since the two failing units are displaying the same symptoms as his one, let's stop wasting time and effort on further investigation. I can re-purpose those units back to running Raspbian for my daughter's School club when that resumes after the current moratorium.

I am waiting for parts to arrive to make a short (27mm) Female to Male 40 Pin Extender which will sit between the Tube Port and the Level Shifter in the access well under the Beeb, The RPi 1B (with the Composite Video Spout and Ethernet Socket removed) will then directly plug into Ken's Level Shifter and sit neatly within the height afforded by the Case Feet. I will post pictures here when I have the finished project.

Stay safe, Robin
#1 BBC Model B Issue 7 + 1770 DFS + Dual TEAC Floppy
#2 BBC Model B Issue 7 + 8271 DFS + Dual Floppy + Speech + PiTubeDirect on KenLowe's Tube Level Shifter
#3 BBC Model B Issue 7 + 8271 DFS + Cumana Single Floppy

User avatar
KenLowe
Posts: 967
Joined: Mon Oct 18, 2004 4:35 pm
Location: Scotland
Contact:

Re: Adding a Raspberry Pi Second Processor running PiTubeDirect using KenLowe's Level-Shifter Interface

Post by KenLowe » Fri Mar 27, 2020 1:31 pm

hoglet wrote:
Fri Mar 27, 2020 6:19 am
Wheel_nut wrote:
Thu Mar 26, 2020 11:01 pm
I have just tested the two failing RPis by booting them in Raspbian and they seem to work perfectly well.
I have a damaged Pi 3 that behaves in exactly the same way: Raspbian will boot fine, but PiTubeDirect no longer boots at all. It got damaged when I plugged it into the level shifter mis-aligned by one row.
Dave
I've got a growing collection of RPi Zeros with similar user initiated damage. I'm wondering if that's why there's currently a world shortage of PI Zeros. My worst faux pas was plugging one of my RPi Zeros into a level shifter, 180 degrees out of orientation. Don't ask! That caused a bit of smoke to appear! Yesterdays jumper issue is coming a close second, but that didn't actually cause any damage, so I'm not sure it counts.

User avatar
Wheel_nut
Posts: 183
Joined: Wed May 01, 2019 12:46 pm
Location: West of Scotland
Contact:

Re: Adding a Raspberry Pi Second Processor running PiTubeDirect using KenLowe's Level-Shifter Interface

Post by Wheel_nut » Fri Mar 27, 2020 5:16 pm

I take strength from your accounts which tell me that I am not the only one making stupid mistakes! So here's a bunch of what may be stupid questions:

1) *CONFIGURE INTUBE - Does this only apply to the Master and not necessary for the Beeb?

2) How do I revert to a "Normal" Beeb without removing the Raspberry Pi? Is it *FX 151,230,14 ? Is there a *NOTUBE equivalent for the Beeb?

3) Can I configure the Tube Co-Processor to Boot up as a "Normal" Beeb and let me then activate the Co-Processor using e.g. *FX 151,230,1 ? If so. How?

3) Is there an Elite Manual in PDF form somewhere? I need to study for my Pilot's Licence!

4) Besides runnine Tube Elite, what applications are you using the Co-Processors for? A brief descripition if what they do and where to find them would be a great help.

5) Is there any way to use the Graphics Processor on the Raspberry Pi Co-Processor? (Yes, I'm a dreamer ... but I hope I'm not the only one!)

6) I see that some of you are installing Raspberry Pis on the Tube and 1MHz Bus ports concurrently. Why? and what is the benefit? How do you tame the beasts?
#1 BBC Model B Issue 7 + 1770 DFS + Dual TEAC Floppy
#2 BBC Model B Issue 7 + 8271 DFS + Dual Floppy + Speech + PiTubeDirect on KenLowe's Tube Level Shifter
#3 BBC Model B Issue 7 + 8271 DFS + Cumana Single Floppy

User avatar
hoglet
Posts: 8949
Joined: Sat Oct 13, 2012 6:21 pm
Location: Bristol
Contact:

Re: Adding a Raspberry Pi Second Processor running PiTubeDirect using KenLowe's Level-Shifter Interface

Post by hoglet » Fri Mar 27, 2020 5:46 pm

Some quick fire answers....
Wheel_nut wrote:
Fri Mar 27, 2020 5:16 pm
1) *CONFIGURE INTUBE - Does this only apply to the Master and not necessary for the Beeb?
This is Master only.
Wheel_nut wrote:
Fri Mar 27, 2020 5:16 pm
2) How do I revert to a "Normal" Beeb without removing the Raspberry Pi? Is it *FX 151,230,14 ? Is there a *NOTUBE equivalent for the Beeb?

Code: Select all

*FX 151,230,14
Wheel_nut wrote:
Fri Mar 27, 2020 5:16 pm
3) Can I configure the Tube Co-Processor to Boot up as a "Normal" Beeb and let me then activate the Co-Processor using e.g. *FX 151,230,1 ? If so. How?
You can set copro=14 in cmdline.txt:

Code: Select all

copro=14 copro1_speed=3 copro3_speed=4 tube_delay=0 elk_mode=0
Wheel_nut wrote:
Fri Mar 27, 2020 5:16 pm
3) Is there an Elite Manual in PDF form somewhere? I need to study for my Pilot's Licence!
https://openretro.org/file/37a540d37634 ... b46dfb7fe4
Wheel_nut wrote:
Fri Mar 27, 2020 5:16 pm
4) Besides runnine Tube Elite, what applications are you using the Co-Processors for? A brief descripition if what they do and where to find them would be a great help.
Ed posted some ideas here:
https://github.com/hoglet67/PiTubeDirec ... CoPro-core

See also this thread:
viewtopic.php?f=2&t=15974
Wheel_nut wrote:
Fri Mar 27, 2020 5:16 pm
5) Is there any way to use the Graphics Processor on the Raspberry Pi Co-Processor? (Yes, I'm a dreamer ... but I hope I'm not the only one!)
Not currently, though it's technically possible to make use of the Pi's frame buffer.

There is a very old verion of PiTubeDirect that we use on the Acorn Atom as a Hi Res Graphics Card/Accelerator. Roland has continued to this develop:
viewtopic.php?f=44&t=11220
Wheel_nut wrote:
Fri Mar 27, 2020 5:16 pm
6) I see that some of you are installing Raspberry Pis on the Tube and 1MHz Bus ports concurrently. Why? and what is the benefit? How do you tame the beasts?
They serve different purposes:
- the Tube (PiTubeDirect) emulates a multitude of old and new second processors
- the 1MHz Bus (Pi1MHz) emulates several useful peripherals: a BeebSCSI hard disk, a large RAM disk, and a Music 5000.

Dave

User avatar
KenLowe
Posts: 967
Joined: Mon Oct 18, 2004 4:35 pm
Location: Scotland
Contact:

Re: Adding a Raspberry Pi Second Processor running PiTubeDirect using KenLowe's Level-Shifter Interface

Post by KenLowe » Fri Mar 27, 2020 5:53 pm

Hoglet has beaten me to it, but here's my quick fire answers:
Wheel_nut wrote:
Fri Mar 27, 2020 5:16 pm
1) *CONFIGURE INTUBE - Does this only apply to the Master and not necessary for the Beeb?
Correct.
Wheel_nut wrote:
Fri Mar 27, 2020 5:16 pm
2) How do I revert to a "Normal" Beeb without removing the Raspberry Pi? Is it *FX 151,230,14 ? Is there a *NOTUBE equivalent for the Beeb?
Correct. *FX151,230,14 drops you back to a normal beeb. The IntegraB add on board provides *NOTUBE / *CONF. TUBE OFF commands. Some other utility ROMs may provide something similar, but I'm not sure about that.
Wheel_nut wrote:
Fri Mar 27, 2020 5:16 pm
3) Can I configure the Tube Co-Processor to Boot up as a "Normal" Beeb and let me then activate the Co-Processor using e.g. *FX 151,230,1 ? If so. How?
You can set the default Co-Pro by modifying the cmdline.txt file on the SDCard. See here.
Wheel_nut wrote:
Fri Mar 27, 2020 5:16 pm
3) Is there an Elite Manual in PDF form somewhere? I need to study for my Pilot's Licence!
You have two question 3's! I'm sure there will be a PDF manual somewhere, but I don't know where. Someone else will be able to advise.
Wheel_nut wrote:
Fri Mar 27, 2020 5:16 pm
4) Besides running Tube Elite, what applications are you using the Co-Processors for? A brief descripition if what they do and where to find them would be a great help.
Lots of things. How about emulating a ZX81, or a ZX Spectrum or Jupiter Ace (you also need a VideoNula for some of those to work). But the most important reason is to be able to run Zork.
Wheel_nut wrote:
Fri Mar 27, 2020 5:16 pm
5) Is there any way to use the Graphics Processor on the Raspberry Pi Co-Processor? (Yes, I'm a dreamer ... but I hope I'm not the only one!)
I don't think so, but hoglet will be able to answer that question better.
Wheel_nut wrote:
Fri Mar 27, 2020 5:16 pm
6) I see that some of you are installing Raspberry Pis on the Tube and 1MHz Bus ports concurrently. Why? and what is the benefit? How do you tame the beasts?
The 1MHz level shifter makes it easier to emulate 1MHz devices. Currently SCSI HDD, Music5000 & RAM Disk are emulated. A SCSI drive makes it easier to run an Econet network.

User avatar
Wheel_nut
Posts: 183
Joined: Wed May 01, 2019 12:46 pm
Location: West of Scotland
Contact:

Re: Adding a Raspberry Pi Second Processor running PiTubeDirect using KenLowe's Level-Shifter Interface

Post by Wheel_nut » Mon Mar 30, 2020 5:05 pm

Thank you Hoglet and KenLowe for your very informative answers and the linkies which have given me plenty of reading material. :)

I am now using FerDeLance and will report any issues that I may encounter.

I would prefer to boot up the Beeb as a "Standard" Beeb so have edited the cmdline.txt on the SD Card to
"copro=14 copro1_speed=3 copro3_speed=4 tube_delay=0 elk_mode=0"

When the Beeb Boots, it shows just a flashing Cursor and needs a Break to display the normal startup messages.
Question 1: Should this be a Ctrl-Break (which Clears Function Key Settings) or is just a Break OK?

Question 2: With Tube Co-Processors 0 or 1 enabled, the "Ready" Prompt changed from > to * and Star commands can be entered without another Star. Why is this? ... and are non Star commands invalid? Do I have to type *Basic to get back to a > Prompt?

Question 3: Can the standard games on the Beeb.MMB compendium be run with Co-Processor 0 or 1 enabled? If so, How?

Question 4: This is more of a WIBNI ... but wouldn't it be nice if the Beeb had the equivalent of an Autoexec.bat which would run EXEC commands or files to do things like set up the Red Function Keys and set Default Drive and Disc Number. The !BOOT is only invoked by the Shift-Break or by *EXECing it so doesn't quite do the same thing.

I miss the reassuring BooBip! :(

Robin
#1 BBC Model B Issue 7 + 1770 DFS + Dual TEAC Floppy
#2 BBC Model B Issue 7 + 8271 DFS + Dual Floppy + Speech + PiTubeDirect on KenLowe's Tube Level Shifter
#3 BBC Model B Issue 7 + 8271 DFS + Cumana Single Floppy

User avatar
hoglet
Posts: 8949
Joined: Sat Oct 13, 2012 6:21 pm
Location: Bristol
Contact:

Re: Adding a Raspberry Pi Second Processor running PiTubeDirect using KenLowe's Level-Shifter Interface

Post by hoglet » Mon Mar 30, 2020 5:32 pm

Wheel_nut wrote:
Mon Mar 30, 2020 5:05 pm
When the Beeb Boots, it shows just a flashing Cursor and needs a Break to display the normal startup messages.
Question 1: Should this be a Ctrl-Break (which Clears Function Key Settings) or is just a Break OK?
Either should be fine.

(It's a shame this case now hangs on a Model B on power up. It's down to how quickly the Pi boots compared to the Beeb. The Pi Foundation firmware blob as got more complex over time, which has resulted in slower boot times.)
Wheel_nut wrote:
Mon Mar 30, 2020 5:05 pm
Question 2: With Tube Co-Processors 0 or 1 enabled, the "Ready" Prompt changed from > to * and Star commands can be entered without another Star. Why is this? ... and are non Star commands invalid? Do I have to type *Basic to get back to a > Prompt?
Are you doing a Ctrl-BREAK after *FX 151,230,0?

If you do this, you should get a > prompt.
Wheel_nut wrote:
Mon Mar 30, 2020 5:05 pm
Question 3: Can the standard games on the Beeb.MMB compendium be run with Co-Processor 0 or 1 enabled? If so, How?
No they can't, and as far as I know, the only solution is to disable the second processor.
Wheel_nut wrote:
Mon Mar 30, 2020 5:05 pm
Question 4: This is more of a WIBNI ... but wouldn't it be nice if the Beeb had the equivalent of an Autoexec.bat which would run EXEC commands or files to do things like set up the Red Function Keys and set Default Drive and Disc Number. The !BOOT is only invoked by the Shift-Break or by *EXECing it so doesn't quite do the same thing.
You can use one of the keyboard link switches to invert the sense of SHIFT-BREAK (so it will always invoke !BOOT, unless the shift key is pressed). That's the only way I can think to run something automatically on power up.

Dave

User avatar
Wheel_nut
Posts: 183
Joined: Wed May 01, 2019 12:46 pm
Location: West of Scotland
Contact:

Re: Adding a Raspberry Pi Second Processor running PiTubeDirect using KenLowe's Level-Shifter Interface

Post by Wheel_nut » Mon Mar 30, 2020 6:20 pm

hoglet wrote:
Mon Mar 30, 2020 5:32 pm
Wheel_nut wrote:
Mon Mar 30, 2020 5:05 pm
When the Beeb Boots, it shows just a flashing Cursor and needs a Break to display the normal startup messages.
Question 1: Should this be a Ctrl-Break (which Clears Function Key Settings) or is just a Break OK?
Either should be fine.

(It's a shame this case now hangs on a Model B on power up. It's down to how quickly the Pi boots compared to the Beeb. The Pi Foundation firmware blob as got more complex over time, which has resulted in slower boot times.)
Amazing that 1980's tech boots quicker than 2010's Technology! :roll: When I get around to it, I might increase the 555 Timer delay on the Beeb to overcome this quirk, now that I know what it is.
Wheel_nut wrote:
Mon Mar 30, 2020 5:05 pm
Question 2: With Tube Co-Processors 0 or 1 enabled, the "Ready" Prompt changed from > to * and Star commands can be entered without another Star. Why is this? ... and are non Star commands invalid? Do I have to type *Basic to get back to a > Prompt?
Are you doing a Ctrl-BREAK after *FX 151,230,0?

If you do this, you should get a > prompt.
OK, Ctrl-Break gets me a > Prompt. Am I correct that the *FX 151,230,n is only activated after the Ctrl-Break?
Wheel_nut wrote:
Mon Mar 30, 2020 5:05 pm
Question 3: Can the standard games on the Beeb.MMB compendium be run with Co-Processor 0 or 1 enabled? If so, How?
No they can't, and as far as I know, the only solution is to disable the second processor.
OK, Understood
Wheel_nut wrote:
Mon Mar 30, 2020 5:05 pm
Question 4: This is more of a WIBNI ... but wouldn't it be nice if the Beeb had the equivalent of an Autoexec.bat which would run EXEC commands or files to do things like set up the Red Function Keys and set Default Drive and Disc Number. The !BOOT is only invoked by the Shift-Break or by *EXECing it so doesn't quite do the same thing.
You can use one of the keyboard link switches to invert the sense of SHIFT-BREAK (so it will always invoke !BOOT, unless the shift key is pressed). That's the only way I can think to run something automatically on power up.

Dave
I hadn't thought of that. Another thing to play with when it gets to the top of my list...

Thank you Dave and stay safe, - Robin
#1 BBC Model B Issue 7 + 1770 DFS + Dual TEAC Floppy
#2 BBC Model B Issue 7 + 8271 DFS + Dual Floppy + Speech + PiTubeDirect on KenLowe's Tube Level Shifter
#3 BBC Model B Issue 7 + 8271 DFS + Cumana Single Floppy

User avatar
hoglet
Posts: 8949
Joined: Sat Oct 13, 2012 6:21 pm
Location: Bristol
Contact:

Re: Adding a Raspberry Pi Second Processor running PiTubeDirect using KenLowe's Level-Shifter Interface

Post by hoglet » Mon Mar 30, 2020 6:36 pm

Wheel_nut wrote:
Mon Mar 30, 2020 6:20 pm
OK, Ctrl-Break gets me a > Prompt. Am I correct that the *FX 151,230,n is only activated after the Ctrl-Break?
That's not quite correct.

The Pi can't tell whether Ctrl is pressed or not, so it will switch to the new Co Pro regardless of the break type.

However, the Beeb OS only transfers the langauge (i.e. BASIC) to the Co Pro on a Ctrl-BREAK.

So, if you just press break you get the new Co Pro but without any language running, hence the * prompt (which comes from the Co Pro's CLI).

Dave

User avatar
Wheel_nut
Posts: 183
Joined: Wed May 01, 2019 12:46 pm
Location: West of Scotland
Contact:

Re: Adding a Raspberry Pi Second Processor running PiTubeDirect using KenLowe's Level-Shifter Interface

Post by Wheel_nut » Mon Mar 30, 2020 7:02 pm

hoglet wrote:
Mon Mar 30, 2020 6:36 pm
Wheel_nut wrote:
Mon Mar 30, 2020 6:20 pm
OK, Ctrl-Break gets me a > Prompt. Am I correct that the *FX 151,230,n is only activated after the Ctrl-Break?
That's not quite correct.

The Pi can't tell whether Ctrl is pressed or not, so it will switch to the new Co Pro regardless of the break type.

However, the Beeb OS only transfers the langauge (i.e. BASIC) to the Co Pro on a Ctrl-BREAK.

So, if you just press break you get the new Co Pro but without any language running, hence the * prompt (which comes from the Co Pro's CLI).

Dave
OK, Got it! that explains exactly what I am seeing. I hadn't attributed the * Prompt to the Co Processor's CLI.

Robin
#1 BBC Model B Issue 7 + 1770 DFS + Dual TEAC Floppy
#2 BBC Model B Issue 7 + 8271 DFS + Dual Floppy + Speech + PiTubeDirect on KenLowe's Tube Level Shifter
#3 BBC Model B Issue 7 + 8271 DFS + Cumana Single Floppy

Post Reply