Upgrading serial port for higher speed / more midi stability

Troubles with your machine? Just want to speak about the latest improvements? This is the place!

Moderators: Mug UK, Zorro 2, Greenious, spiny, Moderator Team

User avatar
Foxie
Captain Atari
Captain Atari
Posts: 354
Joined: Wed Feb 03, 2016 7:12 pm

Re: Upgrading serial port for higher speed / more midi stability

Postby Foxie » Fri Jan 26, 2018 9:45 pm

hasbab wrote:there is a fairly extended discussion on gearslutz about midi latency and jitter with some info about the ST and dongles if that's of any use to any of you


That pretty much confirms my suspicions that Cubase and Notator have pretty lousy timing! There is definitely a need for a MIDI sequencer that takes full advantage of the ST.

In any case, regardless of how bad Cubase performs in reality my aim is to design the actual interface to perform to better than 0.032ms of jitter and latency. Then if better software is developed it can really be exploited.

MIDI input via the cartridge port will always have a jitter, that can never be avoided. But MIDI input via the printer port can actually be as tight as the CPU will allow. In theory a cartridge port device like Midex or Unitor can provide perfectly tight timing on output. But it seems existing software does a poor job of exploiting this.


Miguel wrote:When I noticed the two ports and DIP switches I thought they are either for daisy-chaining or configuring the MM1 for some other platform like the DIP switches on Steinberg's MIDI-3.


At this point I'm almost certain it's something to do with daisy chaining. The unit I've been looking at has the first DIP switch off and the next four on. The fifth DIP switch does something different. So I think turning off the first DIP switch might make the unit the first in the chain.

Sadly, the MM1 driver does not have any provision for supporting daisy chaining. It appears hard-coded to 8 ports. But the Starport driver obviously supports it.

I'm making progress with the disassembly. I might be able to modify it for 16/32 port support in the future. Obviously that's never going to happen with a real MM1 seeing how rare they are. But the clone would be easy to daisy chain then (subject to total cable length limitations!)

I have some hardware in mind already for the clone. Only about 6 ICs, so it will be easy to build. I could include two MIDI inputs in addition to the 8 outputs. But you'd need a special driver to use the inputs. And the inputs won't be compatible with daisy-chaining (you need to choose between using four devices for 32 outputs only, or one device for 2 in 8 out with a DIP switch). But I think that's a fair limitation?

Of course it might turn out that Cubase simply can't cope effectively with more than 8 MIDI ports anyway without severe lag. In which case I'll ditch the daisy chaining feature. It kind of amazes me that the Starport ever supported 32 MIDI outputs from a single ST. That's crazy!

User avatar
edingacic
Captain Atari
Captain Atari
Posts: 163
Joined: Mon Sep 07, 2015 5:16 pm
Location: Austria
Contact:

Re: Upgrading serial port for higher speed / more midi stability

Postby edingacic » Fri Jan 26, 2018 10:06 pm

Foxie ATARI is known for a certain swing feel so that jitter you are talking about might be it. Free music :). If ATARI is lousy with MIDI imagine how bad modern PC is then. We really need something more modern ... if you can implement all of the features like we have in Cubase or Notator in a new sequencer then we might have a winner :)

User avatar
Foxie
Captain Atari
Captain Atari
Posts: 354
Joined: Wed Feb 03, 2016 7:12 pm

Re: Upgrading serial port for higher speed / more midi stability

Postby Foxie » Sat Jan 27, 2018 12:11 am

edingacic wrote:Foxie ATARI is known for a certain swing feel so that jitter you are talking about might be it. Free music :). If ATARI is lousy with MIDI imagine how bad modern PC is then.


Oh yeah, modern IBMs and Macs are just terrible. I don't even like the user experience, let alone the MIDI performance. You can tighten up MIDI output by using a timestamping MIDI interface, but there's lots of caveats. Like problems with MIDI input and thru, and compatibility problems with software. If Yamaha or Apple were sufficiently interested, they could design a MIDI interface that integrates deeply with the sequencer and provides good accuracy. But I doubt they'll ever be interested in "old school MIDI." Yamaha just want to sell you Montages with USB, and Apple just think all you need in a studio is an iPad.

