Main Restorations Software Audio/Jukebox/MP3 Everything Else Buy/Sell/Trade
Project Announcements Monitor/Video GroovyMAME Merit/JVL Touchscreen Meet Up Retail Vendors
Driving & Racing Woodworking Software Support Forums Consoles Project Arcade Reviews
Automated Projects Artwork Frontend Support Forums Pinball Forum Discussion Old Boards
Raspberry Pi & Dev Board controls.dat Linux Miscellaneous Arcade Wiki Discussion Old Archives
Lightguns --- Bug Reports --- Site News

Unread posts | New Replies | Recent posts | Rules | Chatroom | Wiki | File Repository | RSS | Submit news

  

Author Topic: DWJuke question  (Read 3359 times)

0 Members and 1 Guest are viewing this topic.

durandal_666

  • Trade Count: (0)
  • Jr. Member
  • **
  • Offline Offline
  • Posts: 4
  • Last login:April 29, 2011, 04:46:46 am
    • The Project
DWJuke question
« on: August 29, 2009, 08:57:47 am »
Got a question about DWJuke.  Currently set it up on my WIP cab as a joystick operated jukebox  - i know its not written for that in mind but Im much happier with DWJuke than other jukeboxes (Im running a micro-atx, so its low powered.  DWJuke has just enough bling without making my CPU cry).

Playstimulator & radio mode.  I had playstimulator set to the same time as my screensaver, so when left unattended the screensaver kicks in and it plays random music.  Great for parties when you cant get to the cab for whatever reason (READ: Too much booze).  However the playstimulator (like a real jukebox) plays a song and resets the counter, which leaves a lull.  I tried radio mode, but radio mode starts playing as soon as the juke is loaded.

I would like to run it so that it drops into radio mode after xx seconds of non play.  Ive tried fiddling with the settings in both skin and jukebox.ini to no avail.

Is this possible with current settings?  I can easily bind BTN_RADIO to a button on the cab but its just not quite as polished as dropping in automatically after a specified idle time.
Foldup Portable MAME case project: http://durandal666.blogspot.com

Chris

  • Moderator
  • Trade Count: (+2)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 4572
  • Last login:December 22, 2014, 10:29:47 pm
    • Chris's MAME Cabinet
Re: DWJuke question
« Reply #1 on: November 01, 2009, 11:36:37 pm »
I apologize for the lack of answer to this question.  There is no way to do this with the current version of the jukebox.

There is a feature I just added tonight that may work for you, though, and that is user timers.  So you'd want the juke to go into radio mode after it's been idle for a time; that part is easy.  The question is when do you want radio mode to stop?  Once radio mode starts, of course, the jukebox is no longer idle...

So let's solve the first problem: How to trigger radio mode?  The timer would look like this:

[Timer1]

#Intervals are measured in hundredths of a second
# 30000 = 5 minute interval
Interval=30000

# Autostart defines whether the timer starts when the jukebox starts
AutoStart=No

# Repeat determines whether the timer automatically repeats, or repeats a set number of times
Repeat=No

# StartAction and StopAction are messages that will stop and start the timer
StartAction = MSG_IDLE
StopAction = -MSG_IDLE

# OnStart, OnRepeat, OnEnd and OnStop are the messages that are sent at the beginning and end of a timer run.
# OnStart triggers as soon as the timer is first started.  Will probably never be used.
# OnRepeat triggers when the timer reaches the end of its timer and restarts
# OnEnd triggers when the timer reaches the end of its timer and does not restart.
# OnStop triggers when the timer is stopped by its stop message.  Will probably never be used.

OnEnd=CMD_RADIO

So this would start a one-time timer when the jukebox goes idle.  If it goes the full 5 minutes, it will toggle radio mode (and radio mode must be off already if the jukebox is idle at all).  If the tyimer endfs because hte juke is no longer idle, it will not trigger radio mode.

So how do we STOP radio mode?  If we trigger off MSG_SELECTING, then radio mode would be cancelled as soon as anyone enters any selection digits or letters.  However, CMD_RADIO toggles the radio state, so radio mode will keep going on and off.  I need to add discrete commands such as CMD_RADIO_ON and CMD_RADIO_OFF to guarantee a particular state gets set; that is easy enough.  So assuming that is done, the second timer looks like this:

[Timer2]

#Intervals are measured in hundredths of a second
#0 indicates that the timer will go off immediately
Interval=0

# Autostart defines whether the timer starts when the jukebox starts
AutoStart=No

# Repeat determines whether the timer automatically repeats, or repeats a set number of times
Repeat=No

# StartAction and StopAction are messages that will stop and start the timer
StartAction = MSG_SELECTING

# OnStart, OnRepeat, OnEnd and OnStop are the messages that are sent at the beginning and end of a timer run.
# OnStart triggers as soon as the timer is first started.  Will probably never be used.
# OnRepeat triggers when the timer reaches the end of its timer and restarts
# OnEnd triggers when the timer reaches the end of its timer and does not restart.
# OnStop triggers when the timer is stopped by its stop message.  Will probably never be used.

OnEnd=CMD_RADIO_OFF

So there we have it.. with the addition of these new timers you would have a radio mode that goes on after 5 minutes of idle and goes off as soon as someone manually selects a song.

There is one catch... MSG_SELECTING isn't triggered if a song is clicked on directly.  I'll have to do something about thaat.

--Chris
--Chris
DOSCab/WinCab Jukebox: http://www.dwjukebox.com

Kevin Mullins

  • Trade Count: (+2)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 4504
  • Last login:November 11, 2018, 03:00:41 pm
    • Me on Myspace
Re: DWJuke question
« Reply #2 on: November 03, 2009, 12:46:26 am »
Very cool Chris.....  :cheers:

I may have to actually install a newer version of DWJuke now into my jukebox. 
Not a technician . . . . just a DIY'er.

Chris

  • Moderator
  • Trade Count: (+2)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 4572
  • Last login:December 22, 2014, 10:29:47 pm
    • Chris's MAME Cabinet
Re: DWJuke question
« Reply #3 on: November 03, 2009, 01:01:34 am »
I am trying to finalize it for a release over the next few days. 
--Chris
DOSCab/WinCab Jukebox: http://www.dwjukebox.com