.NET Core Quicksstarts Done quickly with one PowerShell script start to finish.

%3CLINGO-SUB%20id%3D%22lingo-sub-1199678%22%20slang%3D%22en-US%22%3E.NET%20Core%20Quicksstarts%20Done%20quickly%20with%20one%20PowerShell%20script%20start%20to%20finish.%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1199678%22%20slang%3D%22en-US%22%3E%3CP%3EI%20have%20a%20long%20time%20felt%20that%20the%20.NET%20Core%20C%23%20%3CA%20title%3D%22Azure%20IOT%20Hub%20Quickstarts%3A%20Telemetry%22%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fazure%2Fiot-hub%2Fquickstart-send-telemetry-dotnet%22%20target%3D%22_self%22%20rel%3D%22noopener%20noreferrer%22%3EQuickstarts%3C%2FA%3E%20for%20the%20Azure%20IoT%20Hub%20SDK%20could%20be%20simpler%20for%20a%20newbie.%20To%20that%20end%20I%20created%20the%20UWP%20apps%26nbsp%3B%3CA%20title%3D%22Azure%20IoT%20Hub%20Device%20Streaming%22%20href%3D%22https%3A%2F%2Fgithub.com%2Fdjaus2%2FAziothubDeviceStreaming%22%20target%3D%22_self%22%20rel%3D%22noopener%20noreferrer%22%3EAzure%20IoT%20Hub%20Device%20Streaming%3C%2FA%3E%20and%20then%20%3CA%20title%3D%22Azure%20IoT%20Hub%20Toolbox%22%20href%3D%22https%3A%2F%2Fgithub.com%2Fdjaus2%2FAzure.IoTHub.Toolbox%22%20target%3D%22_self%22%20rel%3D%22noopener%20noreferrer%22%3EAzure%20IoT%20Hub%20Toolbox.%2C%3C%2FA%3E%20as%20available%20on%20GitHub%20and%20in%20%3CA%20href%3D%22https%3A%2F%2Fwww.microsoft.com%2Fen-au%2Fp%2Fazureiothubtoolbox%2F9pmcf9clttwz%3Factivetab%3Dpivot%3Aoverviewtab%22%20target%3D%22_self%22%20rel%3D%22noopener%20noreferrer%22%3EThe%20Store%3C%2FA%3E.%20These%20encapsulated%20the%20Quickstart%20functionality%20and%20orchestrated%20IoT%20Hub%20creation.%26nbsp%3B%20This%20latest%20salvo%20into%20this%20area%20can%20make%20it%20even%20simpler!%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EYou%20run%20one%20PowerShell%20script%20with%20which%20you%20can%20create%20an%20IoT%20Hub%2C%20get%20all%20of%20the%20connection%20strings%2C%20save%20them%20to%20environment%20variables%2C%20create%20PowerShell%20and%20Bash%20scripts%20to%20re-set%20those%20variables%2C%20get%20the%20required%20targeted%26nbsp%3B%20.NET%20Core%20SK%20binary%20including%20expansion%20of%20the%20download%20amongst%20other%20things.%20Included%20is%20a%20copy%20of%20the%20Quickstarts%20modified%20so%20that%20all%20apps%20get%20the%20required%20connection%20strings%20from%20the%20environment%20variables.%20A%20couple%20of%20variants%20to%20the%20apps%20have%20been%20added.%20More%20coming%2C%20especially%20with%20RPi%20hardware%20use.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22Capture.PNG%22%20style%3D%22width%3A%20541px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F173980i71C411508D2EB4C4%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22Capture.PNG%22%20alt%3D%22Capture.PNG%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThe%20PowerShell%20script%20and%20its%20underlying%20scripts%20is%20available%20on%20GitHub%20as%26nbsp%3B%3CA%20title%3D%22Azure%20IoT%20Hub%20PowerShell%20Scripts%22%20href%3D%22https%3A%2F%2Fgithub.com%2Fdjaus2%2Faz-iothub-ps%22%20target%3D%22_self%22%20rel%3D%22noopener%20noreferrer%22%3EAzure%20IoT%20Hub%20PowerShell%20Scripts%3C%2FA%3E%20.%20It%20is%20a%20menu%20driven%20UI%2C%20with%20a%20bit%20of%20color%20included!.%26nbsp%3B%20I%20have%20written%20as%20series%20of%20blogs%20on%20.NET%20Core%2C%20especially%20on%20the%20RaspberryPi%20(IoT-Core%20and%20Raspian)%20and%20upon%20running%20the%20Quickstarts%20there%20via%20the%20PowerShell%20script%20on%20my%20blog%20at%26nbsp%3B%20%3CA%20href%3D%22http%3A%2F%2Fwww.sportronics.com.au%22%20target%3D%22_self%22%20rel%3D%22nofollow%20noopener%20noreferrer%22%3Ehttp%3A%2F%2Fwww.sportronics.com.au%3C%2FA%3E%20.Here%20are%20the%20specific%20links%3A%3C%2FP%3E%3CP%3E%3CEM%3E(Note%3A%20In%20reverse%20order)%3C%2FEM%3E%3C%2FP%3E%3CUL%3E%3CLI%3E%3CA%20href%3D%22http%3A%2F%2Fwww.sportronics.com.au%2Fdotnetcoreiot%2F.NET_Core_on_IoT-_One_more_way_of_doing_this_-_How_to-dotnetcoreiot.html%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noreferrer%22%3ERemote%20Publishing%20to%20the%20RPI%3C%2FA%3E%3C%2FLI%3E%3CLI%3E%3CA%20href%3D%22http%3A%2F%2Fwww.sportronics.com.au%2Fdotnetcoreiot%2F.NET_Core_on_IoT-One_more_way_of_doing_this-dotnetcoreiot.html%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noreferrer%22%3EOne%20more%20way%20of%20doing%20this%20-%20Background%3C%2FA%3E%3C%2FLI%3E%3CLI%3E%3CA%20href%3D%22http%3A%2F%2Fwww.sportronics.com.au%2Fdotnetcoreiot%2F.NET_Core_on_IoT-_Using_the_PS_Script_to_run_Quickstarts_on_RPi_(Raspian)_.html%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noreferrer%22%3EUsing%20the%20PS%20Script%20to%20run%20Quickstarts%20on%20RPi%20(Raspian)%3C%2FA%3E%3C%2FLI%3E%3CLI%3E%3CA%20href%3D%22http%3A%2F%2Fwww.sportronics.com.au%2Fdotnetcoreiot%2F.NET_Core_on_IoT-_Using_the_PS_Script_to_run_Quickstarts_on_RPi_(IoT-Core)_-_Simpler-dotnetcoreiot.html%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noreferrer%22%3EUsing%20the%20PS%20Script%20to%20run%20Quickstarts%20on%20RPi%20(IoT-Core)%20-%20Simpler%3C%2FA%3E%3C%2FLI%3E%3CLI%3E%3CA%20href%3D%22http%3A%2F%2Fwww.sportronics.com.au%2Fdotnetcoreiot%2F.NET_Core_on_IoT-Using_PS_Script_to_run_Quickstarts_on_RPi_(IoT-Core)-dotnetcoreiot.html%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noreferrer%22%3EUsing%20the%20PS%20Script%20to%20run%20Quickstarts%20on%20RPi%20(IoT-Core)%3C%2FA%3E%3C%2FLI%3E%3CLI%3E%3CA%20href%3D%22http%3A%2F%2Fwww.sportronics.com.au%2Fdotnetcoreiot%2F.NET_Core_on_IoT-Az-IoTHub-PS_The_IOT_Hub_Quickstart_Apps-dotnetcoreiot.html%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noreferrer%22%3EAz-IoTHub-PS%20...%20The%20IoT%20Hub%20Quickstart%20Apps%3C%2FA%3E%3C%2FLI%3E%3CLI%3E%3CA%20href%3D%22http%3A%2F%2Fwww.sportronics.com.au%2Fdotnetcoreiot%2F.NET_Core_on_IoT-Use_the_PS_Script_to_set_up_.NET_Core-dotnetcoreiot.html%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noreferrer%22%3EUse%20the%20PS%20Script%20to%20set%20up%20.NET%20Core%3C%2FA%3E%3C%2FLI%3E%3CLI%3E%3CA%20href%3D%22http%3A%2F%2Fwww.sportronics.com.au%2Fdotnetcoreiot%2F.NET_Core_on_IoT-Fast_tracking_IoT_Hub_Creation_with_PS-dotnetcoreiot.html%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noreferrer%22%3EFast%20tracking%20IoT%20Hub%20Creation%20with%20PS%3C%2FA%3E%3C%2FLI%3E%3CLI%3E%3CA%20href%3D%22http%3A%2F%2Fwww.sportronics.com.au%2Fdotnetcoreiot%2F.NET_Core_on_IoT-On_Windows_Subsystem_for_Linux-dotnetcoreiot.html%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noreferrer%22%3EOn%20Windows%20Subsystem%20for%20Linux%3C%2FA%3E%3C%2FLI%3E%3CLI%3E%3CA%20href%3D%22http%3A%2F%2Fwww.sportronics.com.au%2Fdotnetcoreiot%2F_.NET_Core_on_IoT-Getting_started_on__Raspbian-dotnetcoreiot.html%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noreferrer%22%3EGetting%20started%20on%20Raspbian%3C%2FA%3E%3C%2FLI%3E%3CLI%3E%3CA%20href%3D%22http%3A%2F%2Fwww.sportronics.com.au%2Fdotnetcoreiot%2F_.NET_Core_on_IoT-Getting_started_on_Win_10_IoT-Core-dotnetcoreiot.html%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noreferrer%22%3EGetting%20started%20on%20Win%2010%20IoT%20Core%3C%2FA%3E%3C%2FLI%3E%3CLI%3E%3CA%20href%3D%22http%3A%2F%2Fwww.sportronics.com.au%2Fdotnetcoreiot%2F.NET_Core_on_IoT-Options_for_the_RPi-dotnetcoreiot.html%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noreferrer%22%3EOptions%20for%20the%20RPi%3C%2FA%3E%3C%2FLI%3E%3CLI%3E%3CA%20href%3D%22http%3A%2F%2Fwww.sportronics.com.au%2Fdotnetcoreiot%2F.NET_Core_on_IoT-Some_key_facts-dotnetcoreiot.html%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noreferrer%22%3ESome%20key%20facts%3C%2FA%3E%3C%2FLI%3E%3CLI%3E%3CA%20href%3D%22http%3A%2F%2Fwww.sportronics.com.au%2Fdotnetcoreiot%2Fdnetcore-on-IoT-Apps-dotnetcoreiot.html%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noreferrer%22%3EQuickstart%20Apps%3C%2FA%3E%3C%2FLI%3E%3CLI%3E%3CA%20href%3D%22http%3A%2F%2Fwww.sportronics.com.au%2Fdotnetcoreiot%2Fdnetcore-on-IoT-dotnetcoreiot.html%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noreferrer%22%3EOverview%3C%2FA%3E%3C%2FLI%3E%3C%2FUL%3E%3CP%3EExtra%3A%3CA%20href%3D%22http%3A%2F%2Fwww.sportronics.com.au%2Fdotnetcoreiot%2F.NET_Core_on_IoT-Using_the_az-iothub-ps_script-dotnetcoreiot.html%22%20target%3D%22_self%22%20rel%3D%22nofollow%20noopener%20noreferrer%22%3E%26nbsp%3BUsing%20the%20az-iothub-ps%20script%3C%2FA%3E%3C%2FP%3E%3CP%3EAlso%20a%20presentation%20on%20%3CA%20href%3D%22http%3A%2F%2Fwww.sportronics.com.au%2Fmedia%2Fdnc.pptx%22%20target%3D%22_self%22%20rel%3D%22nofollow%20noopener%20noreferrer%22%3E.NET%20Core%20on%20the%20RPI%20(the%20PPT%20slide%20deck)%3C%2FA%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-1199678%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3E.net-core%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EAzure%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3Eiot-hub%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1203088%22%20slang%3D%22en-US%22%3ERe%3A%20.NET%20Core%20Quicksstarts%20Done%20quickly%20with%20one%20PowerShell%20script%20start%20to%20finish.%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1203088%22%20slang%3D%22en-US%22%3E%3CP%3EThe%20script%20now%20has%20a%20%22one%20touch%20option%22.%20You%20now%20can%20do%20it%20all%20with%20one%20command.%3C%2FP%3E%3CP%3E%3CA%20href%3D%22http%3A%2F%2Fwww.sportronics.com.au%2Fdotnetcoreiot%2F.NET_Core_on_IoT-You_can_now_fully_automate_Group-Hub-Device_creation-dotnetcoreiot.htm%22%20target%3D%22_self%22%20rel%3D%22nofollow%20noopener%20noreferrer%22%3EAbout%20one%20touch%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1210500%22%20slang%3D%22en-US%22%3ENow%20even%20easier%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1210500%22%20slang%3D%22en-US%22%3E%3CP%3EIt%20just%20got%20even%20easier!%20Just%20enter%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CPRE%20class%3D%22lia-code-sample%20language-markup%22%3E%3CCODE%3Eget-iothub%20groupname%2Chubname%2Cdevice%2Cname%3C%2FCODE%3E%3C%2FPRE%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EAnd%20your%20away!%26nbsp%3B%3CA%20href%3D%22http%3A%2F%2Fwww.sportronics.com.au%2Fdotnetcoreiot%2F_.NET_Core_on_IoT-It's_now_even_easier._Enter_names_on_command_line.-dotnetcoreiot.html%22%20target%3D%22_self%22%20rel%3D%22nofollow%20noopener%20noreferrer%22%3EAbout%20this%20new%20feature%20on%20my%20blog.%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EUsual%20setup%20as%20per%20blog%20articles.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1229838%22%20slang%3D%22en-US%22%3ERe%3A%20Now%20even%20easier%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1229838%22%20slang%3D%22en-US%22%3E%3CP%3EAnd%3C%2FP%3E%3CPRE%20class%3D%22lia-code-sample%20language-markup%22%3E%3CCODE%3Eget-iothub%20groupname%2Chubname%2Cdevice%2Cname%205%3C%2FCODE%3E%3C%2FPRE%3E%3CP%3Ewill%20completely%20autorun%20to%20completion%20once%20you%20select%20a%20couple%20of%20things%2C%20with%20only%205%20sec%20pauses%20instead%20of%20the%20%3CEM%3E%3CSTRONG%3Epress-any-key-to-continue%3C%2FSTRONG%3E%3C%2FEM%3E%26nbsp%3B%20messages.%3C%2FP%3E%3C%2FLINGO-BODY%3E
Contributor

