BeebSID

for bbc micro/electron hardware, peripherals & programming issues (NOT emulators!)
User avatar
PitfallJones
Posts: 447
Joined: Fri Feb 22, 2008 3:44 pm
Contact:

BeebSID Disk#6 - Madonna

Post by PitfallJones » Thu Oct 07, 2010 1:31 pm

Here's a Madonna disk!

I've discovered a lot of SIDs have a play address of $0000.

After reading up about it - it appears the sid_init call will setup an IRQ routine at the C64 vector $314. $314 is some graphics workspace on the BBC so shouldn't matter. Anyhow as the BBC IRQ routine has to do some BBC special stuff you can't call the C64 one.

I was trying to be clever with the following code to call down to their IRQ routine from my BBC one, but it doesn't seem to work, anyone got any ideas? (I can post a SID that works like this)

Also SIDs don't seem to store a song length - anyone know anything about that?



._BBC_IRQ:

....

PHP
LDA #HI(next_addr)
PHA
LDA #LO(next_addr)
PHA
JMP ($0314) ;;does an RTI at the end of the SID IRQ
.next_addr:
RTI


beebsid6.jpg
beebsid6.jpg (17.19 KiB) Viewed 1923 times
Attachments
Beebsid6.zip
(49.97 KiB) Downloaded 221 times

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

Re: BeebSID

Post by MartinB » Thu Oct 07, 2010 4:20 pm

Nice one yet again PJ - I will give that a play later and report back :D

On that bit of code, I think I get what you're trying to do but in trying to simulate an IRQ for the C64 RTI, the normal order is PCH, PCL and finally P(status) so on a quick look, shouldn't that PHP should be after the Lo push?

I wouldn't mind seeing some more detail if you can post anything useful or maybe you could put together and attach an info bundle? Not sure I can join in immediately but I'd like to get more into BeebSID programming as time permits. I really should, shouldn't I... :wink:

User avatar
SarahWalker
Posts: 1176
Joined: Fri Jan 14, 2005 3:56 pm
Contact:

Re: BeebSID

Post by SarahWalker » Thu Oct 07, 2010 6:45 pm

PitfallJones wrote:I didn't know the SID could do PCM - we could have speech!

I'm amazed it works at all - at 44100 Hz that leaves 1,000,000/44,100 = 22 cycles per sample - no time to do anything... and how much song can you fit in 64K?
There's an interesting article on it here : http://www.livet.se/mahoney/cubase64 - like most demo stuff it's cheating a lot but still very clever.

There are all sorts of ways to play PCM samples on the SID. The traditional way is to put a 4-bit value into $D418 (the volume register). This works on 6581 due to a volume leak internal to the chip - on an 8580 you either have to create a standing voltage using one of the voices, or put a voltage on the Audio In pin.

The more modern way uses the triangle waveform and some very clever timing. I'm not entirely sure how it works, but the results are impressive : http://www.youtube.com/watch?v=ZMioAPZcays (about a minute in)

User avatar
PitfallJones
Posts: 447
Joined: Fri Feb 22, 2008 3:44 pm
Contact:

Re: BeebSID

Post by PitfallJones » Fri Oct 08, 2010 6:42 pm

@tom
- excellent document - he really goes into it, in detail - and source code!

@martin
- I Tried the PHP after as well with no luck - you do hear it playing the first note so it does get called properly but it never returns.... I'll email you my example.

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

Re: BeebSID

Post by MartinB » Tue Oct 12, 2010 11:50 pm

Hi PJ - can you have a read of this post (by me) and see if you can enlighten me as to what might be going on with your compilation discs. (e.g. how do you produce your disc images.)

User avatar
PitfallJones
Posts: 447
Joined: Fri Feb 22, 2008 3:44 pm
Contact:

Re: BeebSID

Post by PitfallJones » Wed Oct 13, 2010 12:09 am

I create the disk image from a 'c' program I've written on the PC, rather than a BBC - that must be the source of the problem.

So as you say it sounds like I'm creating the directory in the wrong order - I'll try it with higher sector first then...

- PJ

User avatar
retroclinic
Posts: 3027
Joined: Thu Jul 03, 2008 1:22 pm
Location: East Riding of Yorkshire
Contact:

Re: BeebSID

Post by retroclinic » Wed Oct 13, 2010 12:17 am

HAXX!!!!!!1!! :!: :shock: :!:

http://cgi.ebay.co.uk/110597870187

BeebSID has been cloned into a SAMSID?!?!?!
Image

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

Re: BeebSID

Post by MartinB » Wed Oct 13, 2010 7:27 am

Mark wrote:HAXX!!!!!!1!! :!: :shock: :!:
Couldn't have put it better :lol:

Oh well, they do say that imitation is the sincerest form..... :wink:

@ PJ : Actually I'm just relieved to hear that it's your own utility because I'd have had some work to do if that was a widespread layout! In one sense it matters not because as stand-alone discs they appear to work but I guess that sooner or later someone was going to get confused and you can always count on me to be that person :lol:

