Monday, February 8, 2016

MVC, MVP & MVVM - Architectural Patterns.



MVC - Model–View–Controller (MVC) is a software architectural pattern mostly (but not exclusively) for implementing user interfaces on computers. Traditionally used for desktop graphical user interfaces (GUIs), this architecture has become extremely popular for designing web applications.
MVC - Framework Library: Early web MVC frameworks took a thin client approach that placed almost the entire model, view and controller logic on the server. This is still reflected in popular frameworks such as Ruby on Rails, Django, ASP.NET MVC, Spring MVC and Express. Client technologies have matured; frameworks such as AngularJS, EmberJS, JavaScriptMVC, SpineJS and Backbone have been created that allow the MVC components to execute partly on the client.

MVP - Model-View-Presenter (MVP) is a derivation of the model–view–controller (MVC) architectural pattern, and is used mostly for building user interfaces. MVP is a user interface architectural pattern engineered to facilitate automated unit testing and improve the separation of concerns in presentation logic:

  • the view is a passive interface that displays data (the model) and routes user commands (events) to the presenter to act upon that data.  
  • the model is an interface defining the data to be displayed or otherwise acted upon in the user interface.
  • the presenter acts upon the model and the view. It retrieves data from repositories (the model), and formats it for display in the view.
 
MVP - Framework Library: Client Side- Riot.js, GWT   whereas Server Side - Classic ASP.NET, JSP Servlets. In general implementation of MVP: 
  • .Net Framework - Claymore, MVC# Framework, Web Client Software Factory, Evolution.Net MVP Framework, ASP.NET Web Forms Model-View-Presenter (MVP), Nucleo.NET, WinForms MVP
  •  Java Framework - JavaFX, MVP4J, Echo2, Google Web Toolkit, GWT-Platform, JFace, Swing, Vaadin, ZK
  •  PHP Framework - Nette Framework

MVVM - Model–View–ViewModel (MVVM) is a software architectural pattern. MVVM and Presentation Model both derive from the model–view–controller pattern (MVC). MVVM facilitates a separation of development of the graphical user interface (either as markup language or GUI code) from development of the business logic or back-end logic (the data model). Model–view–viewmodel is called model–view–binder, especially in implementations not involving the .NET platform. ZK (a web application framework written in Java) and KnockoutJS (a JavaScript library) use model–view–binder. The MVVM pattern includes three key parts:
  1. Model (Business rule, data access, model classes)
  2. View (User interface (XAML))
  3. ViewModel (Agent or middle man between view and model)
 
MVVM - Framework Library: Client side - Knockout.js, Kendo (MVVM) whereas Server side - WPF (Desk­top) or Sil­verlight, Win­dows Phone apps (XAML), Adobe Flex.  
When to use which?   
  • MVC - Use in situations where the connection between the view and the rest of theprogram is not always available (and you can’t effectively employ MVVM or MVP)
  • MVP - Use in situations where binding via a datacontext is not possible. 
  • MVVM - Use in situations where binding via a datacontext is possible. 
 
Both MVP and MVVM are deriv­a­tives of MVC (see time­lines and how these have evolved). The key dif­fer­ence between them is the depen­dency each layer has on other lay­ers as well as how tightly bound they are to each other. 

Wednesday, February 3, 2016

Developers concern and take on against Parse (MBaaS) cloud service shut down.


In  this blog we are going to discuss about the challenge and alternate approach of an initiative or best practice adoption after shutting down the Parse service i.e, mobile backend as a service (MBaaS).

As we all know that Facebook has made an announcement about shutting down the Parse cloud service. Currently it's not closed, it will stick around till up to the time of  next year i.e., 28 Jan 2017.

Facebook Parse chief technology officer Kevin Lacker wrote in a blog post,  "We’re proud that we’ve been able to help so many of you build great mobile apps, but we need to focus our resources elsewhere".

Challenge:

After Parse shut down, developer must look elsewhere,

Migration in new environment from existing one,

Dealing and convincing to the existing customers/clients, costing, manpower.. so on

 Growing backend and architecture services team, etc.

Alternative Solution Approach:

 Before we move on towards new alternate adoption it is good to analyze about what features are we looking for ? The list of services are:
  • Data Storage
  • Push Notifications
  • Usage Analytics
  • Dashboard
  • Social Integration
  • User Administration
  • Cloud Code Integration
  • Multiple Mobile Platform SDKs
  • Background Jobs 
  • Crash Report
