The UniBios & IR-Maze thread.

Razoola

Divine Hand of the UniBIOS,
Staff member
20 Year Member
Joined
Nov 12, 2002
Posts
4,662
MKL said:
You mean like a short extension that you add or remove depending on what logic state you need for that line? Sure, it could be done.

Yes it could be something like that or permanantly built into the lead/controller if your only ever going to plug it into the joystck ports.

I think its best to do it so the trackball works off joystick ports which have not been modded in any way. That way the game would work off any AES/MVS with out the need of modding that system first.

I'm quite intrested in seeing just how small you can make that PCB.

Raz
 

Razoola

Divine Hand of the UniBIOS,
Staff member
20 Year Member
Joined
Nov 12, 2002
Posts
4,662
Not that I know of.

Raz
 

werejag

Galford's Poppy Trainer
Joined
May 3, 2005
Posts
2,626
monthly post to say im interested in a homebrew interface for IM
 

Razoola

Divine Hand of the UniBIOS,
Staff member
20 Year Member
Joined
Nov 12, 2002
Posts
4,662
No more progress that I know of.

Raz
 

toodles

Zero's Secretary
Joined
Jul 14, 2005
Posts
157
MKL said:
But your help would be much needed here: what do you think about the possibility of building the custom interface that Raz pointed out?
Doesn't sound that hard. The banking system Raz wants should be easy; interpreting the trackball and spinner into 8 bit values sounds like the hardest part. I'm reading up on the 6 pin molex connectors arcade trackballs use to figure out how to use it.

Raz, can you put in a uber-stick test into the next uni-bios? I can certainly try to build any or all of these, but there is no way for me to test that it's working properly. Regular stick, mahjong controller, trackball, dual/quad stick, all of it, preferably simultaneously and with a setting to choose different specific controllers.

Thanks for the brain candy guys. Between this thread and some mame code, I think I actually figured out how to make a mahjong controller.
 

Razoola

Divine Hand of the UniBIOS,
Staff member
20 Year Member
Joined
Nov 12, 2002
Posts
4,662
I would not really want to put such an option in a release build, that said however I can certinally provide you with a custom version so it would display the stuff you need.

Raz
 

toodles

Zero's Secretary
Joined
Jul 14, 2005
Posts
157
Well, I can't find any simple 8 bit, tri-state buffers on a single chip, but I can find 8 bit tranceivers, but they all are enabled on low, not high. So, I'm thinking a single 74HCT138 to decode the three line bank select. Each one of the output pins (that were being used in that controller) would go to a single 74HCT245 that controls that bank. That takes care of part C in Raz's diagram. I can throw something together in Eagle if anyone thinks it'll help, but I'm not sure if there's a need.

Does every game poll all 8 banks? With what kind of frequency? I'm assuming once per vblank, but wanted to be sure. I also wanted to be sure that a normal game using just the stick and four buttons would still work fine if it only answered to bank 011. If it always polls all eight banks each frame, that also gives me a known good time to reset the trackball counter between checks.

Can you give me any idea what values IR Maze is considering? Very slow up, very slow down, very fast up, very fast right, etc. The way the arcade trackballs seem to work, it would seem that it probably sends an signed value, not an unsigned one, since the connector has one line horizontal direction, one for vertical direction, and one each horizontal and vertical speed (the ticks of the wheel). Hardware to adjust the 'sensitivity' of the trackball would be rough, so if I can match what the machine is expecting, it'd be easiest. Same information for spinner speed would be cool, but I assume it is the same ranges as the trackball.
 

werejag

Galford's Poppy Trainer
Joined
May 3, 2005
Posts
2,626
looked at maxim-ic.com ? they have some nice specialty chips
 

Razoola

Divine Hand of the UniBIOS,
Staff member
20 Year Member
Joined
Nov 12, 2002
Posts
4,662
toodles said:
Well, I can't find any simple 8 bit, tri-state buffers on a single chip, but I can find 8 bit tranceivers, but they all are enabled on low, not high. So, I'm thinking a single 74HCT138 to decode the three line bank select. Each one of the output pins (that were being used in that controller) would go to a single 74HCT245 that controls that bank. That takes care of part C in Raz's diagram. I can throw something together in Eagle if anyone thinks it'll help, but I'm not sure if there's a need.

Does every game poll all 8 banks? With what kind of frequency? I'm assuming once per vblank, but wanted to be sure. I also wanted to be sure that a normal game using just the stick and four buttons would still work fine if it only answered to bank 011. If it always polls all eight banks each frame, that also gives me a known good time to reset the trackball counter between checks.

Can you give me any idea what values IR Maze is considering? Very slow up, very slow down, very fast up, very fast right, etc. The way the arcade trackballs seem to work, it would seem that it probably sends an signed value, not an unsigned one, since the connector has one line horizontal direction, one for vertical direction, and one each horizontal and vertical speed (the ticks of the wheel). Hardware to adjust the 'sensitivity' of the trackball would be rough, so if I can match what the machine is expecting, it'd be easiest. Same information for spinner speed would be cool, but I assume it is the same ranges as the trackball.

The banks are read very fast... What happens is the game selects a bank, then waits in a loop and finally reads the vaules returnen. The wait loop is a few hundred CPU cycles with the CPU at 12MHZ. For an example here is the waitloop the normal bios uses.