A 1-2ms jitter from an Atari MIDI expander is pretty loose when compared to the theoretical best. But compared to USB, it's fantastic! I've heard people reporting jitter of 10-20ms on USB. You're usually better off with an Atari. Keep the system simple and fast. And it might be the MM1 provides much better performance than Midex and other expanders.

My dream music setup would be a Firebee running a sequencer of my own design, and a Falcon CT60 running Cubase Audio with ADAT interface - locked together with MIDI time code. But I think the latter is just a dream, considering the high cost of a stock Falcon let alone a maxed out Cubase Audio rig!

User avatar
edingacic
Captain Atari
Captain Atari
Posts: 163
Joined: Mon Sep 07, 2015 5:16 pm
Location: Austria
Contact:

Re: Upgrading serial port for higher speed / more midi stability

Postby edingacic » Sat Jan 27, 2018 12:36 am

Foxie are you familiar with facebook group Atari ST musicians network? I was in contact with two original CuBase developers and one told me about Midex 8 Steinberg´s LTB- technology. Someone few years ago made a driver after long time. https://www.steinberg.net/index.php?id=915&L=1. there is no support as I understand a developer working at steinberg on his own time without support from the company made a driver for windows 7,8,8.1 and as I understand it works with windows 10 also.

I was thinking that maybe that could be a solution to merge the two wolds of ATARI and modern sequencers but I am not sure if the timing is any good.
You do not have the required permissions to view the files attached to this post.

User avatar
Foxie
Captain Atari
Captain Atari
Posts: 354
Joined: Wed Feb 03, 2016 7:12 pm

Re: Upgrading serial port for higher speed / more midi stability

Postby Foxie » Sat Jan 27, 2018 2:04 am

edingacic wrote:Foxie are you familiar with facebook group Atari ST musicians network?


I'm not familiar with that. Then again, I don't have Facebook!

edingacic wrote:I was in contact with two original CuBase developers and one told me about Midex 8 Steinberg´s LTB- technology. Someone few years ago made a driver after long time. https://www.steinberg.net/index.php?id=915&L=1. there is no support as I understand a developer working at steinberg on his own time without support from the company made a driver for windows 7,8,8.1 and as I understand it works with windows 10 also.

I was thinking that maybe that could be a solution to merge the two wolds of ATARI and modern sequencers but I am not sure if the timing is any good.


I don't know much about the Midex 8, but I guess it should perform pretty well for output-only. The trick is making sure the software is compatible with it. The big problem comes if you want MIDI thru or recording, I'm not sure if it even time stamps MIDI input and it can't do anything about MIDI thru problems.

I suppose someone might be able to get the Midex 8 working on an Atari with USB, but I have no idea how! If you disable TOS, it's not really necessary to timestamp on an Atari since the timing can be so tight. But I think there are some overheads in Cubase specifically which make it perform worse than the ST could in theory.

I don't suppose those developers have any info to share about the MROS drivers or their Atari interfaces?

User avatar
Foxie
Captain Atari
Captain Atari
Posts: 354
Joined: Wed Feb 03, 2016 7:12 pm

Re: Upgrading serial port for higher speed / more midi stability

Postby Foxie » Sat Jan 27, 2018 4:22 am

I've done some further tests on the MM1 driver. Things are getting more interesting now!

With a periodic 0.32ms interrupt, the MM1 driver performs as badly as it did with instantaneous interrupts. On an 8MHz system, it can only saturate one port at a time. It's no better than Export!

Cranking up the CPU speed to 32MHz is a completely different matter. Now, the behaviour of the driver changes. It starts sending out MIDI events much faster, and on multiple ports simultaneously. I measured 2ms to transmit 4 events on port 1, 4 events on port 2, and one event each on ports 3-8. That's enough bandwidth to saturate all 8 outputs simultaneously!

So, you might conclude that any serious MIDI user should rush out and get a TT. But, that might not be the case. I have a feeling it might be the ratio between the external clock and the CPU speed that matters - not the absolute CPU speed. Some more testing will follow shortly. At the very least, I would expect an 8MHz ST to be able to saturate two ports.

