Table of Contents

Enum Note

Namespace
GB
Assembly
GBSharp.Framework.dll

A pitch, as the value the frequency registers actually take.

public enum Note : ushort

Fields

A3 = 1452
A4 = 1750
A5 = 1899
A6 = 1974
As3 = 1486
As4 = 1767
As5 = 1907
As6 = 1978
B3 = 1517
B4 = 1783
B5 = 1915
B6 = 1982
C3 = 1046
C4 = 1547
C5 = 1798
C6 = 1923
Cs3 = 1102
Cs4 = 1575
Cs5 = 1812
Cs6 = 1930
D3 = 1155
D4 = 1602
D5 = 1825
D6 = 1936
Ds3 = 1205
Ds4 = 1627
Ds5 = 1837
Ds6 = 1943
E3 = 1253
E4 = 1650
E5 = 1849
E6 = 1949
F3 = 1297
F4 = 1673
F5 = 1860
F6 = 1954
Fs3 = 1339
Fs4 = 1694
Fs5 = 1871
Fs6 = 1959
G3 = 1379
G4 = 1714
G5 = 1881
G6 = 1964
Gs3 = 1417
Gs4 = 1732
Gs5 = 1890
Gs6 = 1969

Remarks

These are periods, not frequencies: the hardware wants 2048 - 131072/Hz, and that is what the members hold. Higher values are higher pitches, and the spacing is not linear.

The enum is backed by ushort so a note used at a call site folds to a literal during lowering. There is no note table in ROM and no lookup at runtime: writing Note.A4 costs exactly what writing 1750 would.