The 'Github Development Community' step ahead of this challenge and a great list of Parse alternatives has already emerged as a result.
In next what developers can do ?
  1. Migrate and Host Own Parse Server: Parse has provided a Migration Guide (https://parse.com/docs/server/guide#migrating). Facebook is open-sourcing Parse Server and making available a database migration tool to help move apps off of Parse, that lets you migrate data from Parse app to any MongoDB database. Developers will run most of the Parse API from their own Node.js servers (or one hosted on a platform like Heroku). 
  2. Switch to Another SaaS:  Developers need to update their application(s) to leverage new SaaS environment as its backend service, this could also be a great time to upgrade app(s) with improved or added functionality.
  3. Build Own Backend Solution: SaaS platforms are great for MVPs, rapid prototyping, personal projects, and powering smaller features of larger products. If your application needs to be built to scale, is mission critical, and continues to evolve with custom needs, it may be a better business strategy to build your own backend. This way you maintain complete control and can leverage it as a competitive advantage.
The difference with Parse is that it has attracted more developers than the existing platforms because of its easy-to-use and well-documented SDKs, highly competitive (often free) pricing, intuitive backend portal, and its ability to handle everything (e.g. cloud computing, push services, user authentication, etc.) with very little configuration or setup. From big-name brands to indie shops, Parse was the obvious choice to accelerate production of MVPs, small to medium scale applications, or specific features of large scale applications. SaaS systems are often ideal for prototyping and personal projects, but for large, custom applications that company environment depends on, building own server stack is worth the extra time and effort. Parse isn’t the only player in the SaaS (Software as a Service) industry. Amazon, Google and Microsoft (and numerous other startups) now offer very similar tools for developers. The idea behind using a service like Parse, however, has always been that developers could avoid dealing with servers, so it remains to be seen how many of its current users will make this switch. 




 



Monday, January 18, 2016

Commercially available things !

There are many standards and proprietary solutions used for connecting things to each other or to the cloud: Wi-Fi, Bluetooth, ZigBee, Active RFID, loWPAN, EtherCAT, NFC, RFID to name a few. Among these technologies, Wi-Fi has been the most successful. It has become a ubiquitous standard of connectivity and is used in the home, enterprise, schools, hospitals, airports etc. 

In this post, we will see some existing commercial things that we can use right now. These include 
  • Smart home devices,  
  • Medical devices, 
  • Wearables, and 
  • All kinds of gadgets.  
All of these devices connect to your Android phone using either WiFi or Bluetooth, pacifically Bluetooth low energy (BLE), sometimes know as Bluetooth smart.
 
One of the most well-known internet of things (IoT) is the Phillips Hue Lighting System. talk to both Android Phone and Android wear watch.
 
Let's go take a look at some existing devices. Kaptur band this is a simple wrist band, that essentially consist of a microphone sensor, some memory, and a Bluetooth radio. It sits and records in a loop, 60 seconds, and whenever you tap it, it captures that 60 seconds, and sends it to your device.  
Another well-known device is the Nest thermostat, which as I believe everybody know, is also owned by Google. They also make a smoke detector, both of which connect up via WiFi, and talk to your Android phone.  

One of the most well-known companies in the home automation market is a company called SmartThings. They make a number of devices that allow you to connect up to your phone. They build locks, sensors, so you can tell when doors are opened or closed, cameras, speakers, and so forth.
 
Talking about the internet of things would be completely empty if we didn't talk about Android wear. The two most prominent devices right now for Android wear are the Moto 360 and the LG G watch.  There's also the Pebble watch. It's not a specific product that's just for Android, but it does have a very nice SDK, and it actually has some physical buttons on it, so you can build apps that do a variety of things with the user punching the buttons on the device. Then, using your Android phone to either control your phone or to use your phone then via WiFi to control other devices.
 
Lumo Lift is a small device to track your activity and calories burned, as well as improve your posture. It is essentially an accelerometer, and you can see here it goes on the shirt/bra by holding it with a magnet. Essentially, you just sit up straight, double-tap it, and then if you ever start to slump, it'll buzz, vibrate and remind you to sit up straight again.  

In terms of wearables and fineness, one of the most popular's called Fitbit. Fitbit, essentially, will tell you how many steps you've taken, route your map, and do all of that while you just wear it around everyday, and it'll help you manage your weight, eat better, sleep better, and so forth.
 
One of the early entries in the internet of things was a company called Withings. They make everything from activity tracker to a bathroom scales, to this fashionable Activite steel white watch and activity tracker. They also make a pulse oximeter, so that you can tell how much oxygen is in your blood while you're exercising, and even a home camera.  

The internet of things goes everywhere, including into your peaceful moments. The muse, the brain sensing headband monitors your brain waves, and allows you to determine when you brain is actually calm. There's also an SDK that you can use to experiment with using your brain waves to control other things.  

TI Sensor Tag. The reason it's great is because it's $25, and it contains all of these things, temperature sensor, humidity sensor, pressure sensor, accelerometer, gyroscope, and magnetometer. That works on one CR2032 battery, and it's very, very easy to talk to it with Bluetooth. And also you can do your Android phone or Android tablet to talk to a Bluetooth device. This is a easy way to get started, so that you can understand how to build a Bluetooth app. 

Then, there's this great product that's a internet of things developer kit called WunderBar. It's from Germany from a company called Relayer.  We'll talk to the Relayer master module via WiFi, and it will talk to the different individual modules via Bluetooth.

Then, we're going to go even further, and build a simple intelligent device that you can mount at your door, so that when somebody rings the doorbell, you can pick up your phone and snap a picture of who's there, so you can see who's at the door. For that, we're going to use the Tessel platform. Tessel's very interesting. It's a microcontroller that runs JavaScript. It uses no JS, has WiFi, it's got four connectors. Tessel's very unique in it, all of the components are only on one side. You can always tell when you've got things plugged in correctly with the Tessel, because it can only go in one direction. With components on one side, if you flip it over, all you see are the backs of all the boards. You can plug pretty much any component into any one of those things, and you can power the Tessel with via USB or with a battery. It's very, very easy to program using JavaScript.

Lot more are available or existing which can be used as a solution in demanding market.



Where to find new Internet of Things (IoT) Devices ?

Hey folks,

If you are a crazy and passionate gigs for exploring Internet of Things (IoT) technology invention and gadget availability around. Also very fond to know about latest news, articles, pricing and purpose for various available sensors and IoT based gadgets details.

 I recommend to checkout below links, will help on making decision and pursuing further:
  1. http://iotlist.co/
  2. http://www.iotnewsnetwork.com/
  3. https://www.kickstarter.com/
  4. https://www.indiegogo.com/
Thank You!

Tuesday, January 5, 2016

Custom ROM: CM and MIUI - High Level Overview.

Hello Readers,

Cheers and best wishes for 2016 :-)