Looking at the photos, the MM1 does have some limited buffering on-board. It can accept two bytes for each MIDI port plus a further two bytes in a global queue. The driver seems to be aware of this fact, and I think the clock speed might be lower to take into account the buffering. Another thing that will help answer this is running a test program on a real MM1 to see how it responds. I'm making a list of parameters to test in that program.

User avatar
edingacic
Captain Atari
Captain Atari
Posts: 163
Joined: Mon Sep 07, 2015 5:16 pm
Location: Austria
Contact:

Re: Upgrading serial port for higher speed / more midi stability

Postby edingacic » Sat Jan 27, 2018 2:43 pm

Nice progress Foxie ;) When you are ready to with the test program we are going to run it on Falcon and maybe he can find a TT030 also.

User avatar
Foxie
Captain Atari
Captain Atari
Posts: 354
Joined: Wed Feb 03, 2016 7:12 pm

Re: Upgrading serial port for higher speed / more midi stability

Postby Foxie » Sat Jan 27, 2018 9:22 pm

edingacic wrote:Nice progress Foxie ;) When you are ready to with the test program we are going to run it on Falcon and maybe he can find a TT030 also.


I've started work on the test program. I plan to output the statistics to a text file, is it possible to send the text file back to me when it's generated?

I tried decreasing the clock frequency, but no matter what I do I can't get an 8MHz system to run smoothly. Once I see how the real MM1 behaves, I'll be able to answer this with certainty. But so far, it looks like Cubase users absolutely need a 16MHz system to drive multiple outs. I reckon it should be possible to make a faster sequencer which performs well on an 8MHz machine. But as far as Cubase goes 16MHz+ is needed.

The increase between 8MHz and 16MHz is so dramatic, I almost suspect I'm doing something wrong - or there's an issue in Cubase that limits its performance. Here are the stats:

14 MIDI events transmitted simultaneously, four on the first two outs, one on each of the remaining outs.
36 bytes of MIDI data total
Theoretical time needed to transmit all these events on a single MIDI port: 11.5ms
Theoretical time needed to transmit the events on an 8-out interface: 2.9ms
8MHz system: 15.6ms (less than one port of MIDI bandwidth! You're better off using the Atari's MIDI out only!)
16MHz 5.4ms (enough bandwidth to saturate 4.3 MIDI outs)
32MHz 2.2ms (enough bandwidth to saturate all 8 outs)

Unfortunately, if the large body of Cubase users see these stats the price of MegaSTEs will go through the roof!

User avatar
edingacic
Captain Atari
Captain Atari
Posts: 163
Joined: Mon Sep 07, 2015 5:16 pm
Location: Austria
Contact:

Re: Upgrading serial port for higher speed / more midi stability

Postby edingacic » Sat Jan 27, 2018 10:59 pm

is it possible that the emulator is not giving you the right stats? Yes it is possible to give you back the text file no problem.

User avatar
Foxie
Captain Atari
Captain Atari
Posts: 354
Joined: Wed Feb 03, 2016 7:12 pm

Re: Upgrading serial port for higher speed / more midi stability

Postby Foxie » Sat Jan 27, 2018 11:06 pm

edingacic wrote:is it possible that the emulator is not giving you the right stats?


I'm not entirely sure. There are some shortcomings in the emulator definitely. The alternative would be to find someone with both an MM1 and a logic analyzer, which isn't very likely! Though if the MM1 owner also has some kind of multi-track recorder, it might be possible to measure its real performance by plugging the MIDI ports into the recorder's audio inputs. You could then look at the recorded waveforms to see exactly how much delay there is.

I'm actually interested to also test the driver for the Soundpool 4-out interface. Do you have the driver for that? I'd be curious if the same delays are present there.

I don't think there's anything to worry about with using a Falcon on the MM1. It should deliver very good performance. I'm just not entirely sure there's any point in 1040ST owners adding an MM1 to their rig without also adding an accelerator.

User avatar
edingacic
Captain Atari
Captain Atari
Posts: 163
Joined: Mon Sep 07, 2015 5:16 pm
Location: Austria
Contact:

Re: Upgrading serial port for higher speed / more midi stability

