Raspberry.IO.Components.Displays.Hd44780.Hd44780LcdConnection.GetLcdAddressLocation C# (CSharp) Method

GetLcdAddressLocation() private method

Returns the Lcd Address for the given row
http://www.mikroe.com/forum/viewtopic.php?t=5149
private GetLcdAddressLocation ( int row ) : int
row int A zero based row position
return int
        private int GetLcdAddressLocation(int row)
        {
            const int baseAddress = 128;

            switch (row)
            {
                case 0: return baseAddress;
                case 1: return (baseAddress + 64);
                case 2: return (baseAddress + width);
                case 3: return (baseAddress + 64 + width);
                default: return baseAddress;
            }
        }