With this post you'll grasp better knowledge and understanding about CyanogenMod (CM) and MIUI
(which stands for Mi User Interface and pronounced "Me You I", a play on the common abbreviation of the words user interface as UI). 

Lets discuss first, what exactly the purpose to know about them?

There are list of custom ROM available in market as an open source. CM and MIUI are most popular which can be used on almost any phone brand and has support for custom ROMs. Both are an open source operating system for smartphones and tablet computers, based on the Android mobile platform. Developed as free and open source software based on the official releases of Android by Google, with added original and third-party code. Both can be used as firmware for smartphones and tablet computers based on the free software Android OS. It is similar to installing any OS on a PC.

If you love to play with technology and interested to buy a new Android based phone or flashing an existing phone with one of these ROMs or UIs theme, this article will help you to make decision and also to pick one among these two MIUI and CM.

Here is a short background comparison of the two:
  • MIUI, developed by Xiaomi Tech whereas CM is developed by CyanogenMod Open-Source Community as free and open source software based on the official releases of Android by Google, with added original and third-party code. It is based on a rolling release development model and quite similar to stock Android.
  • The source model of MIUI is an open source with closed source component  whereas CM is an open source. 
  • Both ROMs have version history with the date of their launching and criticism/controversies involved time-to-time , the recent version of MIUI is MIUI v7 and CM is CM v13.  
  • Interesting to know that the original MIUI ROMs were based on Android 2.2.x Froyo and CM v6 sources. Xiaomi added a number of apps to enhance the basic framework; those include Notes, Backup, Music, and Gallery. Other than supporting own brand Xiaomi also offers MIUI to be flashed on other smartphone brands such as Samsung, Sony, HTC, LG, One Plus and Nexus. On the other side, Cyanogen OS 12, a variant of CM v12 for the OnePlus One and Yu Yureka was released in April 2015. Yu Yuphoria got Cyanogen OS 12 out-of-the-box when it was launched in May 2015. Cyanogen commercially develops operating systems pre-installed on some devices (OnePlus One, YU Yureka, YU Yuphoria, Andromax Q, Lenovo ZUK Z1, Wileyfox Swift, Wileyfox Storm) based upon the CM source code.
  • MIUI do have regional restriction on package manager side. It doesn't ship Google Play Services in Mainland China. Global versions of MIUI are been certified by Google. Also during the development of MIUI v4, Xiaomi started to remove Google services from their ROMs in order to build and monopolize its own environment of Xiaomi, including cloud services, paid themes and games (featuring MiCredit currency). Later, during development of MIUI v5, nearly all Google services had been removed from the Chinese versions.
