I'm debugging the service test code at the moment. After some of the recent decompilation work, I fancied something easy. Nevertheless there are still some cool things to be discovered.
One thing you'll notice in MAME, is that the "Motor Test" fails:
The motor test, which only runs if the DIP switches are set to the Moving cabinet type, essentially moves the cabinet from left to right. The limit switches activate at the extremities and the pot values from the motor are recorded. A magnet also detects the centre position.
I quickly hooked up a simulation of the motor hardware in the Jemu2 driver I coded, using knowledge from the decompilation. Here are the results:
Notice that there are no error messages, and the values are correctly recorded.
As far as I can see register 0x140001 works as follows:
Bit 3 = Set to indicate left limit reached
Bit 4 = Set to indicate centre reached
Bit 5 = Set to indicate right limit reached
Bit 4 = Set to indicate centre reached
Bit 5 = Set to indicate right limit reached
The desired motor position is written to register 0x140003.
The actual motor position can by read by writing '12' to the analogue select register 0x140012.
No comments:
Post a Comment