I have a long time felt that the .NET Core C# Quickstarts for the Azure IoT Hub SDK could be simpler for a newbie. To that end I created the UWP apps Azure IoT Hub Device Streaming and then Azure IoT Hub Toolbox., as available on GitHub and in The Store. These encapsulated the Quickstart functionality and orchestrated IoT Hub creation.  This latest salvo into this area can make it even simpler!

 

You run one PowerShell script with which you can create an IoT Hub, get all of the connection strings, save them to environment variables, create PowerShell and Bash scripts to re-set those variables, get the required targeted  .NET Core SK binary including expansion of the download amongst other things. Included is a copy of the Quickstarts modified so that all apps get the required connection strings from the environment variables. A couple of variants to the apps have been added. More coming, especially with RPi hardware use.

 

Capture.PNG

 

The PowerShell script and its underlying scripts is available on GitHub as Azure IoT Hub PowerShell Scripts . It is a menu driven UI, with a bit of color included!.  I have written as series of blogs on .NET Core, especially on the RaspberryPi (IoT-Core and Raspian) and upon running the Quickstarts there via the PowerShell script on my blog at  http://www.sportronics.com.au .Here are the specific links:

(Note: In reverse order)

Extra: Using the az-iothub-ps script

Also a presentation on .NET Core on the RPI (the PPT slide deck)

 

 

3 Replies

The script now has a "one touch option". You now can do it all with one command.

About one touch 

It just got even easier! Just enter 

 

get-iothub groupname,hubname,device,name

 

And your away! About this new feature on my blog. 

 

Usual setup as per blog articles.

And

get-iothub groupname,hubname,device,name 5

will completely autorun to completion once you select a couple of things, with only 5 sec pauses instead of the press-any-key-to-continue  messages.