diff --git a/Source/CrossPlatform/MauiMeadow/App.xaml.cs b/Source/CrossPlatform/MauiMeadow/App.xaml.cs index 4cd88a6..89f49c9 100644 --- a/Source/CrossPlatform/MauiMeadow/App.xaml.cs +++ b/Source/CrossPlatform/MauiMeadow/App.xaml.cs @@ -1,7 +1,7 @@ using Meadow; using Meadow.Foundation.Displays; -using Meadow.Foundation.Graphics; using Meadow.Foundation.ICs.IOExpanders; +using Meadow.Peripherals.Displays; using Meadow.UI; namespace MauiMeadow @@ -18,7 +18,7 @@ public App() MainPage = new AppShell(); } - protected Task MeadowInitialize() + protected Task MeadowInitialize() { var expander = new Ft232h(); @@ -30,7 +30,7 @@ protected Task MeadowInitialize() resetPin: expander.Pins.C2 ); - Resolver.Services.Add(display); + Resolver.Services.Add(display); return Task.CompletedTask; } diff --git a/Source/CrossPlatform/MauiMeadow/ViewModels/MainPageViewModel.cs b/Source/CrossPlatform/MauiMeadow/ViewModels/MainPageViewModel.cs index bf1665a..9e2d5ce 100644 --- a/Source/CrossPlatform/MauiMeadow/ViewModels/MainPageViewModel.cs +++ b/Source/CrossPlatform/MauiMeadow/ViewModels/MainPageViewModel.cs @@ -1,5 +1,6 @@ using Meadow; using Meadow.Foundation.Graphics; +using Meadow.Peripherals.Displays; using System.ComponentModel; using System.Runtime.CompilerServices; using System.Windows.Input; @@ -10,7 +11,7 @@ public class MainPageViewModel : INotifyPropertyChanged { private MicroGraphics graphics; - private IGraphicsDisplay _display; + private IPixelDisplay _display; public ICommand CountCommand { get; set; } @@ -27,7 +28,7 @@ private async Task WaitForDisplay() { while (_display == null) { - _display = Resolver.Services.Get(); + _display = Resolver.Services.Get(); await Task.Delay(100); } diff --git a/Source/Linux/Amg8833_Sample/MeadowApp.cs b/Source/Linux/Amg8833_Sample/MeadowApp.cs index 8032218..8096f5f 100644 --- a/Source/Linux/Amg8833_Sample/MeadowApp.cs +++ b/Source/Linux/Amg8833_Sample/MeadowApp.cs @@ -1,13 +1,13 @@ using Meadow; using Meadow.Foundation.Displays; -using Meadow.Foundation.Graphics; using Meadow.Foundation.Graphics.MicroLayout; using Meadow.Foundation.Sensors.Camera; +using Meadow.Peripherals.Displays; using Meadow.Pinouts; public class MeadowApp : App> { - private IGraphicsDisplay _display; + private IPixelDisplay _display; private DisplayScreen _screen; private Amg8833 _camera; private Box[] _pixelBoxes; diff --git a/Source/Linux/Meadow.Linux.Samples.sln b/Source/Linux/Meadow.Linux.Samples.sln index 7abda46..a91914a 100644 --- a/Source/Linux/Meadow.Linux.Samples.sln +++ b/Source/Linux/Meadow.Linux.Samples.sln @@ -81,6 +81,8 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Cloud", "Cloud", "{7E2108C1 EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "CloudCommandReceiver", "Cloud\CloudCommandReceiver\CloudCommandReceiver.csproj", "{1B5A6F9A-D905-454F-895D-C7A06FD98D7B}" EndProject +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Meadow.Foundation.Core", "..\..\..\Meadow.Foundation\Source\Meadow.Foundation.Core\Meadow.Foundation.Core.csproj", "{DEC506C7-85AC-4381-AECA-B71E7CA03D05}" +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -251,6 +253,12 @@ Global {1B5A6F9A-D905-454F-895D-C7A06FD98D7B}.Debug|Any CPU.Build.0 = Debug|Any CPU {1B5A6F9A-D905-454F-895D-C7A06FD98D7B}.Release|Any CPU.ActiveCfg = Release|Any CPU {1B5A6F9A-D905-454F-895D-C7A06FD98D7B}.Release|Any CPU.Build.0 = Release|Any CPU + {DEC506C7-85AC-4381-AECA-B71E7CA03D05}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {DEC506C7-85AC-4381-AECA-B71E7CA03D05}.Debug|Any CPU.Build.0 = Debug|Any CPU + {DEC506C7-85AC-4381-AECA-B71E7CA03D05}.Debug|Any CPU.Deploy.0 = Debug|Any CPU + {DEC506C7-85AC-4381-AECA-B71E7CA03D05}.Release|Any CPU.ActiveCfg = Release|Any CPU + {DEC506C7-85AC-4381-AECA-B71E7CA03D05}.Release|Any CPU.Build.0 = Release|Any CPU + {DEC506C7-85AC-4381-AECA-B71E7CA03D05}.Release|Any CPU.Deploy.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE @@ -291,6 +299,7 @@ Global {0CB462BC-EC1D-4EE2-BDB8-884CA9308F30} = {7E2108C1-60C2-45AF-8C00-29275D81AB50} {7E2108C1-60C2-45AF-8C00-29275D81AB50} = {AF3F2B7E-D0AC-4418-8E9E-5515874092C7} {1B5A6F9A-D905-454F-895D-C7A06FD98D7B} = {7E2108C1-60C2-45AF-8C00-29275D81AB50} + {DEC506C7-85AC-4381-AECA-B71E7CA03D05} = {0E9EB1DB-A564-465B-9CE9-5E1CDD7306C6} EndGlobalSection GlobalSection(ExtensibilityGlobals) = postSolution SolutionGuid = {E3F002EA-1A25-487F-9A5D-93D1E7EC6E31} diff --git a/Source/Linux/ST7789_Sample/MeadowApp.cs b/Source/Linux/ST7789_Sample/MeadowApp.cs index 04a9923..928e808 100644 --- a/Source/Linux/ST7789_Sample/MeadowApp.cs +++ b/Source/Linux/ST7789_Sample/MeadowApp.cs @@ -411,11 +411,11 @@ void ColorFontTest() _graphics.Clear(); - _graphics.DrawTriangle(120, 20, 200, 100, 120, 100, Meadow.Foundation.Color.Red, false); + _graphics.DrawTriangle(120, 20, 200, 100, 120, 100, Meadow.Color.Red, false); - _graphics.DrawRectangle(140, 30, 40, 90, Meadow.Foundation.Color.Yellow, false); + _graphics.DrawRectangle(140, 30, 40, 90, Meadow.Color.Yellow, false); - _graphics.DrawCircle(160, 80, 40, Meadow.Foundation.Color.Cyan, false); + _graphics.DrawCircle(160, 80, 40, Meadow.Color.Cyan, false); int indent = 5; int spacing = 14; @@ -423,25 +423,25 @@ void ColorFontTest() _graphics.DrawText(indent, y, "Meadow F7 SPI ST7789!!"); - _graphics.DrawText(indent, y += spacing, "Red", Meadow.Foundation.Color.Red); + _graphics.DrawText(indent, y += spacing, "Red", Color.Red); - _graphics.DrawText(indent, y += spacing, "Purple", Meadow.Foundation.Color.Purple); + _graphics.DrawText(indent, y += spacing, "Purple", Color.Purple); - _graphics.DrawText(indent, y += spacing, "BlueViolet", Meadow.Foundation.Color.BlueViolet); + _graphics.DrawText(indent, y += spacing, "BlueViolet", Color.BlueViolet); - _graphics.DrawText(indent, y += spacing, "Blue", Meadow.Foundation.Color.Blue); + _graphics.DrawText(indent, y += spacing, "Blue", Color.Blue); - _graphics.DrawText(indent, y += spacing, "Cyan", Meadow.Foundation.Color.Cyan); + _graphics.DrawText(indent, y += spacing, "Cyan", Color.Cyan); - _graphics.DrawText(indent, y += spacing, "LawnGreen", Meadow.Foundation.Color.LawnGreen); + _graphics.DrawText(indent, y += spacing, "LawnGreen", Color.LawnGreen); - _graphics.DrawText(indent, y += spacing, "GreenYellow", Meadow.Foundation.Color.GreenYellow); + _graphics.DrawText(indent, y += spacing, "GreenYellow", Color.GreenYellow); - _graphics.DrawText(indent, y += spacing, "Yellow", Meadow.Foundation.Color.Yellow); + _graphics.DrawText(indent, y += spacing, "Yellow", Color.Yellow); - _graphics.DrawText(indent, y += spacing, "Orange", Meadow.Foundation.Color.Orange); + _graphics.DrawText(indent, y += spacing, "Orange", Color.Orange); - _graphics.DrawText(indent, y += spacing, "Brown", Meadow.Foundation.Color.Brown); + _graphics.DrawText(indent, y += spacing, "Brown", Color.Brown); _graphics.Show(); diff --git a/Source/Windows/SPI/MeadowApp.cs b/Source/Windows/SPI/MeadowApp.cs index b849167..bd05f55 100644 --- a/Source/Windows/SPI/MeadowApp.cs +++ b/Source/Windows/SPI/MeadowApp.cs @@ -1,8 +1,7 @@ using Meadow; -using Meadow.Foundation; using Meadow.Foundation.Displays; -using Meadow.Foundation.Graphics; using Meadow.Foundation.ICs.IOExpanders; +using Meadow.Peripherals.Displays; public class MeadowApp : App { diff --git a/Source/Windows/WifiWeather/Views/DisplayView.cs b/Source/Windows/WifiWeather/Views/DisplayView.cs index 8c8d6ee..3be207a 100644 --- a/Source/Windows/WifiWeather/Views/DisplayView.cs +++ b/Source/Windows/WifiWeather/Views/DisplayView.cs @@ -1,5 +1,6 @@ using Meadow.Foundation.Graphics; -using Meadow.Foundation.Graphics.MicroLayout; +using Meadow.Foundation.Graphics.MicroLayout; +using Meadow.Peripherals.Displays; namespace WifiWeather.Views { @@ -40,7 +41,7 @@ public class DisplayView Font12x16 font12X16 = new Font12x16(); Font8x16 font8X16 = new Font8x16(); - public DisplayView(IGraphicsDisplay display) + public DisplayView(IPixelDisplay display) { DisplayScreen = new DisplayScreen(display) { diff --git a/Source/Windows/WinForms/Views/AtmosphericHMI.cs b/Source/Windows/WinForms/Views/AtmosphericHMI.cs index 4358c97..59bfa1a 100644 --- a/Source/Windows/WinForms/Views/AtmosphericHMI.cs +++ b/Source/Windows/WinForms/Views/AtmosphericHMI.cs @@ -1,5 +1,6 @@ using Meadow.Foundation.Graphics; using Meadow.Foundation.Graphics.MicroLayout; +using Meadow.Peripherals.Displays; using System; using System.Threading.Tasks; @@ -25,7 +26,7 @@ public class AtmosphericHMI Font12x20 font12X20 = new Font12x20(); - public AtmosphericHMI(IGraphicsDisplay display) + public AtmosphericHMI(IPixelDisplay display) { DisplayScreen = new DisplayScreen(display) { diff --git a/Source/Windows/WinForms/Views/CultivarView.cs b/Source/Windows/WinForms/Views/CultivarView.cs index 7c6fa71..0bdf2bd 100644 --- a/Source/Windows/WinForms/Views/CultivarView.cs +++ b/Source/Windows/WinForms/Views/CultivarView.cs @@ -1,5 +1,6 @@ using Meadow.Foundation.Graphics; using Meadow.Foundation.Graphics.MicroLayout; +using Meadow.Peripherals.Displays; using System; using System.Threading.Tasks; @@ -37,7 +38,7 @@ public class CultivarView protected Picture ledHeater { get; set; } - public CultivarView(IGraphicsDisplay _display) + public CultivarView(IPixelDisplay _display) { screen = new DisplayScreen(_display); diff --git a/Source/Windows/WinForms/Views/HomeWidget.cs b/Source/Windows/WinForms/Views/HomeWidget.cs index 5695683..d7b759f 100644 --- a/Source/Windows/WinForms/Views/HomeWidget.cs +++ b/Source/Windows/WinForms/Views/HomeWidget.cs @@ -1,6 +1,7 @@ using Meadow; using Meadow.Foundation.Graphics; using Meadow.Foundation.Graphics.MicroLayout; +using Meadow.Peripherals.Displays; using System; using System.Threading.Tasks; @@ -45,7 +46,7 @@ public class HomeWidget Font12x20 font12X20 = new Font12x20(); Font6x8 font6x8 = new Font6x8(); - public HomeWidget(IGraphicsDisplay display) + public HomeWidget(IPixelDisplay display) { DisplayScreen = new DisplayScreen(display) { diff --git a/Source/Windows/WinForms/Views/ProjectLabDemoView.cs b/Source/Windows/WinForms/Views/ProjectLabDemoView.cs index e465051..42df0ae 100644 --- a/Source/Windows/WinForms/Views/ProjectLabDemoView.cs +++ b/Source/Windows/WinForms/Views/ProjectLabDemoView.cs @@ -1,5 +1,6 @@ using Meadow.Foundation.Graphics; using Meadow.Foundation.Graphics.MicroLayout; +using Meadow.Peripherals.Displays; using System; using System.Threading.Tasks; @@ -92,7 +93,7 @@ internal class ProjectLabDemoView private Font8x16 font8x16 = new Font8x16(); private Font6x8 font6x8 = new Font6x8(); - public ProjectLabDemoView(IGraphicsDisplay display) + public ProjectLabDemoView(IPixelDisplay display) { DisplayScreen = new DisplayScreen(display) { diff --git a/Source/Windows/WinForms/Views/WiFiWeather.cs b/Source/Windows/WinForms/Views/WiFiWeather.cs index 1c05c3b..29e4da3 100644 --- a/Source/Windows/WinForms/Views/WiFiWeather.cs +++ b/Source/Windows/WinForms/Views/WiFiWeather.cs @@ -1,5 +1,6 @@ using Meadow.Foundation.Graphics; using Meadow.Foundation.Graphics.MicroLayout; +using Meadow.Peripherals.Displays; using System; using System.Threading.Tasks; @@ -42,7 +43,7 @@ public class WiFiWeather Font12x16 font12X16 = new Font12x16(); Font8x16 font8X16 = new Font8x16(); - public WiFiWeather(IGraphicsDisplay display) + public WiFiWeather(IPixelDisplay display) { DisplayScreen = new DisplayScreen(display) { diff --git a/Source/Windows/WinForms/Views/WifiWeatherV2.cs b/Source/Windows/WinForms/Views/WifiWeatherV2.cs index d4cbf30..a419d79 100644 --- a/Source/Windows/WinForms/Views/WifiWeatherV2.cs +++ b/Source/Windows/WinForms/Views/WifiWeatherV2.cs @@ -1,6 +1,7 @@ using Meadow; using Meadow.Foundation.Graphics; using Meadow.Foundation.Graphics.MicroLayout; +using Meadow.Peripherals.Displays; using System; using System.Collections.Generic; using System.Threading.Tasks; @@ -56,7 +57,7 @@ internal class WifiWeatherV2 protected Label Sunrise { get; set; } protected Label Sunset { get; set; } - public WifiWeatherV2(IGraphicsDisplay display) + public WifiWeatherV2(IPixelDisplay display) { DisplayScreen = new DisplayScreen(display) {