C184F4 6100 000A BSR *+0xC [0xC18500]
C184F8 6100 0006 BSR *+0x8 [0xC18500]
C184FC 6100 0002 BSR *+0x4 [0xC18500]
C18500 4E71 NOP
C18502 4E71 NOP
C18504 4E71 NOP
C18506 4E71 NOP
C18508 4E71 NOP
C1850A 4E71 NOP
C1850C 4E75 RTS

Raz
 

toodles

Zero's Secretary
Joined
Jul 14, 2005
Posts
157
Output transition time for the HCT138 (Bank select): 19 ns
Output transition time to enable the HCT245: 49 ns
If that's accurate, then we are looking at it responding in less than a single cpu instruction's worth of time. :) The speed isn't a concern, but the frequency is. Is every bank checked every time by every game? How frequently is it checked? Can you give some example values for the trackball at various speeds?


Whatever circuit is made will have to count the number of speed ticks from the trackball, and reset the counter every so often at regular intervals. I'm hoping that every one of the 8 banks are checked every vblank, so I can have the bank after the trackball Y bank reset the speed counter, and similarly with the X speed counter.
 

Razoola

Divine Hand of the UniBIOS,
Staff member
20 Year Member
Joined
Nov 12, 2002
Posts
4,662
All banks are not checked, it depends on the game. I can't really give any sample values because I don't currently have a trakball myself. Normally the trackball x and y axis are read once per frame though.

I dont understand why the counter needs to be reset?

Raz
 

toodles

Zero's Secretary
Joined
Jul 14, 2005
Posts
157
The trackball spins the slotted wheel between a LED and receiver. The light goes through the slots, sending the line low when light hits the receiver, and high when the light is blocked. The faster the ball is spun, the faster (higher frequency) the 'clicks'. So, if you want to know how fast the trackball is going for the next frame, you reset the counter to 0, let the clicks kick up the counter, and then check at the end of the frame, and repeat. If the ball is going at a constant speed, let's say 100 clicks, then there will be 100 clicks on every frame. If we don't reset the counter, the counter will be constantly accelerating, even though the ball is at a constant speed. 100, 200, 300, 400, etc.etc. speed = distance/time. Counting the clicks gives us the distance, but only by resetting the counter at regular periods can we get the time.

Can you tell me what values are sent by the joystick hack to IRMaze, with and without the BC buttons pressed?
 

Razoola

Divine Hand of the UniBIOS,
Staff member
20 Year Member
Joined
Nov 12, 2002
Posts
4,662
Values written are 01,02,03.

The problem here is the trackball hardware sends the values and the NG hardware converts them. I miss out this conversion and only use end results so I don't know the actual values given by the trackball.

Looking at the code it only seems to change the banks between 00 and 01, it does not read other banks after so you could not use that to reset the counters. Why not simply reset the counter an x ammount of time after the bank is selected?

Raz
 
Last edited:

Nightmare Tony

*Account control passed, on to Tony's family.Ex Ro
Joined
Sep 19, 2001
Posts
1,029
am interested. Got an IR cart and 1C for it but no extra sub board. Been too busy to try and get it going with a trackball. Sigh. Will be watching out here...
 

TheNewGuy

n00b
Joined
May 12, 2010
Posts
8
Anyone please help me out.......

i have windjammers for my neogeo BUT the time limit and the point limit is WAY to short is there any bios that will help me extend the GREAT game i mean its over WAY to fat:hammer:
 

Xian Xi

JammaNationX,
15 Year Member
Joined
Dec 1, 2005
Posts
27,748
Sorry, Japan is for a higher score limit. If you want to change time limit go into your soft dip settings via your test button. If you have an AES you need a unibios and set it to arcade mode then change the softdips or use the cheat menu.
 

TheNewGuy

n00b
Joined
May 12, 2010
Posts
8
hi

Sorry, Japan is for a higher score limit. If you want to change time limit go into your soft dip settings via your test button. If you have an AES you need a unibios and set it to arcade mode then change the softdips or use the cheat menu.

that is what i want a higher score limit past 15 and a higher time limit whats the latest uni-bios?
 

distropia

SouthTown StreetSweeper
10 Year Member
Joined
Apr 28, 2010
Posts
1,075
Any advance?

It's more than 4 years since the thread was created and we don't have any homebrew interface sketch yet.
 

Neo Alec

Ned's Ninja Academy Dropout
20 Year Member
Joined
Dec 7, 2000
Posts
11,897
I read through this whole thread recently and was surprised to find it was never resolved. I thought someone had achieved trackball support through this method already. I guess it's too complicated to expect to just buy any old arcade trackball and expect to have a way of wiring it up.
 

Hewitson

Metal Slug Mechanic
Joined
Mar 6, 2008
Posts
2,198
It probably is, I'd expect different trackballs would have different interfaces and sensitivity levels.. However it shouldn't be difficult to make an interface for one particular model of trackball eg the Happ ones.
 

Mendel

Vanessa's Drinking Buddy
Joined
Sep 3, 2012
Posts
1,187
Received unibios 3.1 and it is all about awesome. I can even enter into the ingame menu with start+a+b+c. I didn´t know that would work, I was worried I would have to make and wire a select button :)
 
Top