forked from WildernessLabs/Clima
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Projects renamed to shorten URL paths
- Loading branch information
Showing
139 changed files
with
262 additions
and
261 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
34 changes: 17 additions & 17 deletions
34
.../WildernessLabs.Clima.Contracts.projitems → ...CommonContracts/CommonContracts.projitems
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,18 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | ||
<PropertyGroup> | ||
<MSBuildAllProjects>$(MSBuildAllProjects);$(MSBuildThisFileFullPath)</MSBuildAllProjects> | ||
<HasSharedItems>true</HasSharedItems> | ||
<SharedGUID>{567267B3-ED96-4FEA-B555-2EE203372EA4}</SharedGUID> | ||
</PropertyGroup> | ||
<PropertyGroup Label="Configuration"> | ||
<Import_RootNamespace>Clima.Contracts</Import_RootNamespace> | ||
</PropertyGroup> | ||
<ItemGroup> | ||
<Folder Include="$(MSBuildThisFileDirectory)Models\" /> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<Compile Include="$(MSBuildThisFileDirectory)DTUs\ClimateReadingEntity.cs" /> | ||
<Compile Include="$(MSBuildThisFileDirectory)Models\ClimateReading.cs" /> | ||
</ItemGroup> | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | ||
<PropertyGroup> | ||
<MSBuildAllProjects>$(MSBuildAllProjects);$(MSBuildThisFileFullPath)</MSBuildAllProjects> | ||
<HasSharedItems>true</HasSharedItems> | ||
<SharedGUID>{567267B3-ED96-4FEA-B555-2EE203372EA4}</SharedGUID> | ||
</PropertyGroup> | ||
<PropertyGroup Label="Configuration"> | ||
<Import_RootNamespace>Clima.Contracts</Import_RootNamespace> | ||
</PropertyGroup> | ||
<ItemGroup> | ||
<Folder Include="$(MSBuildThisFileDirectory)Models\" /> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<Compile Include="$(MSBuildThisFileDirectory)DTUs\ClimateReadingEntity.cs" /> | ||
<Compile Include="$(MSBuildThisFileDirectory)Models\ClimateReading.cs" /> | ||
</ItemGroup> | ||
</Project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
122 changes: 61 additions & 61 deletions
122
...dernessLabs.Clima.Meadow.Pro/MeadowApp.cs → Source/Clima/MeadowClimaKit/MeadowApp.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,62 +1,62 @@ | ||
using MeadowProKit.DataAccessLayer; | ||
using MeadowProKit.Models; | ||
using MeadowProKit.Server.Bluetooth; | ||
using Meadow; | ||
using Meadow.Devices; | ||
using Meadow.Foundation; | ||
using Meadow.Foundation.Leds; | ||
using Meadow.Gateway.WiFi; | ||
using System; | ||
using System.Threading.Tasks; | ||
|
||
namespace MeadowProKit | ||
{ | ||
public class MeadowApp : App<F7MicroV2, MeadowApp> | ||
{ | ||
//==== Controllers and such | ||
public MeadowApp() | ||
{ | ||
Console.WriteLine("MeadowApp constructor started."); | ||
|
||
//==== new up our peripherals | ||
Initialize(); | ||
|
||
//==== subscribe to climate updates and save them to the database | ||
ClimateMonitorAgent.Instance.ClimateConditionsUpdated += (s, e) => | ||
{ | ||
DebugOut(e.New); | ||
LocalDbManager.Instance.SaveReading(e.New); | ||
}; | ||
ClimateMonitorAgent.Instance.StartUpdating(TimeSpan.FromSeconds(10)); | ||
|
||
Console.WriteLine("MeadowApp constructor finished."); | ||
} | ||
|
||
//==== Initializes the hardware. | ||
protected void Initialize() | ||
{ | ||
Console.WriteLine("Hardware initialization started."); | ||
var onboardLed = new RgbPwmLed(device: Device, | ||
redPwmPin: Device.Pins.OnboardLedRed, | ||
greenPwmPin: Device.Pins.OnboardLedGreen, | ||
bluePwmPin: Device.Pins.OnboardLedBlue); | ||
|
||
onboardLed.SetColor(WildernessLabsColors.ChileanFire); | ||
|
||
BluetoothServer.Instance.Initialize(); | ||
|
||
onboardLed.SetColor(Color.Green); | ||
Console.WriteLine("Hardware initialization complete."); | ||
} | ||
|
||
protected void DebugOut(Climate climate) | ||
{ | ||
Console.WriteLine("New climate reading:"); | ||
Console.WriteLine($"Temperature: {climate.Temperature?.Celsius:N2}C"); | ||
Console.WriteLine($"Pressure: {climate.Pressure?.Millibar:N2}millibar"); | ||
Console.WriteLine($"Humidity: {climate.Humidity:N2}%"); | ||
Console.WriteLine($"Wind Speed: {climate.WindSpeed?.KilometersPerHour}"); | ||
Console.WriteLine($"Wind Direction: {climate.WindDirection?.Compass16PointCardinalName}"); | ||
} | ||
} | ||
using MeadowProKit.DataAccessLayer; | ||
using MeadowProKit.Models; | ||
using MeadowProKit.Server.Bluetooth; | ||
using Meadow; | ||
using Meadow.Devices; | ||
using Meadow.Foundation; | ||
using Meadow.Foundation.Leds; | ||
using Meadow.Gateway.WiFi; | ||
using System; | ||
using System.Threading.Tasks; | ||
|
||
namespace MeadowProKit | ||
{ | ||
public class MeadowApp : App<F7MicroV2, MeadowApp> | ||
{ | ||
//==== Controllers and such | ||
public MeadowApp() | ||
{ | ||
Console.WriteLine("MeadowApp constructor started."); | ||
|
||
//==== new up our peripherals | ||
Initialize(); | ||
|
||
//==== subscribe to climate updates and save them to the database | ||
ClimateMonitorAgent.Instance.ClimateConditionsUpdated += (s, e) => | ||
{ | ||
DebugOut(e.New); | ||
LocalDbManager.Instance.SaveReading(e.New); | ||
}; | ||
ClimateMonitorAgent.Instance.StartUpdating(TimeSpan.FromSeconds(10)); | ||
|
||
Console.WriteLine("MeadowApp constructor finished."); | ||
} | ||
|
||
//==== Initializes the hardware. | ||
protected void Initialize() | ||
{ | ||
Console.WriteLine("Hardware initialization started."); | ||
var onboardLed = new RgbPwmLed(device: Device, | ||
redPwmPin: Device.Pins.OnboardLedRed, | ||
greenPwmPin: Device.Pins.OnboardLedGreen, | ||
bluePwmPin: Device.Pins.OnboardLedBlue); | ||
|
||
onboardLed.SetColor(WildernessLabsColors.ChileanFire); | ||
|
||
BluetoothServer.Instance.Initialize(); | ||
|
||
onboardLed.SetColor(Color.Green); | ||
Console.WriteLine("Hardware initialization complete."); | ||
} | ||
|
||
protected void DebugOut(Climate climate) | ||
{ | ||
Console.WriteLine("New climate reading:"); | ||
Console.WriteLine($"Temperature: {climate.Temperature?.Celsius:N2}C"); | ||
Console.WriteLine($"Pressure: {climate.Pressure?.Millibar:N2}millibar"); | ||
Console.WriteLine($"Humidity: {climate.Humidity:N2}%"); | ||
Console.WriteLine($"Wind Speed: {climate.WindSpeed?.KilometersPerHour}"); | ||
Console.WriteLine($"Wind Direction: {climate.WindDirection?.Compass16PointCardinalName}"); | ||
} | ||
} | ||
} |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
30 changes: 15 additions & 15 deletions
30
...rnessLabs.Clima.Meadow.HackKit/Secrets.cs → Source/Clima/MeadowHackKit/Secrets.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
namespace MeadowHackKit | ||
{ | ||
public class Secrets | ||
{ | ||
/// <summary> | ||
/// Name of the WiFi network to use. | ||
/// </summary> | ||
public const string WIFI_NAME = "[SSID]"; | ||
|
||
/// <summary> | ||
/// Password for the WiFi network names in WIFI_NAME. | ||
/// </summary> | ||
public const string WIFI_PASSWORD = "[PASSWORD]"; | ||
} | ||
} | ||
namespace MeadowHackKit | ||
{ | ||
public class Secrets | ||
{ | ||
/// <summary> | ||
/// Name of the WiFi network to use. | ||
/// </summary> | ||
public const string WIFI_NAME = "[SSID]"; | ||
|
||
/// <summary> | ||
/// Password for the WiFi network names in WIFI_NAME. | ||
/// </summary> | ||
public const string WIFI_PASSWORD = "[PASSWORD]"; | ||
} | ||
} |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...nt.Android/Properties/AndroidManifest.xml → ...pp.Android/Properties/AndroidManifest.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
4 changes: 2 additions & 2 deletions
4
...lient.Android/Renderers/StylelessEntry.cs → ...leApp.Android/Renderers/StylelessEntry.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
...ient.Android/Renderers/StylelessPicker.cs → ...eApp.Android/Renderers/StylelessPicker.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
...t/WildernessLabs.Clima.Client/App.xaml.cs → ...ima/MobileApp/MobileApp.Forms/App.xaml.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
Oops, something went wrong.