Author Topic: Drum Machine Prototype  (Read 9420 times)

0 Members and 1 Guest are viewing this topic.

Offline Pete

  • Forum Resident
  • Posts: 2361
  • Cuz I sez so, varmint!
    • View Profile
Re: Drum Machine Prototype
« Reply #30 on: April 21, 2020, 01:44:01 pm »
Well sure, me and Fell, oh, and maybe Steve, if he works really, really hard at it for the next 20 or so years. :D :D :D

You have the ability to be both modest and talented. I'd be happy to have half your traits. (The talented half, of course.) My wife said to me once, "Honey, you should try being modest." I told her, I can't. I can't be modest because I have nothing to be modest about! Amazingly enough, we've been married now for 39 years and counting, so I must be doing something right. Shut up Bill! 

Anyway, TheBOB checked out the project and called it a "Pretty cool program." He told me he had ventured into some similar programming back in the 1980's. He made a keyboard recorder. He pitched it (excuse the pun) because the tempo was a bit off. He was new to programming back then, and now realizes he could have used TIMER to better calculate the time delay between notes. Now with the increased capabilities of QB64, more is even possible.

Pete
Want to learn how to write code on cave walls? https://www.tapatalk.com/groups/qbasic/qbasic-f1/

Offline Dav

  • Forum Resident
  • Posts: 792
    • View Profile
Re: Drum Machine Prototype
« Reply #31 on: April 21, 2020, 06:25:53 pm »
What do you mean by changing meters? Do you want to change the music sample length? Does this mean, for example, that the sound of a drum strike is slower or faster?

No, it doesn't change the sample length or tempos, just how long the whole drum pattern is.

For example, without getting into musical terms, right now the drum pattern is 8 beats long (8 clicks), and there are 4 boxes between those beats you can assign sounds to.  If I changed it to a 3/4 meter, there would only be  6 beats.  So the pattern length just becomes shorter, not the sample sounds.

- Dav 
« Last Edit: April 21, 2020, 06:49:22 pm by Dav »

Offline Petr

  • Forum Resident
  • Posts: 1720
  • The best code is the DNA of the hops.
    • View Profile
Re: Drum Machine Prototype
« Reply #32 on: April 22, 2020, 03:14:32 pm »
Thanks for the explanation, Dav. Music notes therefore determine the regularity of timing in music, if i understand it correctly.

Offline Pete

  • Forum Resident
  • Posts: 2361
  • Cuz I sez so, varmint!
    • View Profile
Re: Drum Machine Prototype
« Reply #33 on: April 22, 2020, 04:46:32 pm »
Thanks for the explanation, Dav. Music notes therefore determine the regularity of timing in music, if i understand it correctly.

Right, things like whole notes, half notes, quarter notes, etc. mixed with the beat like 4/4 time, 2/4 time, etc. I took one class in music appreciation in my younger days. I asked my classmates if they had any requests, and they told me to go play "In the Street." I still haven't found those lyrics online.

Pete
Want to learn how to write code on cave walls? https://www.tapatalk.com/groups/qbasic/qbasic-f1/

Offline Dav

  • Forum Resident
  • Posts: 792
    • View Profile
Re: Drum Machine Prototype
« Reply #34 on: April 23, 2020, 08:46:36 pm »
That's right, Petr.  Changing the meter shouldn't interfere with the way you are getting samples.

@Pete: Thanks for the TheBob feedback.  I have been an admirer of his work for many years.  Please send my thanks to him for checking out the program.

- Dav
« Last Edit: April 23, 2020, 08:55:24 pm by Dav »

Offline Pete

  • Forum Resident
  • Posts: 2361
  • Cuz I sez so, varmint!
    • View Profile
Re: Drum Machine Prototype
« Reply #35 on: April 23, 2020, 10:10:22 pm »
Will do. ;)

Pete
Want to learn how to write code on cave walls? https://www.tapatalk.com/groups/qbasic/qbasic-f1/

Offline Pete

  • Forum Resident
  • Posts: 2361
  • Cuz I sez so, varmint!
    • View Profile
Re: Drum Machine Prototype
« Reply #36 on: April 24, 2020, 11:25:08 am »
TheBOB appreciated your comment and asked me to send his regards. He would have sent them himself, but do to the Wuhan Virus, the Canadian American border is currently closed.

Pete
Want to learn how to write code on cave walls? https://www.tapatalk.com/groups/qbasic/qbasic-f1/

Offline Dav

  • Forum Resident
  • Posts: 792
    • View Profile
Re: Drum Machine Prototype
« Reply #37 on: May 07, 2020, 07:33:12 pm »
I've updated the Drum Machine again, changing its looks (for the better I hope) and added option to mute/unmute individual instruments.  There are some things improved.  Again, I have re-edited it's needed data files, so you will have to extract the whole package to run this new version, replacing earlier files.  Petr's SAV to WAV utility will srill work on this versions SAV files as I have not changed the SAV file format.

I'll post what's new in this version, a screen cap, and the source below to download.

- Dav

'================================
'New in v0.1c...

'Added: Added program _TITLE and _ICON.
'Added: New logo with keyboard command help.
'Added: Shows big TEMPO (BMP) font at top left.
'Added: Shows green playing position line down grid.
'       (replaced little white moving marker)
'Added: Give user notices when a Save/Load is done.
'Added: Instrument names can now be clicked on to mute/unmute.
'Added: Now shows on screen if metronome is ON/OFF
'Fixed: Changed keyboard input method. Much more responsive.
'========================================

 
drummachine.png


Download --> 

Offline Petr

  • Forum Resident
  • Posts: 1720
  • The best code is the DNA of the hops.
    • View Profile
Re: Drum Machine Prototype
« Reply #38 on: May 09, 2020, 04:02:43 am »
Very nice work, Dav! I have a suggestion that would make it very easy to customize my audio storage program. If you are planning to expand to the right and down (longer playing, more instruments), I want to request that two records be added to the SAV file. One for the number of rows and one for the number of columns. Upgrading my program will then be very easy.

Offline Dav

  • Forum Resident
  • Posts: 792
    • View Profile
Re: Drum Machine Prototype
« Reply #39 on: May 10, 2020, 09:22:48 am »
Peter, sure - I will do that.  I should have did it at first but got lazy!

Thanks!

- Dav