One thing though, if you remember I previously concluded that the <Shift><Break> problem appeared to some sort of timing issue so I wonder if it's related to the fact that your !BOOT files are at the opposite end of the disc to Sector 0 causing a longer than normal seek at boot :-k

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

Re: BeebSID

Post by MartinB » Wed Apr 27, 2011 9:20 pm

It's just emerged that the Issue 2 schematic isn't attached anywhere on this thread so here it is. (Full-size BMP version attached.)
BeebSID Issue 2.PNG
BeebSID Issue 2.PNG (92.08 KiB) Viewed 1656 times
Attachments
BeebSID Issue 2.zip
(76.06 KiB) Downloaded 110 times

Prime
Posts: 2723
Joined: Sun May 31, 2009 11:52 pm
Contact:

Re: BeebSID

Post by Prime » Wed Apr 27, 2011 10:21 pm

retroclinic wrote:HAXX!!!!!!1!! :!: :shock: :!:

http://cgi.ebay.co.uk/110597870187

BeebSID has been cloned into a SAMSID?!?!?!
Humm as I'm playing around with ZX80/81 hardware at the moment.....ZX-SID anyone ? :) :) :)

Cheers.

Phill.

Prime
Posts: 2723
Joined: Sun May 31, 2009 11:52 pm
Contact:

Re: BeebSID

Post by Prime » Thu May 05, 2011 11:36 pm

Is the source of the SID player available, I want to check how often it's bashing the SID registers, incase that's the cause of the slowness I'm experiencing with my SwinSID emulation.

Cheers.

Phill.

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

Re: BeebSID

Post by MartinB » Wed Jul 20, 2011 7:26 pm

@ Tom W : Hi Tom - someone has commented on You Tube and asked what the first piece of music is in this BeebSID demo. I think you told me once but I can't remember.... :-k ?

User avatar
SarahWalker
Posts: 1176
Joined: Fri Jan 14, 2005 3:56 pm
Contact:

Re: BeebSID

Post by SarahWalker » Wed Jul 20, 2011 7:51 pm

It's the intro music to Cubemagik.

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

Re: BeebSID

Post by MartinB » Wed Jul 20, 2011 8:20 pm

Ta :wink:

User avatar
sirmorris
Posts: 771
Joined: Wed Feb 11, 2009 12:18 pm
Location: oxfordshire uk
Contact:

Re: BeebSID

Post by sirmorris » Wed Jul 20, 2011 8:32 pm

Did I imagine it or did someone at InDa80s have an AtomSID going??

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

Re: BeebSID

Post by MartinB » Wed Jul 20, 2011 8:35 pm

I heard that malicious rumour too but in the absence of pictures and videos I'm treating it as a damn lie.... =;

User avatar
mga1103
Posts: 184
Joined: Mon Jan 24, 2011 4:00 pm
Location: Galway, Ireland
Contact:

Re: BeebSID

Post by mga1103 » Wed Jul 20, 2011 8:47 pm

(When I saw this thread active again, my heart skipped a beat! ...but, alas.. :( )

User avatar
Samwise
Site Admin
Posts: 1823
Joined: Mon Mar 14, 2005 9:13 pm
Contact:

Re: BeebSID

Post by Samwise » Wed Jul 20, 2011 9:01 pm

Sounds dubious to me Martin. Pretty unlikely they'd have everything to hand ... so unless they started ripping the pub fixtures down, I don't see how it would have happened ... ;)

Sam.

User avatar
sorvad
Posts: 2184
Joined: Wed Aug 24, 2005 12:13 pm
Location: Back of beyond
Contact:

Re: BeebSID

Post by sorvad » Wed Jul 20, 2011 9:05 pm

As impressive as the stuff always is at these shows I don't remember an AtomSid, only remember there being one Atom working there for a start and that was constantly running Chuckie Egg ! Very impressively actually

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

Re: BeebSID

Post by MartinB » Wed Jul 20, 2011 9:11 pm

You're right Sam & Steve, AtomSID is a ridiculous name that you'd remember for sure and what's more, I've just been through today's post and there's certainly no sign of a public performance rights royalties cheque... :-

User avatar
sirmorris
Posts: 771
Joined: Wed Feb 11, 2009 12:18 pm
Location: oxfordshire uk
Contact:

Re: BeebSID

Post by sirmorris » Wed Jul 20, 2011 9:15 pm

AtomSID lived for about 10 minutes - just long enough to successfully run the short demo program posted earlier in the thread. Alas after meeting with some wayward voltses from the back of a monitor it died soon after :(

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

Re: BeebSID

Post by MartinB » Wed Jul 20, 2011 9:26 pm

It is was true then :shock:

(It's probably the way you wrote it but I promise I'm not laughing on the inside... :wink:)

What popped - it wasn't the SID was it ? :(

User avatar
Samwise
Site Admin
Posts: 1823
Joined: Mon Mar 14, 2005 9:13 pm
Contact:

Re: BeebSID

Post by Samwise » Wed Jul 20, 2011 9:30 pm

naah, they found a replacement to check that.

Sam.

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

Re: BeebSID

Post by MartinB » Wed Jul 20, 2011 9:37 pm

Samwise wrote:naah, they found a replacement to check that.
Wow! That's some venue - not only is it a pub but there's SID chips just lying about the place... :D

User avatar
sirmorris
Posts: 771
Joined: Wed Feb 11, 2009 12:18 pm
Location: oxfordshire uk
Contact:

Re: BeebSID

Post by sirmorris » Wed Jul 20, 2011 9:47 pm

Not lying exactly, more ... mounted :) There is a display of broken computers literally screwed to the wall. I asked the landlord nicely and he said I could get the '64 down to check for a SID... Result! =D>

Still didn't work tho - same fault with new SID - I suspect some other circuitry got it...

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

Re: BeebSID

Post by MartinB » Thu Jul 21, 2011 9:42 pm

mga1103 (or 'A' Martin as I prefer to call him) wrote:When I saw this thread active again, my heart skipped a beat! ...but, alas.. :(
Curiously, a previous BeebSID PCB buyer has taken pity on wretched 'A' Martin's obvious despair and is returning an unused board for me to pass on to him :shock:. He's got the luck of the Irish this muppet look-alike.... :wink:

This has actually given me a thought - if there were sufficient interest (say 25) people interested in getting a PCB, someone (not me this time) could order another 25 and distribute them as I did for the first batch. That person would need about £150 up-front (or could take pre-paid orders) and I could supply the necessary Gerber files needed. (If the same supplier were used, they might even still have the patterns.)

Just a thought in case anyone feels so inclined :wink:

User avatar
mga1103
Posts: 184
Joined: Mon Jan 24, 2011 4:00 pm
Location: Galway, Ireland
Contact:

Re: BeebSID

Post by mga1103 » Thu Jul 21, 2011 9:54 pm

MartinB wrote:
mga1103 (or 'A' Martin as I prefer to call him) wrote:When I saw this thread active again, my heart skipped a beat! ...but, alas.. :(
Curiously, a previous BeebSID PCB buyer has taken pity on wretched 'A' Martin's obvious despair and is returning an unused board for me to pass on to him :shock:. He's got the luck of the Irish this muppet look-alike.... :wink:
...
Yippee !!! \:D/ \:D/ \:D/. Someone's just made me a happy camper :D . =P~ .
(Note to self: do the lotto tomorrow...just in case there's any more of that luck around :wink: ).

My 6581 and beeb are finally going to get together... :D

Thanks Martin...(and of course to the doner) =D> .

User avatar
mga1103
Posts: 184
Joined: Mon Jan 24, 2011 4:00 pm
Location: Galway, Ireland
Contact:

Re: BeebSID

Post by mga1103 » Thu Jul 21, 2011 10:23 pm

Now, in anticipation of becoming a BeebSID owner ( :D ), the mind is racing ahead and of course, questions arise:

I've seen various values mentioned earlier in this thread for the C1 & C2 caps (6800pF for the 9V 8580 and 1000pF/2200pF for the 12V 6581), which would appear to influence the audio quality output.

(1) As I'll be using the 6581, I'm just wondering if anyone's experimented with various values with this chip and if so, what were your findings?

(2) If I wanted to experiment with different cap values, I wouldn't want to torture my pcb to death with a solder iron, so has anyone successfully socketed caps before to allow for easy substitutions? Is there an off-the-shelf gizmo available?

(3) My local component suppliers (RS, Farnell, Maplin) don't seem to supply sticky pads with pole mounts (well, as far as I can tell), which seems a bit odd :roll: . [I'm already having visions of my BeebSID boxed! :wink: ]. Can anyone recommend a supplier?

Thanks in advance for any pointers & tips...!

-Martin.

User avatar
retroclinic
Posts: 3027
Joined: Thu Jul 03, 2008 1:22 pm
Location: East Riding of Yorkshire
Contact:

Re: BeebSID

Post by retroclinic » Thu Jul 21, 2011 11:02 pm

mga1103 wrote:(2) If I wanted to experiment with different cap values, I wouldn't want to torture my pcb to death with a solder iron, so has anyone successfully socketed caps before to allow for easy substitutions? Is there an off-the-shelf gizmo available?
You can always cannabalise a turned pin IC socket, if you don't fancy buying some SIL strip sockets
mga1103 wrote:(3) My local component suppliers (RS, Farnell, Maplin) don't seem to supply sticky pads with pole mounts (well, as far as I can tell), which seems a bit odd
Au contraire, RS and Farnell indeed do sticky posts, lots of different types (although I'd forgive you for not finding any on the RS website as they've sure screwed it up recently) - however RS 580-001 are one type I use, but there are others of different lengths, and for 3mm or 4mm PCB holes.

Mark.
Image

User avatar
mga1103
Posts: 184
Joined: Mon Jan 24, 2011 4:00 pm
Location: Galway, Ireland
Contact:

Re: BeebSID

Post by mga1103 » Thu Jul 21, 2011 11:41 pm

I certainly couldn't find those boys :oops: . Just what I was looking for. Will check out the SIL strip sockets.

Thanks Mark.

Post Reply