On performance perspective,  
  • Features supported by CM include native theming support, FLAC audio codec support, a large Access Point Name list, an OpenVPN client, an enhanced reboot menu, support for Wi-Fi, Bluetooth, and USB tethering, CPU overclocking and other performance enhancements, soft buttons and other "tablet tweaks", toggles in the notification pull-down (such as wi-fi, Bluetooth and GPS), app permissions management, as well as other interface enhancements. CM does not contain spyware or bloatware. In many cases, CM may increase performance and reliability compared with official firmware releases.
  • MIUI, the interface is similar to and competes with iOS's UI and Samsung's TouchWiz UI. MIUI has really taken the android community apart by the really amazing features that the ROM is providing to its end users. It features a heavily-modified user interface that does away with the Android app drawer and has drawn comparisons with Apple’s iOS.  IT features additional functionality that is not found in the stock Android applications which include toggles on the notification pull down, new music, gallery, and camera apps, and an altered phone dialer that displays matching contacts as a user enters a number. The modified operating system has been criticized to be similar to the Apple’s iOS but that does not really matter for the end users as long as they are enjoying using it. 
 
 
Source: http://en.miui.com/data/attachment/forum/201410/05/202651rxdbgqd8b8dlqza2.jpg.thumb.jpg

Experts take on as conclusion: pick MIUI for user-friendly features and intuitiveness; go for CM if you want to control every aspect or built-in features of your phone and want more controls with high stability; and go for stock Android for performance, stability and simplicity. Also you can find experienced user view over here


Wednesday, July 2, 2014

Mobilizing .aspx web based desktop app on BlackBerry10 platform over BES10




This blog gives a quick sense to understand the approach of problem statement i.e., mobilizing .aspx web based desktop application on BlackBerry10 and other major platforms significantly. To achieve the result, please verify the system requirements and make sure all setup should be done early before moving ahead.
For .aspx web based app: Visual Studio IDE is needed on your development machine. For creating the fresh project or existing project execution, Please follow following steps:
On Visual Studio IDE- > click on File Menu-> New Project -> Pick the recent template as ‘Visual C#’ and select ‘ASP.NET Web Application’ for executing the project. See below image for ref (Fig1)

                                    Fig1. Running ASP.NET web app on Visual Studio IDE
Click on the ‘Release’ button. App will run and display on default browser with picked port number, like this http://127.0.0.1:48667/Web.UI/EmpLogin.aspx 

Fig2. Running Web Application on Desktop Browser with Port value
Write click on the Solution Explorer -> Publish Website
Fig3. Actual path of the Application

Copy the path C:\PFC\Sample App\PrecompiledWeb\Web.UI

Active the IIS Sever on Desktop platform first. Then go to
Windows -> Start - > ctrl + R -> inetmgr

IIS Manger window will open, then click on Sites - > Default Web Site - > Right-Click and choose ‘Add Application’ option
Provide the application ‘Alias name’ and actual path i.e., same target location which received from Publish Web Site on Visual Studio IDE.
Right-Click on the application Alias -> Manage Application -> Browse

The app will open on the default browser, without port-number, i.e., http://127.0.0.1/PFC/ 

Fig4. Running Web Application on Desktop Browser without Port value
 
In next step, as we know BlackBerry Enterprise Service (BES 10) environment is setup on the dev environment.Target platform device has to be enabled with the BES services, such as, currently supports available for BlackBerry 10, iOS and Android.
Open the Workspace (BlackBerry 10)/Secure Workspace browser (iOS and Android), type the URL with the IP address and alias name, i.e., http://127.0.0.1/PFC/ (have been created above as and application alias) . 
App will start showing on the device workspace browser:
Fig5. Running Desktop Web Application on BlackBerry 10 Secure Browser

For launching the same output as an application, there are following ways:
1.     Hybrid approach – create a native app and call the application URL on web associated API in that.
2.     Web app – simply call the URL at respective web view API. That’s it.  

After creation of the app, it has to be pushed on Workspace (BlackBerry 10)/Secure workspace (iOS and Android). 
If the app doesn’t have a target to implement specific features such as (push notification, other api, so on) on respective app on specific platform, then above solution would be the right approach to pick or go forward.
To get to know more about BES 10, please follow: BES

*****END*****