Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updated mappings for the Hercules Inpulse 300 #12503

Closed
wants to merge 54 commits into from

Conversation

BoredGuy1
Copy link
Contributor

@BoredGuy1 BoredGuy1 commented Jan 3, 2024

I made some improvements to Mixxx's included Inpulse 300 mapping. I tried to stay close to the manufacturer mappings listed in this manual.

Full list of changes:

  • Added ability to stop samplers (shift + button)

  • Added toneplay

    • Pressing a pad jumps to the most recently used hotcue and changes the pitch
    • Shift + toneplay changes the pitch without jumping
    • Pads 1-4 increase the pitch by +0 to +3 semitones
    • Pads 5-8 decrease the pitch by -4 to -1 semitones
    • LED reflects total adjustment to current key
  • Added slicer/slicer loop:

    • Press slicer button to activate a slicer section, press again to deactivate it
    • Slicer length is dependent on loop length
    • Exiting slicer mode or pressing LOOP OUT also deactivates the slicer section
    • Creating a slicer section overrides active loops, and creating a 4-beat loop overrides active slicer sections
    • Only works on constant BPM (also true in native software DJUCED)
    • Slicer section does not move backwards when scratching (also true in native software DJUCED)
  • Added actual beatmatch guide functionality to the LEDs

    • This replaces the LEDs' old end-of-track warning functionality. Hopefully no one missed it :P
  • Changed the way scratching works

    • Wheels have inertia rather than instantly stopping when released (this allows backspins and other tricks)
    • Removed scratchPad in XML (not sure what it was doing there)
  • Updated VU meter syntax

    • Replaced vu_meter with VuMeter to comply with new version of Mixxx
    • Replaced connectControl with makeConnection to allow multiple connections (and also to comply with newer versions)
  • Replaced "hotcue_X_enabled" with "hotcue_X_status" in XML file to comply with newer version of Mixxx

Manual is being updated accordingly in another PR: PR#604.

@JoergAtGithub
Copy link
Member

Welcome at Mixxx!
As a first-time contributor we need you to sign the Mixxx Contributor Agreement and comment here when you have done so. It gives us permission to distribute your contribution under the GPL v2 or later license and the Apple Mac App Store. It is also helpful for us to have contact information for contributors in case we may need it in the future.

@JoergAtGithub
Copy link
Member

The pre-commit check is failing. The best way to fix pre-commit issues is to install pre-commit locally on your system, as described here: https://github.com/mixxxdj/mixxx/wiki/Using-Git#set-up-automatic-code-checking
Than it will fix these issues automatically before every commit.
Alternatively, you can download the pre-commit.patch file from the artifacts of this PR
grafik
unzip it, and apply it using:
git apply pre-commit.patch

Please note, that this will not fix the typo, that the codespell check reports - this one must be fixed manually.

@BoredGuy1
Copy link
Contributor Author

Alright, I've filled out the agreement, installed pre-commit, and fixed all the typos and style issues. Let me know if there's anything else I need to do.

@JoergAtGithub
Copy link
Member

Target for this PR should be 2.4 not main. Please rebase.

@BoredGuy1 BoredGuy1 changed the base branch from main to 2.4 January 3, 2024 21:27
@JoergAtGithub
Copy link
Member

If you need help with Git, have a look here: https://github.com/mixxxdj/mixxx/wiki/Using-Git#targeting-another-base-branch

@BoredGuy1
Copy link
Contributor Author

I'm still figuring my way around git, but assuming I rebased it properly, it should be ready to merge now. I also took the opportunity to add a whole bunch of other stuff, but now the manual PR is no longer up to date. I will be busy in the coming weeks, but hopefully I can get the manual up to speed after that.

In the meantime, it would be nice to have some feedback on this mapping (especially from @DJPhatso ;)

@DJPhatso
Copy link
Contributor

DJPhatso commented Feb 6, 2024

Pretty busy right now, but I'll see what I can do.

@DJPhatso
Copy link
Contributor

DJPhatso commented Feb 13, 2024

Some feedback of what I was able to try:

  • Samplers stop:

Work as expected.

  • Toneplay:

Been a while since I used this functionality in Traktor, so I might not be the best to judge if the flow is correct, but all functions were assigned as described.

  • Beatmatch guide to LEDs

Glad you could make it work as intended :-)

  • Changed the way scratching works

I noticed some unexpected scratching on occasion (i.e. without actually touching the wheels), which did no occur when I switched back to the default mapping (even tried with another unit to rule out some hardware problems), so there might be some adjustments to be done on that side.

Looking at the script, there are a few User Options I might try to modify next time.

  • Updated VU meter syntax

No problems there

Copy link
Member

@Swiftb0y Swiftb0y left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you. I don't think I can make any more informed comments. I trust you to have the mapping tested thoroughly as I can't confirm whether its working myself. @ywwg merge?

@ywwg
Copy link
Member

ywwg commented Dec 20, 2024

@BoredGuy1 can you fix the lint issues identified by the CI? they look like they are small things

Copy link
Member

@ywwg ywwg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

address lint issues

@ywwg
Copy link
Member

ywwg commented Dec 20, 2024

sorry just one more set of lint!

diff --git a/res/controllers/Hercules-DJControl-Inpulse-300-script.js b/res/controllers/Hercules-DJControl-Inpulse-300-script.js
index 2b48a5f917..507d308c25 100644
--- a/res/controllers/Hercules-DJControl-Inpulse-300-script.js
+++ b/res/controllers/Hercules-DJControl-Inpulse-300-script.js
@@ -585,7 +585,7 @@ DJCi300.Deck = function(deckNumber) {
                         this.slicerUpdateLED(group);
                     }
                 }.bind(this),
-            })
+            });
         }
     }
     // This function will count beats and move the Slicer section forward when needed
@@ -608,7 +608,7 @@ DJCi300.Deck = function(deckNumber) {
 
         // If in slicer mode (not slicer loop mode), check to see if the slicer section needs to be moved
  if (DJCi300.padMode[group] === DJCi300.padModeSlicer) {
  -    
  +
               // If slicerBeat is 8, move the slicer section forward
               if (beat > 7) {

@Swiftb0y Swiftb0y requested a review from ywwg December 20, 2024 21:51
@BoredGuy1
Copy link
Contributor Author

Don't worry - I already know my code style is messy :P

Let me know if there's any more lint issues - I'll gladly patch them.

@ywwg
Copy link
Member

ywwg commented Dec 23, 2024

ok now that it passes, can you squash down some of the commits, especially the broken ones? you can do this by doing git rebase -i -- I am not sure about your level of familiarity with git. I can do that for you if you like

@BoredGuy1
Copy link
Contributor Author

Let me see if I can figure it out.

Fixed minor error on comment

Reverted beatmatch code slightly

Tested code, fixed ESLint issues

Fixed even more ESLint issues

3rd time's the charm
@BoredGuy1
Copy link
Contributor Author

BoredGuy1 commented Dec 23, 2024

Never mind, I don't think I did it right. If you can squash down the commits on your end, that would be great. @ywwg

@ywwg
Copy link
Member

ywwg commented Dec 23, 2024

alternative squashed version: #14051 @Swiftb0y what do you prefer

@Swiftb0y
Copy link
Member

Lets continue on #14051. Thank you so far @BoredGuy1.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants