Message

Popular in previous forums place your programming snippets here
Post Reply
User avatar
Zenerdiode
Posts: 81
Joined: Wed Jan 04, 2023 12:45 am
Location: Newcastle, England

Message

Post by Zenerdiode »

MSG.zip
You do not have the required permissions to view the files attached to this post.
Christopher. - Check out my TRAP message, it’s not difficult to decode and is sometimes uttered under the breath when said message appears… :|
User avatar
Martin
Global Admin
Posts: 430
Joined: Mon Jan 02, 2023 5:18 pm

Message

Post by Martin »

Thanks Chris... Merry Christmas...
MartinP
Posts: 68
Joined: Wed Jan 04, 2023 7:51 pm

Re: Message

Post by MartinP »

Lovely!
Merry Christmas!
User avatar
NotFitForPurpose
Posts: 92
Joined: Tue Sep 03, 2024 12:06 pm
Contact:

Re: Message

Post by NotFitForPurpose »

My guess is there is better out there:

Code: Select all

bps:
LOCAL nm$(9)
LOCAL fr%(9)
LOCAL nt$(128)
LOCAL bt$(128)
LOCAL b%,i%,l%
LOCAL d%,t%


REM Semicolon is a space
nm$ = "cdefgabC;"
fr%(1) = 262
fr%(2) = 294
fr%(3) = 330
fr%(4) = 349
fr%(5) = 392
fr%(6) = 440
fr%(7) = 494
fr%(8) = 523
fr%(9) = 1

REM a space represents a rest
REM bt$ must have same number of entries as nt$
nt$ = "eee;eee;egcde;fff;ffee;eeggfdc;"
bt$ = "2231223122314422301222011222244"

REM Attribution - As I have not a musical bone in my body
REM https://github.com/ammonshepherd/arduino-tuts/blob/master/03-jingle-bells.md


b% = 56 : REM Beats
i% = 1
l% = LEN(nt$)

While (i% <= l%)
  d%= (ASC(MID$(bt$, i%, 1)) - 48) * b%
  t% = 921600 / (78 + 2 * fr%(LOC(nm$, MID$(nt$, i%, 1))))
  BEEP d%, t%
  i% = i% + 1
ENDWH
Still its of an era...
Compliments of the season
User avatar
Martin
Global Admin
Posts: 430
Joined: Mon Jan 02, 2023 5:18 pm

BPS Ringtone

Post by Martin »

Works on a CM (if you disconnect the Comms Link)... If I had a mobile phone - slow it down a little - and that could be my ringtone.

Happy New Year
Martin
Post Reply