Postby edingacic » Sat Jan 27, 2018 11:14 pm

What I think I heard people say about Emulator and especially about crack version of Cubase is that it has timing problems but I am not sure also. Might be that real Cubase with dongle has better performance and on real hardware behaves really different. Yes, I have MO4 driver and I can test it on my TT030. I don't have a multitrack recording yet but soon I am getting better audio interface to connect from my mixer. I know my friend has his Falcon connected to multiple outs to another pc where he records so that could be a good test also. I will send you Mo4 driver when I get to it

User avatar
charles
10 GOTO 10
10 GOTO 10
Posts: 2254
Joined: Tue Aug 17, 2004 12:11 am
Location: ont. Canada
Contact:

Re: Upgrading serial port for higher speed / more midi stability

Postby charles » Sun Jan 28, 2018 4:01 am

it isn't a delay the mm1 has so it can pick up active sensing signal?
atari is my lifestyle,not a hobby.
HOLD ON ! ! !,
Im printing unreadable characters ...!

User avatar
Foxie
Captain Atari
Captain Atari
Posts: 354
Joined: Wed Feb 03, 2016 7:12 pm

Re: Upgrading serial port for higher speed / more midi stability

Postby Foxie » Tue Jan 30, 2018 1:03 am

edingacic wrote:What I think I heard people say about Emulator and especially about crack version of Cubase is that it has timing problems but I am not sure also.


It's possible there's some issue with the cracked version. I've heard MROS has issues multitasking in the cracked copy. But it's also possible that 8MHz simply isn't enough, considering the considerable complexity of MROS. What's really needed is someone with a genuine dongle and multi-out interface to stick a logic analyzer on the outputs and have a really close look. Or at least a multi-track recorder or audio interface (it would need to be measured from the MIDI outputs plugged directly into the audio recorder, not recording the output from synthesisers - because synthesisers often have a latency and jitter of their own).

Of course MegaSTE and Falcon owners have nothing to worry about!


edingacic wrote:I will send you Mo4 driver when I get to it


I've managed to track down a copy online, so don't worry about that for now (unless your copy is different in some way?)

I had a quick look at the protocol, and it looks simple at first. But like the MM1 driver, it's picky about handshaking. In fact it's even more picky than the MM1! There's also an unknown 0-byte command which I don't know the function of yet. Performance-wise it looks about the same as the MM1 - I'm seeing the same slowdown at 8MHz, but it goes plenty fast enough at 16MHz+.

Since the protocol is so similar to the MM1, I'm going to make a slightly modified version of my test program for the Soundpool. Would you mind running that on the MO4?

Since I can't see any performance benefits to using the MO4 at the moment, I think it's best to focus on cloning the MM1. But it would be nice to know how the MO4 works to implement support in a new sequencer.

charles wrote:it isn't a delay the mm1 has so it can pick up active sensing signal?


I don't think it's related to active sensing - the MM1 has no intelligence on-board, so it can't differentiate between different MIDI events. I think Cubase probably ignores active sensing, or at least many sequencers seem to.

User avatar
edingacic
Captain Atari
Captain Atari
Posts: 163
Joined: Mon Sep 07, 2015 5:16 pm
Location: Austria
Contact:

Re: Upgrading serial port for higher speed / more midi stability

Postby edingacic » Tue Jan 30, 2018 1:30 pm

Foxie I am ready to test your program with TT030 & SoundPoolMo4. I found out that SoundPool is todays RME. So I know these guys know what they are doing they are best in latency even today for audio :). Do you want pictures of SoundPool Mo4 internals?

User avatar
Foxie
Captain Atari
Captain Atari
Posts: 354
Joined: Wed Feb 03, 2016 7:12 pm

Re: Upgrading serial port for higher speed / more midi stability

Postby Foxie » Tue Jan 30, 2018 3:24 pm

edingacic wrote:Foxie I am ready to test your program with TT030 & SoundPoolMo4.


I'm still working on it, it should be ready soon ^.^

edingacic wrote:Do you want pictures of SoundPool Mo4 internals?


I've seen a very low-res pic of the MO4, but I couldn't make out which chips are used. If you wouldn't mind taking some pics that might be interesting. From what I could see, it looks like they used a CPLD and a GAL but I'm not 100% certain. I don't think it's possible to deduce much about the protocol from looking at the internals - unlike the MM1 which is entirely exposed in its workings.

The protocol is pretty simple: you write a byte to select which ports need to be addressed, and then one or more data bytes. One for each port, starting with 1. The select byte is a bitfield to indicate which ports are addressed (when a bit is set). This is a bit more efficient than the MM1 because it reduces selection byte traffic, but I doubt it makes a lot of difference in reality. The mysterious 0 selection byte has me slightly puzzled. It probably resets the state of the device back to the default - at startup they send four 0s for resetting. But I wonder if it has a side-effect like clear interrupt?

In theory, the protocol of the MO4 allows up to 8 ports. The MM1 protocol could allow up to 256 ports (although I suspect some bits are used for printer enable/disable).

User avatar
edingacic
Captain Atari
Captain Atari
Posts: 163
Joined: Mon Sep 07, 2015 5:16 pm
Location: Austria
Contact:

Re: Upgrading serial port for higher speed / more midi stability

Postby edingacic » Wed Jan 31, 2018 12:47 am

Here are the pictures ... take your time when its ready I can test it :)

20170831_232106.jpg

20170821_170922.jpg

20170821_153550.jpg

20170920_125615.jpg

20170920_125204.jpg

20170920_125153.jpg

1.jpg
You do not have the required permissions to view the files attached to this post.

User avatar
Foxie
Captain Atari
Captain Atari
Posts: 354
Joined: Wed Feb 03, 2016 7:12 pm

Re: Upgrading serial port for higher speed / more midi stability

Postby Foxie » Wed Jan 31, 2018 3:43 am

edingacic wrote:Here are the pictures ... take your time when its ready I can test it :)


You have a nice setup there ^.^

I've got an S6000 too, but I think I'd also like an E6400 due to the warmth of sound. I think the E-mu samplers run on the 680x0, their synths definitely do.

Thanks for the internal pics, it looks quite simple! All the shifting logic is surely buried in that CPLD, but CPLDs don't have many registers. I imagine the buffer size is small like the MM1. I'm not sure what that pin header is for, is it just an extension of the printer port signals?

User avatar
edingacic
Captain Atari
Captain Atari
Posts: 163
Joined: Mon Sep 07, 2015 5:16 pm
Location: Austria
Contact:

Re: Upgrading serial port for higher speed / more midi stability

Postby edingacic » Wed Jan 31, 2018 2:08 pm

Thanks I really think s6000 is the best for clean sound without color... also I have it fully expanded so its acting like 2 sampler in one. EMU e4X is also fully expanded and I use it to add character with filters. Roland s760 probably the best time stretching algorithm just sound so nice. DX7 i use to make all kinds of crazy sounds.

I have no idea what this pin header is for it is not used at all. Might be for expanding more of these? Who knows

User avatar
Foxie
Captain Atari
Captain Atari
Posts: 354
Joined: Wed Feb 03, 2016 7:12 pm

Re: Upgrading serial port for higher speed / more midi stability

Postby Foxie » Mon Feb 05, 2018 12:27 am

I've got the test program ready - there's versions for both the MM1 and MO4.

When you're ready, I'd love to see the results on both devices ^.^

The programs along with a readme.txt file are included in the attached zip.

MIDITEST.ZIP


Thanks!


edingacic wrote:Thanks I really think s6000 is the best for clean sound without color... also I have it fully expanded so its acting like 2 sampler in one. EMU e4X is also fully expanded and I use it to add character with filters. Roland s760 probably the best time stretching algorithm just sound so nice. DX7 i use to make all kinds of crazy sounds.

I have no idea what this pin header is for it is not used at all. Might be for expanding more of these? Who knows
You do not have the required permissions to view the files attached to this post.

User avatar
edingacic
Captain Atari
Captain Atari
Posts: 163
Joined: Mon Sep 07, 2015 5:16 pm
Location: Austria
Contact:

Re: Upgrading serial port for higher speed / more midi stability

Postby edingacic » Mon Feb 05, 2018 1:29 am

