It pretty a nice idea to use one command, but there is now various commands to fit all you need. You can do this all functions with various functions, so they are all covered in the SDK:
JUKE_APPLICATION_OPENED
Juke_Initialize()
JUKE_APPLICATION_CLOSED
Juke_Shutdown(0)
JUKE_SONG_STARTED
Juke_SongBegin()
; do not need to send song info again, since the plugin allready know it using add2queue().
JUKE_SONG_FINISHED
Juke_SongEnd(0)
; EDIT, just corrected a error.
JUKE_SONG_RESTARTED
Juke_SongBegin()
; The plugin did not delete the song from its queue, because Juke_SongEnd(0) was not used.
; can also use the same if you use some thing as song loop and something elsewice.
JUKE_SONG_SKIPPED
Juke_SongEnd(1)
; When a song skipped, the song is also ended. Let the plugin know with setting value to 1.
JUKE_SONG_PAUSED
Juke_SongStatus("PAUSE")
; Plugin can also detect that when listen to Juke_SongPlayed(secs), because seconds diddent count.
JUKE_SONG_RESUMED
Juke_SongStatus("PLAY")
JUKE_SONG_FAST_FORWARD_POS
Juke_SongStatus("FAST RESERVE")
Juke_CommandSend("FAST_RESERVE") ; if it can been used as a keypress command.
JUKE_SONG_PLAY_POS
;no need, the plugin can detect it while listing to Juke_SongPlayed(secs), since the secs change.
JUKE_QUEUE_USER_ADD_SONG
Juke_Add2Queue(File$, totalDurationSecs, 0, CoverArt$="", "+tracknr+" "+name, artist, album, "", "")
; tracknr is not supported, but use it as part of the title name. A plugin might check about it.
JUKE_QUEUE_SYSTEM_ADD_SONG
Juke_Add2Queue(File$, totalDurationSecs, 1, CoverArt$="", "+tracknr+" "+name, artist, album, "", "")
; tracknr is not supported, but use it as part of the title name. A plugin might check about it.
JUKE_QUEUE_DELETE_SONG
Juke_QueueClear(1)
; then resubmit all songs agom you have in your queue using Juke_Add2Queue()
JUKE_QUEUE_MOVE_SONG
Juke_QueueClear(1)
; then resubmit all songs you have in your queue using Juke_Add2Queue()
JUKE_QUEUE_CLEARED
Juke_QueueClear(0)
JUKE_VOLUME_CHANGE
Juke_Volume(volumelevel, minVolumeLevel, maxVolumeLevel)
JUKE_VOLUME_MUTE_STATUS
Juke_CommandSend("MUTE", 0); on
Juke_CommandSend("MUTE", 1); off
JUKE_VOLUME_RANGE
Juke_Volume(volumelevel, minVolumeLevel, maxVolumeLevel)
JUKE_ENTER_ALBUM_NUM_DIGIT
Juke_CommandSend(digit, 0) <- just a a string digit, You might need to use LCDString if you want full LCD control using this function.
JUKE_ENTER_TRACK_NUM_DIGIT
Juke_CommandSend(digit, 0) <- just a a string digit, You might need to use LCDString if you want full LCD control using this function.
in plugindir/Commands.txt you should set these for above example:
FAST_RESERVE,0
MUTE, 0
0, 0
1, 0
2, 0
3, 0
4, 0
5, 0
6, 0
7, 0
8, 0
9, 0
About the config:
The main problem is I wont have my software locked while a plugin is on configuration. This because BlitzMax dosent support threads.
Instead the exe file can use the same name as the dll itself, so they can been called from the application. I add such a function in next version on my SDK when I went home. plugin authors dosnet need to do anything, just make sure the config exe is the same as dll name itself.
Adding this function soon to my wrapper to invoke a exe file to its config.