-
Posts
3,651 -
Joined
-
Last visited
-
Days Won
169
Content Type
Profiles
Forums
Gallery
Downloads
Articles
Everything posted by johnparker007
-
Update since it's been a while Been working on stuff to do with classic style layouts, since the Oasis LayoutEditor will have a MAME Exporter in it, to create pure text layouts to go in MAME codebase... first signs of life, I can see some text!
-
That is a very high spec card wrt Arcade Sim. Ok so if you want I can remote into your PC with a program like TeamViewer and we'll very likely be able to get this working Apologies it's a faff, on the new Oasis project, it doesn't do anything 'weird' (Arcade Sim hacks its local copy of MFME.exe) so it should work for everyone, but it's a long way off. Feel free to DM me if you want to set up a session where I remote in and diagnose and apply whatever fix is needed to get it working on your machine
-
Direct link to the post with the fix: This also needs you to have the latest MFME installed on your system, and updated to the latest version (v20.1). Good luck - if you are still stuck, post here and tag my username so I see it, we should be able to get you up and running. In the future there won't be these issues, it's all down to the various hacks that have to be done to use MFME as the emulation backend... but the new project is a very long way off yet.
-
Source code / disassembly / reverse engineering question.
johnparker007 replied to redbags's topic in The Laboratory
I wonder if setting up a Windows 10 Virtual Machine image might be the way to go, if it has a very picky toolchain to set up... so then when it's working, that image can be shared/preserved, and should work in the future even on Win 11 / Linux / Mac (running the Virtual Machine Image on something like VirtualBox). I'm not sure how much I can really contribute to the process, I never actually worked on making fruit machines, and my free fme dev time is usually committed to working on the new Oasis project - but if I can help in some way with you copying your set up that used to work over to the Win 10 VM and testing etc, lemme know The VM should mean that if it works on your machine under VirtualBox, it should run on anyone's machine using VirtualBox (in theory! ) Your plan to use Epoch sounds sensible, if that has little to no legal risks compared to the Bell Fruit stuff So people could test their games they have created in MFME, and then in theory burn to chips, and build a real machine from them using Epoch parts. -
Just a heads up, I've been busy so time is precious Work on Oasis has been continuing on an almost daily basis, mainly on the Layout Editor system, however, as time/energy is limited, I've not been posting updates compared to the past and on Arcade Sim projects. If you want to see the live updates to the code, you can watch the commit list on github (as this is a fullly open source project): https://github.com/johnparker007/Oasis/commits/main/ Also, we have a new coder @oldfruitlover, who is (initially) looking into some super important base areas, such as file formats and the MAME Layout Builder system, so props and welcome to him I think for now, the lack of updates from me will continue, but that link above will give you an live snapshot of what's being worked on with Oasis. I know it's not as 'fresh' as the Arcade Sim updates were, but the key thing is for the work to continue at pace, so I hope you understand the prioritising github commits over forum updates
- 242 replies
-
- 11
-
-
-
@spinrite This version of Arcade Sim also needs MFME v20.1 to be installed on your system. Suspect you may either not have it installed, or haven't run the Updater in the MFME install folder. After installing MFME, there's an Updater exe in the MFME install folder (default path is usually C:\MFME\v20). If it's still not working after doing that then rerunning Arcade Sim, let us know, though hopefully that will fix it for you
-
Source code / disassembly / reverse engineering question.
johnparker007 replied to redbags's topic in The Laboratory
Part of this process would be reverse engineering 'libs'. So each fruit machine, even something like a somewhat templated Speccy game by Ocean would use libs, and then these would most likely be using some 'relocatable source' for generic functions. So, if you are writing a routine for an MPU4 machine to pay out a coin, you may 'call' (not really a call) a Macro in the src: PAYOUT(1) Of course, lots is nested in there. It gets tricky, quick, unfortunately So in assembler, you'd do the equivalent of a c #include, and include some say 6809 source (in an MPU4 game). It's all fairly straightforward when writing the game, but to work backwards from the ROM is near infinitely more a ball ache. It's all stuff that's not impossible, but is a massive amount of effort even (only) in the hands of a highly skilled retro coder. Maybe one day something with AI could be employed to expedite the process, but for reference here's a quick random n64 repo I found, early commits from 4 years ago, still in progress https://github.com/pmret/papermario TLDR: it's complicated and takes bloomin' ages. Also the code is less interchangeable than n64 game code due to the manufacturer fragmentation, so bonus despair ahead. TLDR TLDR: it's a lot more work than it sounds, even if you have leet skillz On a non-despair note; if @edwardb reads this, and is up for sharing his set of libs and build env, perhaps as part of a VM, for incoming coders to use to build new games, that would be a great step forward in creating new machines on those platforms etc. Totally understand Edward if this is impossible due to still binding NDAs etc. -
If it is set up correctly in Windows Defender it should work...it should appear like this in your excluded folders list:
-
@royb232 I saw your post in the chat box on the front page of the forum. With this prototype version of Arcade Simulator, the virus protectors have started picking up one of its components as a false positive. This is what causes the input to not work. There are steps to fix here:
-
Yes, I think it is the most nostalgic of machines An issue 1 would be amazing, ever since you told me about that one you had with the hard drawn tracks on the PCB - I'm guessing it looked like this: One day mate There's probably still some undiscovered ones in dead flesh cases that haven't been opened since the 80s, just out there, lurking around!
-
Yeah it's that sweet-ass FDD sticker that makes it, I have one of those also in the collection - even got a QL lurking on the shelves Just had to look that up, now that looks nice...
-
Haha I wasn't fussed about preserving the RF since it looks kinda dreadful... this also allows the RF to become the composite socket so you don't need to make the hole in the case
-
This is the way
-
A Harlequin in a new build toastrack case, now that is nice I still have my toastie I bought a few years back
-
This bluetooth keyboard project was by Steve Wilcox (Elite) - I'm normally a fan of software folks from the Speccy era, but he ripped me off £5k for R-Type mobile ports back in the day And probs some royalties too - so not a fan lol I also believe there is input latency with the bluetooth anyway (with some Speccy games needing precise 'pixel perfect' input), though to be fair I've read it's a pretty good physical copy of the original on a cosmetic level. Though for just an accurate collector piece you'd be better trying to source a clean original 48k unit.
-
I believe it's based on the Harlequin arch, so a real Speccy, not an emulator. But with modern conveniences built into the new design https://github.com/DonSuperfo/Superfo-Harlequin-128
-
Nice, sounds like it has a turbo function like the Next! Would recommend running Stunt Car Racer and some of those very early 3d games like Driller, there was a bunch on that Freescape engine - they are all much improved with an overclocked Speccy
-
Nice all in one unit! I liked Valkyrie 17 as an adventure game for the Speccy
-
I did reply to your previous post about this here: In short it will need some programming knowledge. I unfortunately really can't spare the time to work on this at present, but for someone will some coding knowledge, you should have all you need to get started in my previous reply. Would recommend trying to get an initial LED blinking... then branch out from there into how you might try control other things.
-
I haven't looked into the pac drive, however there is an SDK here: http://www.ultimarc.com/PacDriveSDK.zip If you are using Unity you'll be interested in the c# code below to interface with the .dll: Hope that helps // * ---------------------------------------------------------------------------- // * Author: Ben Baker // * Website: headsoft.com.au // * E-Mail: benbaker@headsoft.com.au // * Copyright (C) 2015 Headsoft. All Rights Reserved. // * ---------------------------------------------------------------------------- using System; using System.Collections.Generic; using System.Text; using System.Runtime.InteropServices; using System.Diagnostics; using System.IO; using System.Windows.Forms; namespace PacDriveDemo { public class PacDrive : IDisposable { // **************************************************************** // PacDrive / U-HID / Blue-HID // **************************************************************** // - 16 LED channels // **************************************************************** // Nano-LED // **************************************************************** // - 60 LED channels // - 256 brightness levels // - 20 RGB LEDs // **************************************************************** // PacLED64 // **************************************************************** // - 64 LED channels // - 256 brightness levels // - 21 RGB LEDs // **************************************************************** // I-Pac Ultimate I/O // **************************************************************** // - 96 LED channels // - 256 brightness levels // - 32 RGB LEDs public const int MAX_DEVICES = 16; public const int MAX_LEDCOUNT = 96; public const int MAX_INTENSITY = 255; public enum DeviceType { Unknown, PacDrive, UHID, BlueHID, NanoLED, PacLED64, IPacUltimateIO, ServoStik, USBButton }; public enum FlashSpeed : byte { AlwaysOn = 0, Seconds_2 = 1, Seconds_1 = 2, Seconds_0_5 = 3 }; // ================== 32-bit ==================== [DllImport("PacDrive32.dll", EntryPoint = "PacSetCallbacks", CallingConvention = CallingConvention.StdCall)] private static extern void PacSetCallbacks32(USBDEVICE_ATTACHED_CALLBACK usbDeviceAttachedCallback, USBDEVICE_REMOVED_CALLBACK usbDeviceRemovedCallback); [DllImport("PacDrive32.dll", EntryPoint = "PacInitialize", CallingConvention = CallingConvention.StdCall)] private static extern int PacInitialize32(); [DllImport("PacDrive32.dll", EntryPoint = "PacShutdown", CallingConvention = CallingConvention.StdCall)] private static extern void PacShutdown32(); [DllImport("PacDrive32.dll", EntryPoint = "PacSetLEDStates", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool PacSetLEDStates32(int id, ushort data); [DllImport("PacDrive32.dll", EntryPoint = "PacSetLEDState", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool PacSetLEDState32(int id, int port, [MarshalAs(UnmanagedType.Bool)] bool state); [DllImport("PacDrive32.dll", EntryPoint = "Pac64SetLEDStates", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64SetLEDStates32(int id, int group, byte data); [DllImport("PacDrive32.dll", EntryPoint = "Pac64SetLEDState", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64SetLEDState32(int id, int group, int port, [MarshalAs(UnmanagedType.Bool)] bool state); [DllImport("PacDrive32.dll", EntryPoint = "Pac64SetLEDStatesRandom", CallingConvention = CallingConvention.StdCall)] private static extern bool Pac64SetLEDStatesRandom32(int id); [DllImport("PacDrive32.dll", EntryPoint = "Pac64SetLEDIntensities", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64SetLEDIntensities32(int id, byte[] dataArray); [DllImport("PacDrive32.dll", EntryPoint = "Pac64SetLEDIntensity", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64SetLEDIntensity32(int id, int port, byte intensity); [DllImport("PacDrive32.dll", EntryPoint = "Pac64SetLEDFadeTime", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64SetLEDFadeTime32(int id, byte fadeTime); [DllImport("PacDrive32.dll", EntryPoint = "Pac64SetLEDFlashSpeeds", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64SetLEDFlashSpeeds32(int id, byte flashSpeed); [DllImport("PacDrive32.dll", EntryPoint = "Pac64SetLEDFlashSpeed", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64SetLEDFlashSpeed32(int id, int port, byte flashSpeed); [DllImport("PacDrive32.dll", EntryPoint = "Pac64StartScriptRecording", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64StartScriptRecording32(int id); [DllImport("PacDrive32.dll", EntryPoint = "Pac64StopScriptRecording", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64StopScriptRecording32(int id); [DllImport("PacDrive32.dll", EntryPoint = "Pac64SetScriptStepDelay", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64SetScriptStepDelay32(int id, byte stepDelay); [DllImport("PacDrive32.dll", EntryPoint = "Pac64RunScript", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64RunScript32(int id); [DllImport("PacDrive32.dll", EntryPoint = "Pac64ClearFlash", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64ClearFlash32(int id); [DllImport("PacDrive32.dll", EntryPoint = "Pac64SetDeviceId", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64SetDeviceId32(int id, int newId); [DllImport("PacDrive32.dll", EntryPoint = "PacGetDeviceType", CallingConvention = CallingConvention.StdCall)] private static extern int PacGetDeviceType32(int id); [DllImport("PacDrive32.dll", EntryPoint = "PacGetVendorId", CallingConvention = CallingConvention.StdCall)] private static extern int PacGetVendorId32(int id); [DllImport("PacDrive32.dll", EntryPoint = "PacGetProductId", CallingConvention = CallingConvention.StdCall)] private static extern int PacGetProductId32(int id); [DllImport("PacDrive32.dll", EntryPoint = "PacGetVersionNumber", CallingConvention = CallingConvention.StdCall)] private static extern int PacGetVersionNumber32(int id); [DllImport("PacDrive32.dll", EntryPoint = "PacGetVendorName", CharSet = CharSet.Unicode, CallingConvention = CallingConvention.StdCall)] private static extern void PacGetVendorName32(int id, StringBuilder vendorName); [DllImport("PacDrive32.dll", EntryPoint = "PacGetProductName", CharSet = CharSet.Unicode, CallingConvention = CallingConvention.StdCall)] private static extern void PacGetProductName32(int id, StringBuilder productName); [DllImport("PacDrive32.dll", EntryPoint = "PacGetSerialNumber", CharSet = CharSet.Unicode, CallingConvention = CallingConvention.StdCall)] private static extern void PacGetSerialNumber32(int id, StringBuilder serialNumber); [DllImport("PacDrive32.dll", EntryPoint = "PacGetDevicePath", CharSet = CharSet.Unicode, CallingConvention = CallingConvention.StdCall)] private static extern void PacGetDevicePath32(int id, StringBuilder devicePath); [DllImport("PacDrive32.dll", EntryPoint = "PacProgramUHid", CharSet = CharSet.Unicode, CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool PacProgramUHid32(int id, StringBuilder fileName); [DllImport("PacDrive32.dll", EntryPoint = "PacSetServoStik4Way", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool PacSetServoStik4Way32(); [DllImport("PacDrive32.dll", EntryPoint = "PacSetServoStik8Way", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool PacSetServoStik8Way32(); [DllImport("PacDrive32.dll", EntryPoint = "USBButtonConfigurePermanent", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool USBButtonConfigurePermanent32(int id, byte[] dataArray); [DllImport("PacDrive32.dll", EntryPoint = "USBButtonConfigureTemporary", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool USBButtonConfigureTemporary32(int id, byte[] dataArray); [DllImport("PacDrive32.dll", EntryPoint = "USBButtonConfigureColor", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool USBButtonConfigureColor32(int id, byte red, byte green, byte blue); [DllImport("PacDrive32.dll", EntryPoint = "USBButtonGetState", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool USBButtonGetState32(int id, [MarshalAs(UnmanagedType.Bool)] ref bool state); // ================== 64-bit ==================== [DllImport("PacDrive64.dll", EntryPoint = "PacSetCallbacks", CallingConvention = CallingConvention.StdCall)] private static extern void PacSetCallbacks64(USBDEVICE_ATTACHED_CALLBACK usbDeviceAttachedCallback, USBDEVICE_REMOVED_CALLBACK usbDeviceRemovedCallback); [DllImport("PacDrive64.dll", EntryPoint = "PacInitialize", CallingConvention = CallingConvention.StdCall)] private static extern int PacInitialize64(); [DllImport("PacDrive64.dll", EntryPoint = "PacShutdown", CallingConvention = CallingConvention.StdCall)] private static extern void PacShutdown64(); [DllImport("PacDrive64.dll", EntryPoint = "PacSetLEDStates", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool PacSetLEDStates64(int id, ushort data); [DllImport("PacDrive64.dll", EntryPoint = "PacSetLEDState", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool PacSetLEDState64(int id, int port, [MarshalAs(UnmanagedType.Bool)] bool state); [DllImport("PacDrive64.dll", EntryPoint = "Pac64SetLEDStates", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64SetLEDStates64(int id, int group, byte data); [DllImport("PacDrive64.dll", EntryPoint = "Pac64SetLEDState", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64SetLEDState64(int id, int group, int port, [MarshalAs(UnmanagedType.Bool)] bool state); [DllImport("PacDrive64.dll", EntryPoint = "Pac64SetLEDStatesRandom", CallingConvention = CallingConvention.StdCall)] private static extern bool Pac64SetLEDStatesRandom64(int id); [DllImport("PacDrive64.dll", EntryPoint = "Pac64SetLEDIntensities", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64SetLEDIntensities64(int id, byte[] dataArray); [DllImport("PacDrive64.dll", EntryPoint = "Pac64SetLEDIntensity", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64SetLEDIntensity64(int id, int port, byte intensity); [DllImport("PacDrive64.dll", EntryPoint = "Pac64SetLEDFadeTime", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64SetLEDFadeTime64(int id, byte fadeTime); [DllImport("PacDrive64.dll", EntryPoint = "Pac64SetLEDFlashSpeeds", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64SetLEDFlashSpeeds64(int id, byte flashSpeed); [DllImport("PacDrive64.dll", EntryPoint = "Pac64SetLEDFlashSpeed", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64SetLEDFlashSpeed64(int id, int port, byte flashSpeed); [DllImport("PacDrive64.dll", EntryPoint = "Pac64StartScriptRecording", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64StartScriptRecording64(int id); [DllImport("PacDrive64.dll", EntryPoint = "Pac64StopScriptRecording", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64StopScriptRecording64(int id); [DllImport("PacDrive64.dll", EntryPoint = "Pac64SetScriptStepDelay", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64SetScriptStepDelay64(int id, byte stepDelay); [DllImport("PacDrive64.dll", EntryPoint = "Pac64RunScript", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64RunScript64(int id); [DllImport("PacDrive64.dll", EntryPoint = "Pac64ClearFlash", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64ClearFlash64(int id); [DllImport("PacDrive64.dll", EntryPoint = "Pac64SetDeviceId", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool Pac64SetDeviceId64(int id, int newId); [DllImport("PacDrive64.dll", EntryPoint = "PacGetDeviceType", CallingConvention = CallingConvention.StdCall)] private static extern int PacGetDeviceType64(int id); [DllImport("PacDrive64.dll", EntryPoint = "PacGetVendorId", CallingConvention = CallingConvention.StdCall)] private static extern int PacGetVendorId64(int id); [DllImport("PacDrive64.dll", EntryPoint = "PacGetProductId", CallingConvention = CallingConvention.StdCall)] private static extern int PacGetProductId64(int id); [DllImport("PacDrive64.dll", EntryPoint = "PacGetVersionNumber", CallingConvention = CallingConvention.StdCall)] private static extern int PacGetVersionNumber64(int id); [DllImport("PacDrive64.dll", EntryPoint = "PacGetVendorName", CharSet = CharSet.Unicode, CallingConvention = CallingConvention.StdCall)] private static extern void PacGetVendorName64(int id, StringBuilder vendorName); [DllImport("PacDrive64.dll", EntryPoint = "PacGetProductName", CharSet = CharSet.Unicode, CallingConvention = CallingConvention.StdCall)] private static extern void PacGetProductName64(int id, StringBuilder productName); [DllImport("PacDrive64.dll", EntryPoint = "PacGetSerialNumber", CharSet = CharSet.Unicode, CallingConvention = CallingConvention.StdCall)] private static extern void PacGetSerialNumber64(int id, StringBuilder serialNumber); [DllImport("PacDrive64.dll", EntryPoint = "PacGetDevicePath", CharSet = CharSet.Unicode, CallingConvention = CallingConvention.StdCall)] private static extern void PacGetDevicePath64(int id, StringBuilder devicePath); [DllImport("PacDrive64.dll", EntryPoint = "PacProgramUHid", CharSet = CharSet.Unicode, CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool PacProgramUHid64(int id, StringBuilder fileName); [DllImport("PacDrive64.dll", EntryPoint = "PacSetServoStik4Way", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool PacSetServoStik4Way64(); [DllImport("PacDrive64.dll", EntryPoint = "PacSetServoStik8Way", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool PacSetServoStik8Way64(); [DllImport("PacDrive64.dll", EntryPoint = "USBButtonConfigurePermanent", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool USBButtonConfigurePermanent64(int id, byte[] dataArray); [DllImport("PacDrive64.dll", EntryPoint = "USBButtonConfigureTemporary", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool USBButtonConfigureTemporary64(int id, byte[] dataArray); [DllImport("PacDrive64.dll", EntryPoint = "USBButtonConfigureColor", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool USBButtonConfigureColor64(int id, byte red, byte green, byte blue); [DllImport("PacDrive64.dll", EntryPoint = "USBButtonGetState", CallingConvention = CallingConvention.StdCall)] [return: MarshalAs(UnmanagedType.Bool)] private static extern bool USBButtonGetState64(int id, [MarshalAs(UnmanagedType.Bool)] ref bool state); private delegate void USBDEVICE_ATTACHED_CALLBACK(int id); private delegate void USBDEVICE_REMOVED_CALLBACK(int id); public delegate void UsbDeviceAttachedDelegate(int id); public delegate void UsbDeviceRemovedDelegate(int id); public event UsbDeviceAttachedDelegate OnUsbDeviceAttached = null; public event UsbDeviceRemovedDelegate OnUsbDeviceRemoved = null; [MarshalAs(UnmanagedType.FunctionPtr)] USBDEVICE_ATTACHED_CALLBACK UsbDeviceAttachedCallbackPtr = null; [MarshalAs(UnmanagedType.FunctionPtr)] USBDEVICE_REMOVED_CALLBACK UsbDeviceRemovedCallbackPtr = null; private Control m_ctrl; private bool m_is64Bit = false; private bool[][] m_LEDState; private byte[][] m_LEDIntensity; private int m_deviceCount = 0; private bool m_disposed = false; public PacDrive(Control ctrl) { m_ctrl = ctrl; m_is64Bit = Is64Bit(); UsbDeviceAttachedCallbackPtr = new USBDEVICE_ATTACHED_CALLBACK(UsbDeviceAttachedCallback); UsbDeviceRemovedCallbackPtr = new USBDEVICE_REMOVED_CALLBACK(UsbDeviceRemovedCallback); if (m_is64Bit) PacSetCallbacks64(UsbDeviceAttachedCallbackPtr, UsbDeviceRemovedCallbackPtr); else PacSetCallbacks32(UsbDeviceAttachedCallbackPtr, UsbDeviceRemovedCallbackPtr); m_LEDState = new bool[MAX_DEVICES][]; m_LEDIntensity = new byte[MAX_DEVICES][]; for (int i = 0; i < MAX_DEVICES; i++) { m_LEDState[i] = new bool[MAX_LEDCOUNT]; m_LEDIntensity[i] = new byte[MAX_LEDCOUNT]; for (int j = 0; j < MAX_LEDCOUNT; j++) { m_LEDState[i][j] = false; m_LEDIntensity[i][j] = 0; } } } private void UsbDeviceAttachedCallback(int id) { m_deviceCount++; if (OnUsbDeviceAttached != null) m_ctrl.BeginInvoke(OnUsbDeviceAttached, id); } private void UsbDeviceRemovedCallback(int id) { m_deviceCount--; if (OnUsbDeviceRemoved != null) m_ctrl.BeginInvoke(OnUsbDeviceRemoved, id); } public int Initialize() { m_deviceCount = (m_is64Bit ? PacInitialize64() : PacInitialize32()); return m_deviceCount; } public void Shutdown() { if (m_is64Bit) PacShutdown64(); else PacShutdown32(); } public bool SetLEDStates(int id, ushort data) { if (id >= m_deviceCount) return false; return (m_is64Bit ? PacSetLEDStates64(id, data) : PacSetLEDStates32(id, data)); } public bool SetLEDState(int id, int port, bool state) { if (id >= m_deviceCount) return false; return (m_is64Bit ? PacSetLEDState64(id, port, state) : PacSetLEDState32(id, port, state)); } public bool SetLEDStates(int id, bool[] stateArray) { Array.Copy(stateArray, m_LEDState[id], Math.Min(stateArray.Length, m_LEDState[id].Length)); return SetLEDStates(id); } public bool SetLEDStates(int id) { if (id >= m_deviceCount) return false; bool retVal = false; if (IsPacDrive(id)) { ushort dataSend = 0; for (int i = 0; i < m_LEDState[id].Length; i++) if (m_LEDState[id][i]) dataSend |= (ushort)(1 << i); retVal = (m_is64Bit ? PacSetLEDStates64(id, dataSend) : PacSetLEDStates32(id, dataSend)); } else if (IsPac64(id)) { for (int i = 0; i < m_LEDState[id].Length; i += 8) { int group = (i / 8) + 1; byte dataSend = 0; for (int j = 0; j < 8; j++) if (m_LEDState[id][i + j]) dataSend |= (byte)(1 << j); retVal = (m_is64Bit ? Pac64SetLEDStates64(id, group, dataSend) : Pac64SetLEDStates32(id, group, dataSend)); } } return retVal; } public bool SetLEDStatesRandom(int id) { if (id >= m_deviceCount) return false; return (m_is64Bit ? Pac64SetLEDStatesRandom64(id) : Pac64SetLEDStatesRandom32(id)); } public bool SetLEDIntensity(int id) { if (id >= m_deviceCount) return false; return (m_is64Bit ? Pac64SetLEDIntensities64(id, m_LEDIntensity[id]) : Pac64SetLEDIntensities32(id, m_LEDIntensity[id])); } public bool SetLEDIntensity(int id, int port, byte intensity) { if (id >= m_deviceCount) return false; return (m_is64Bit ? Pac64SetLEDIntensity64(id, port, intensity) : Pac64SetLEDIntensity32(id, port, intensity)); } public bool SetLEDFadeTime(int id, byte fadeTime) { if (id >= m_deviceCount) return false; return (m_is64Bit ? Pac64SetLEDFadeTime64(id, fadeTime) : Pac64SetLEDFadeTime32(id, fadeTime)); } public bool SetLEDFlashSpeeds(int id, FlashSpeed flashSpeed) { if (id >= m_deviceCount) return false; return (m_is64Bit ? Pac64SetLEDFlashSpeeds64(id, (byte)flashSpeed) : Pac64SetLEDFlashSpeeds32(id, (byte)flashSpeed)); } public bool SetLEDFlashSpeed(int id, int port, FlashSpeed flashSpeed) { if (id >= m_deviceCount) return false; return (m_is64Bit ? Pac64SetLEDFlashSpeed64(id, port, (byte)flashSpeed) : Pac64SetLEDFlashSpeed32(id, port, (byte)flashSpeed)); } public bool StartScriptRecording(int id) { if (id >= m_deviceCount) return false; return (m_is64Bit ? Pac64StartScriptRecording64(id) : Pac64StartScriptRecording32(id)); } public bool StopScriptRecording(int id) { if (id >= m_deviceCount) return false; return (m_is64Bit ? Pac64StopScriptRecording64(id) : Pac64StopScriptRecording32(id)); } public bool SetScriptStepDelay(int id, byte stepDelay) { if (id >= m_deviceCount) return false; return (m_is64Bit ? Pac64SetScriptStepDelay64(id, stepDelay) : Pac64SetScriptStepDelay32(id, stepDelay)); } public bool RunScript(int id) { if (id >= m_deviceCount) return false; return (m_is64Bit ? Pac64RunScript64(id) : Pac64RunScript32(id)); } public bool ClearFlash(int id) { if (id >= m_deviceCount) return false; return (m_is64Bit ? Pac64ClearFlash64(id) : Pac64ClearFlash32(id)); } public bool SetDeviceId(int id, int newId) { if (id >= m_deviceCount) return false; return (m_is64Bit ? Pac64SetDeviceId64(id, newId) : Pac64SetDeviceId32(id, newId)); } public DeviceType GetDeviceType(int id) { if (id >= m_deviceCount) return DeviceType.Unknown; return (DeviceType)(m_is64Bit ? PacGetDeviceType64(id) : PacGetDeviceType32(id)); } public int GetVendorId(int id) { if (id >= m_deviceCount) return 0; return (m_is64Bit ? PacGetVendorId64(id) : PacGetVendorId32(id)); } public int GetProductId(int id) { if (id >= m_deviceCount) return 0; return (m_is64Bit ? PacGetProductId64(id) : PacGetProductId32(id)); } public int GetVersionNumber(int id) { if (id >= m_deviceCount) return 0; return (m_is64Bit ? PacGetVersionNumber64(id) : PacGetVersionNumber32(id)); } public string GetVendorName(int id) { if (id >= m_deviceCount) return String.Empty; StringBuilder sb = new StringBuilder(256); if (m_is64Bit) PacGetVendorName64(id, sb); else PacGetVendorName32(id, sb); return sb.ToString(); } public string GetProductName(int id) { if (id >= m_deviceCount) return String.Empty; StringBuilder sb = new StringBuilder(256); if (m_is64Bit) PacGetProductName64(id, sb); else PacGetProductName32(id, sb); return sb.ToString(); } public string GetSerialNumber(int id) { if (id >= m_deviceCount) return String.Empty; StringBuilder sb = new StringBuilder(256); if (m_is64Bit) PacGetSerialNumber64(id, sb); else PacGetSerialNumber32(id, sb); return sb.ToString(); } public string GetDevicePath(int id) { if (id >= m_deviceCount) return String.Empty; StringBuilder sb = new StringBuilder(256); if (m_is64Bit) PacGetDevicePath64(id, sb); else PacGetDevicePath32(id, sb); return sb.ToString(); } public bool ProgramUHid(int id, string fileName) { if (id >= m_deviceCount) return false; StringBuilder sb = new StringBuilder(fileName); return (m_is64Bit ? PacProgramUHid64(id, sb) : PacProgramUHid32(id, sb)); } public bool SetServoStik4Way() { return (m_is64Bit ? PacSetServoStik4Way64() : PacSetServoStik4Way32()); } public bool SetServoStik8Way() { return (m_is64Bit ? PacSetServoStik8Way64() : PacSetServoStik8Way32()); } public bool SetUSBButtonConfigurePermanent(int id, byte[] dataArray) { if (id >= m_deviceCount) return false; return (m_is64Bit ? USBButtonConfigurePermanent64(id, dataArray) : USBButtonConfigurePermanent32(id, dataArray)); } public bool SetUSBButtonConfigureTemporary(int id, byte[] dataArray) { if (id >= m_deviceCount) return false; return (m_is64Bit ? USBButtonConfigureTemporary64(id, dataArray) : USBButtonConfigureTemporary32(id, dataArray)); } public bool SetUSBButtonConfigureColor(int id, byte red, byte green, byte blue) { if (id >= m_deviceCount) return false; return (m_is64Bit ? USBButtonConfigureColor64(id, red, green, blue) : USBButtonConfigureColor32(id, red, green, blue)); } public bool GetUSBButtonState(int id, ref bool state) { if (id >= m_deviceCount) return false; return (m_is64Bit ? USBButtonGetState64(id, ref state) : USBButtonGetState32(id, ref state)); } public void GetLEDControllerInfo(int id, out bool isLEDController, out bool isRGB, out int ledCount, out int rgbLEDCount, out int maxBrightness) { isLEDController = false; isRGB = false; ledCount = 0; rgbLEDCount = 0; maxBrightness = 0; if (id >= m_deviceCount) return; DeviceType deviceType = GetDeviceType(id); switch (deviceType) { case DeviceType.Unknown: break; case DeviceType.PacDrive: case DeviceType.UHID: case DeviceType.BlueHID: isLEDController = true; ledCount = 16; break; case DeviceType.NanoLED: isLEDController = true; isRGB = true; ledCount = 60; rgbLEDCount = 20; maxBrightness = 255; break; case DeviceType.PacLED64: isLEDController = true; isRGB = true; ledCount = 64; rgbLEDCount = 21; maxBrightness = 255; break; case DeviceType.IPacUltimateIO: isLEDController = true; isRGB = true; ledCount = 16; rgbLEDCount = 32; maxBrightness = 255; break; case DeviceType.ServoStik: break; case DeviceType.USBButton: break; } } public bool IsPacDrive(int id) { if (id >= m_deviceCount) return false; DeviceType deviceType = GetDeviceType(id); return (deviceType == DeviceType.PacDrive || deviceType == DeviceType.UHID || deviceType == DeviceType.BlueHID); } public bool IsPac64(int id) { if (id >= m_deviceCount) return false; DeviceType deviceType = GetDeviceType(id); return (deviceType == DeviceType.NanoLED || deviceType == DeviceType.PacLED64 || deviceType == DeviceType.IPacUltimateIO); } public void SetSingleLEDState(int id, int port, bool state) { m_LEDState[id][port] = state; SetLEDStates(id); } public void SetSingleLEDIntensity(int id, int port, byte intensity) { m_LEDIntensity[id][port] = intensity; SetLEDIntensity(id); } public void SetRGBLEDIntensity(int id, int[] portArray, byte[] intensityArray) { for (int i = 0; i < portArray.Length; i++) m_LEDIntensity[id][portArray[i]] = intensityArray[i]; SetLEDIntensity(id); } public void SetRGBLEDState(int id, int[] portArray, bool[] stateArray) { for (int i = 0; i < portArray.Length; i++) m_LEDState[id][portArray[i]] = stateArray[i]; SetLEDStates(id); } public void SetLEDStateAll(bool state) { for (int i = 0; i < m_deviceCount; i++) { for (int j = 0; j < MAX_LEDCOUNT; j++) m_LEDState[i][j] = state; SetLEDStates(i); } } public void SetLEDIntensity(int id, byte[] intensityArray) { Array.Copy(intensityArray, m_LEDIntensity[id], Math.Min(intensityArray.Length, m_LEDIntensity[id].Length)); SetLEDIntensity(id); } public void SetLEDIntensityAll(byte intensity) { for (int i = 0; i < m_deviceCount; i++) { for (int j = 0; j < MAX_LEDCOUNT; j++) m_LEDIntensity[i][j] = intensity; SetLEDIntensity(i); } } #region IDisposable Members public void Dispose() { Dispose(true); GC.SuppressFinalize(this); // remove this from gc finalizer list } private void Dispose(bool disposing) { if (!this.m_disposed) // dispose once only { if (disposing) // called from Dispose { // Dispose managed resources. } // Clean up unmanaged resources here. Shutdown(); } m_disposed = true; } #endregion public int DeviceCount { get { return m_deviceCount; } } public bool[][] LEDState { get { return m_LEDState; } set { m_LEDState = value; } } public byte[][] LEDIntensity { get { return m_LEDIntensity; } set { m_LEDIntensity = value; } } private bool Is64Bit() { return Marshal.SizeOf(typeof(IntPtr)) == 8; } } }
-
No chance I'm sorry to say, it would be diverting a massive amount of time away from making the new Oasis software, and I'm not getting much dev time in as it is! All that work would then be essentially wasted as the machines will all need to be built again in Oasis.
-
It's Windows Defender throwing a false positive, it's a pain! Glad you got it sorted so you can play again
-
Refurbished IGT (US casino tech) edge lit dynamic buttons can be had for $24 each, but you'd also need the driver board (~$100), plus reverse engineer a way to drive the displays... one day, hopefully there'll be some nice solution that can be driven with something like an pi pico/arduino nano per button, and then have them all hooked to a USB hub, something like that. Then have Oasis send out the images for each button, and a layout with the bottom buttons cropped off... shame they're so niche as a product.
-
They do look much better, last time I found some proper integrated 'display buttons' I think they were pretty expensive... I might have another search I think it'd be a bit painful trying to hook this up with MFME, something perhaps for Oasis one day if cheap display buttons become commonplace, the cost of tiny displays is going down a lot as time progresses
-
I remember seeing some pretty expensive buttons with built in displays a while back... well I had a look into it again, and while these aren't buttons, they are small and cheap! I wonder if a standard fruit machine button could be modified to house one of these, with a hard clear plastic cover... Square: Round: Ali express links: https://www.aliexpress.com/item/1005006258472043.html?aff_fcid=23a51dc57d544622b680fc78a28a8adc-1717923506685-05574-_Dl834Gr&tt=CPS_NORMAL&aff_fsk=_Dl834Gr&aff_platform=shareComponent-detail&sk=_Dl834Gr&aff_trace_key=23a51dc57d544622b680fc78a28a8adc-1717923506685-05574-_Dl834Gr&terminal_id=90d1e9f9920b42f8b547fa7476ae1c41&afSmartRedirect=y https://www.aliexpress.com/item/1005006678263566.html?spm=a2g0o.productlist.main.33.2e76jOffjOffMV&algo_pvid=b7e514b2-432f-4790-9f86-238c2078edf8&algo_exp_id=b7e514b2-432f-4790-9f86-238c2078edf8-16&pdp_npi=4%40dis!GBP!1.78!1.78!!!16.04!16.04!%402103893b17179238461672546e2f5e!12000037992181350!sea!UK!1700116599!&curPageLogUid=t2HR7hgE0QT6&utparam-url=scene%3Asearch|query_from%3A