Hi Foxie,

I will run the MO4 test hopefully tomorrow. I have sent the file for MM1 testing and as soon as I get this data back I will post it here.

nice work :)

dbsys
Captain Atari
Captain Atari
Posts: 335
Joined: Fri Aug 31, 2012 6:11 am
Location: Germany

Re: Upgrading serial port for higher speed / more midi stability

Postby dbsys » Mon Feb 05, 2018 7:26 pm

@Foxie, although I was only reading here, I took the freedom to perform your MO4 test with my MO4, connected to a 1040STE with TOS 2.06.

The log file is attached.

MO4LOG00.TXT


The results will hopefully make sense to you.

I will be happy to test more, if needed. Let me know.
You do not have the required permissions to view the files attached to this post.

dbsys
Captain Atari
Captain Atari
Posts: 335
Joined: Fri Aug 31, 2012 6:11 am
Location: Germany

Re: Upgrading serial port for higher speed / more midi stability

Postby dbsys » Mon Feb 05, 2018 7:34 pm

One more log file...

MO4LOG01.TXT
You do not have the required permissions to view the files attached to this post.

guus.assmann
Atari freak
Atari freak
Posts: 64
Joined: Tue Dec 13, 2005 10:34 pm
Location: Ede Netherlands

Re: Upgrading serial port for higher speed / more midi stability

Postby guus.assmann » Mon Feb 05, 2018 8:46 pm

Hello,

Does anyone have the MROS files from Steinberg that work on a Falcon?
I've tried to modify a Midex+ to run on a Falcon. But the testprogram keeps telling it cannot find a file in the MROS folder.
The modified Midex doesn't work on a Mega ST anymore. (But can be made switchable real easy.)

BR/
Guus
Guus Assmann

User avatar
Foxie
Captain Atari
Captain Atari
Posts: 354
Joined: Wed Feb 03, 2016 7:12 pm

Re: Upgrading serial port for higher speed / more midi stability

Postby Foxie » Mon Feb 05, 2018 11:06 pm

dbsys wrote:@Foxie, although I was only reading here, I took the freedom to perform your MO4 test with my MO4, connected to a 1040STE with TOS 2.06.

The log file is attached.


Fantastic, thanks! I'll decipher the results later tonight ^.^


guus.assmann wrote:Does anyone have the MROS files from Steinberg that work on a Falcon?
I've tried to modify a Midex+ to run on a Falcon. But the testprogram keeps telling it cannot find a file in the MROS folder.
The modified Midex doesn't work on a Mega ST anymore. (But can be made switchable real easy.)


There's MIDEXFAL.DR in the Cubase Audio crack package, I've attached it. It might only work with Cubase Audio, but not owning a Falcon I've no way of testing it. You'll need to rename it to DRV.

Did you manage to figure out what the modification actually does? My guess is that it removes the skip-every-other-access behaviour of the Midex to accommodate the 68030. Do you know if it works on a TT?

I'm not sure what differences there are between the Falcon and ST cartridge ports - on the schematic they look more or less the same. I assume accesses to the cartridge port are slowed to 8MHz for compatibility?
You do not have the required permissions to view the files attached to this post.

ranix
Atari maniac
Atari maniac
Posts: 79
Joined: Sun Jan 14, 2018 8:01 pm

Re: Upgrading serial port for higher speed / more midi stability

Postby ranix » Tue Feb 06, 2018 1:19 am

Doesn't Cubase actually have pretty rock solid timing on Atari with one pair of MIDI ports, and the timing issues arise as a result of using expansions to get 3+ midi in/out ports? I assumed this was a limitation of the 8mhz Atari or of any i/o controllers or busses between the CPU and MIDI ports. If I understand correctly the onboard midi ports are connected to an ACIA chip with a fat pipe to the 68k (8 bit parallel? seems excessive, maybe something is in between). But as I understand it the CPU can pretty much drive this thing at ludicrous speed.

I'm looking forward to figuring out whether or not there are differences in timing with the Unitor at high load between when the CPU is running at 8mhs vs 16mhz


Social Media

     

Return to “Hardware”

Who is online

Users browsing this forum: Gaiyan and 7 guests