diff --git a/RELEASE_NOTES.md b/RELEASE_NOTES.md index de0843c..4c76f0a 100644 --- a/RELEASE_NOTES.md +++ b/RELEASE_NOTES.md @@ -1,6 +1,9 @@ # Release Notes -## 1.1.16 - 2019-03-17 +## 1.2.0 - 2019-03-19 +* Update .NET Core to 2.2.3 + +## 1.1.16 - 2019-03-1 * Upgrade Raspbian ## 1.1.0 - 2019-01-20 diff --git a/src/Client/ReleaseNotes.fs b/src/Client/ReleaseNotes.fs index 0d49e50..4eb9335 100644 --- a/src/Client/ReleaseNotes.fs +++ b/src/Client/ReleaseNotes.fs @@ -1,13 +1,16 @@ module internal ReleaseNotes -let Version = "1.1.16" +let Version = "1.2.0" let IsPrerelease = false let Notes = """ # Release Notes -## 1.1.16 - 2019-03-17 +## 1.2.0 - 2019-03-19 +* Update .NET Core to 2.2.3 + +## 1.1.16 - 2019-03-1 * Upgrade Raspbian ## 1.1.0 - 2019-01-20 diff --git a/src/PiServer/PiServer.fs b/src/PiServer/PiServer.fs index e7a7860..3e89085 100644 --- a/src/PiServer/PiServer.fs +++ b/src/PiServer/PiServer.fs @@ -104,19 +104,12 @@ let rfidLoop (dispatch,nodeServices:INodeServices) = task { waiting <- false } -let getMACAddress() = - NetworkInterface.GetAllNetworkInterfaces() - |> Seq.filter (fun nic -> - nic.OperationalStatus = OperationalStatus.Up && - nic.NetworkInterfaceType <> NetworkInterfaceType.Loopback) - |> Seq.map (fun nic -> nic.GetPhysicalAddress().ToString()) - |> Seq.tryHead let init nodeServices : Model * Cmd = { Playing = None FirmwareUpdateInterval = TimeSpan.FromHours 1. UserID = - getMACAddress() + Utils.getMACAddress() |> Option.defaultValue "9bb2b109-bf08-4342-9e09-f4ce3fb01c0f" // TODO: load from some config TagServer = "https://audio-hub.azurewebsites.net" // TODO: load from some config Volume = 0.5 // TODO: load from webserver diff --git a/src/PiServer/Utils.fs b/src/PiServer/Utils.fs new file mode 100644 index 0000000..70ddf1e --- /dev/null +++ b/src/PiServer/Utils.fs @@ -0,0 +1,11 @@ +module Utils +open System.Net.NetworkInformation + + +let getMACAddress() = + NetworkInterface.GetAllNetworkInterfaces() + |> Seq.filter (fun nic -> + nic.OperationalStatus = OperationalStatus.Up && + nic.NetworkInterfaceType <> NetworkInterfaceType.Loopback) + |> Seq.map (fun nic -> nic.GetPhysicalAddress().ToString()) + |> Seq.tryHead diff --git a/src/Server/Server.fsproj b/src/Server/Server.fsproj index 6e20210..a971df1 100644 --- a/src/Server/Server.fsproj +++ b/src/Server/Server.fsproj @@ -10,6 +10,7 @@ +