Jereme Causing

Blogger | Developer | Pythonista

Blog

Blog
Initial Commit: XtremeLoader

Initial Commit: XtremeLoader

Development

This is a log on my work for an app I am currently developing which I named XtremeLoader. The purpose of this app is to utilize the Quick loading service of LoadXtreme. This is an online service that enable loading to lots of services which can be helpful on some scenarios. What I like from this is it also has access to promotions I don’t even know it exists.

There have been a few existing apps made for this including the official one recently although I am not comfortable using them since it requires me to log in first and I am only interested in using the quick access. So I decided to build my own which I might be also needing for personal use as well.

API

First of all they don’t provide a developer API. Yes I am simply directly accessing their AJAX pages. I find it also safer since it gets their up to date data and is also utilizing SSL which makes data transaction secure. I believe even though they don’t intend to share this kind of data, they will still benefit from this because the transaction still goes to them. I don’t monetize this app anyway.

Target Platforms

I am planning to target Android platforms. But since this is a hybrid app, I am also planning to make this as a single page application for non-android users. But that is for a later development, although I already have started another repository for that.

Framework and Tools

For the core app itself I decided to use jQuery Mobile for a lot of reasons. Well first of all, because it support even older phones or at least those who are using Android 4.0 (Ice Cream Sandwich) or higher. Although when I tested it using Android

I didn’t like using crosswalk though especially for simple app. Crosswalk is an embedded webkit browser that make modern HTML 5 webpages compatible to the mobile phone. The problem with this though is it makes your app a bit bloated (for more than 30MB). Which becomes a bit of a problem since I live in a country with slow internet connection. Also it gets a bit overkill to make large app that isn’t that complex

For development I use grunt, it is a good tool especially lets you automate a lot of things. The tool I use mainly is the HTML build which lets me split the pages into mulitple sections and build them. I also use other grunt tools like concatenate and uglify that would compress the scripts into smaller size. Although I don’t minify them while under development for easier debugging.

Initial Design

So here is the initial design:

Initial Design

After attending a seminar from coins.ph, I realized that I need to work on the design to make it more user friendly as their app does. I’m not that good in design and I often rely on available template when working especially since I’m more of a back-end developer. So what I did as of now is I had to split the long pages into two to make it easier to fill up as well. Also just to avoid scrolling.

It’s in black as of now since I feel comfortable working with dark background but I will eventually change it to white and add a setting where users can change the color as well.

Future Plans

There are a lot of things features I would like to add such as recent transactions, and the other quick access as well but my first goal is to be able to launch the basic functionality. I was able to try online loading on a prototype on my device which is a good first step, I just need to finalize it before launching at Google play store.

Links

You can find the repository here. As of now the instructions are not clear, but if you would like to check it out you can run the build folder on your webserver or use http-server it’s a good tool. Feel free to contribute if you like either from source code or posting an issue. There is also a repository for the cordova project

 

How to Deal With Fake News in Social Media

How to Deal With Fake News in Social Media

blog

These days, due to the popularity of social media apps such as Facebook, people are now able to share thing easily. Here in the Philippines, telecommunication companies are providing free (or if not cheap) Facebook usage which has caused everyone to have access to the website since majority of the users have smartphones. A major problem though is that sometimes users take this for granted and share unreliable information which become viral as well.

Just recently, Facebook CEO and Founder Mark Zuckerberg has announced that they are working on a way to stop fake news. It seems that this would take a good effort in building this since machine learning would also be involved. But we don’t have to wait for this since it might take them some time and all this just needs is human intelligence which we already initially have.

Fake information has been already around the internet even on its early days. Chains mails ranging from the superstitious “spread this to your friends or die” up to some fake scientific or medical  researches to fake news that often spread in discussion boards and emails. Although the email is no longer a main source of communication these days as it is left for business and formal uses instead, sharing these types of information has leveled up to broadcasting them publicly with higher chances of being viewed.

The purpose of this is to make everyone aware from these type of scams and what to do when you encounter a fake news article.

How to Spot Fake News

Here are some ideas to determine a fake news. There are a lot more ways but these are the common things that can be spotted.

Check the Domain. Domain is the main URL of the website. Most of these fake news makers are too lazy to purchase their domain. Either they could not afford or probably they are afraid of being traced. For bloggers, it easy to spot some of these free domains. Especially for websites ending with a ‘.tumblr.com’,‘.blogspot’, or ‘.wordpress.org’. These are websites that offer free creation of blogs. Other of these are altervista.org or weebly. Once good way to know if this is a free hosting website is to access the main domain. Say we have pinoytrending.altervista.org, check the site altervista.org and you will end up on their hosting product page. Real news websites have enough budget to purchase their own domain. Of course not all fake news use free domains but this is probably your the conditions to check.
Another thing to note is that there are times that instead of a domain name, they are using an IP address. Someone probably had the idea to host using their PC or didn’t bother to create the domain.

Faking News

Check if it’s Satire. OK So maybe you might be overreacting to a new article without checking the website itself. A lot of news website are simply trying to be satire by itself and also admits to it’s readers. Either by it’s slogan or sometimes you would have to go deeper to it’s about page or terms and conditions. The point is these are news sites that parody actual news or sometimes create stories that reflect actual events only for the purpose of humor. The sad thing though is some people take these seriously. You can also tell a satire news from the amount of sarcasm it shows on other articles.

Too much ads. I’d also like to classify this as a form of click bait. These makers of fake news website are often too desperate of getting the most out of their audience, even to the point of putting all of the available advertising services they know. From pop-up, to redirections, to over use of infolinks (often appears as link but when you hover on it displays a tiny banner ad), and even provocative banners which just makes the website can be pretty messy and difficult to navigate.
Legit news websites have advertisements but most of them focus on the article and they often rely on sponsors. This just shows that individuals who make fake websites lack the knowledge in proper standards of design and rely on their ad services.

Lets you sign up first. This is also a potential danger which a lot of social media users fall into. Some fake news page claim to contain controversial articles or videos but asks the user to log in first or connect their social media account. Do not attempt to connect your facebook as it gives hackers access to post more fake news links on your account and other pages even without the user knowing . It also gives away your identity to them which they can exploit on other things.

Decent news websites never ask for log in apart from writing to the comment section. Often times if you want to participate to the comment section, you should use a different account which most people do as well. For subscription, your email address is enough and most of the time they will just prompt you to like their fan page to subscribe to their feeds so there is no excuse in connecting your social media account.

Dealing with Fake News

Now that you are able to identify a fake news website apart from a real, this is what you should do to prevent from falling into a victim and prevent others as well.

Be vigilant

Be Vigilant. The internet a vast ocean of information that is often taken for granted. Know your local news websites (or at least 5 of them ) and only get news from these websites. Seriously, like there are a ton of local websites I know to keep track of starting from the official tabloid websites. I only know the top known ones and keep track of their website addresses. A lot of scammers often try to imitate their names so it’s also important to know the real name. Like for example we know cnn.com is a news website but some fake website scammers might publish an article on a website named cnnheadlines.com which might appear convincing to some.

Speak up. It’s very hard to avoid getting someone to fall as a victim to these kind of websites. Probably the best thing you can do is to let them know that the link they are sharing is unreliable. Let them know (in a nice way of course) either privately or leave a comment that the website they are sharing is fake. As of now the best suggestion Facebook can give is talking to the person about the post.

Be Responsible. This is a problem for most users who click the share button without knowing what they are contributing to. Sometimes I even wonder if people are actually reading the article or just interested in the caption supplied at the preview and description. But if this is your case then probably the internet not for you. Though I might understand since most of these users are using free data. Meaning they can’t access other websites apart from Facebook. But this does not mean you will have to rely on information from the link preview out of ignorance. Your opinions are yours to express but be accountable in what you are sharing.

Conclusion

Whether we are aware of the things we share or not, we have to keep in mind that we should be responsible in what we post. Spreading wrong information is similar to gossip and this is very counterproductive. These fake news have always been there since the beginning and are just part of the ugly things we need to cope up with the internet. But it doesn’t mean we should support them either. Let’s make the internet a better place for our fellow netizens.

 

Image Sources:
All photos belong to their respective owners and are under creative commons attribution

 

Developing in Android with Xamarin Tools

Developing in Android with Xamarin Tools

blog

Just recently I have published my first Xamarin app. I have developed apps already before using Java and hybrid code in HTML and JS as well. This is just a simple app that retrieves data from a server that is the list of events from a scrapped data I got from a certain website. This is not for client since this is just a pet project so the purpose of this is to display all of the upcoming events or gig. Here I used the native setup or also known as Xamarin.Android. It would I have be better if I used Xamarin.Forms to be able to publish in Windows and IOS however I only have an Android phone and I don’t have a Mac. But the code is somehow similar since they both use the C# language as well.  So this is just to share my experience and recommendations in developing using these tools.

Just a little detail for those who are unfamiliar with Xamarin. Xamarin is a software company that provides tools for cross platform development using the .NET Framework. Their primary IDE is Xamarin Studio (Formerly MonoDevelop) and this installs also in Linux (although the Mobile development tools are only available in Windows and Mac). Just recently Microsoft acquired Xamarin so now they provide a plugin that would enable using Xamarin tools with Microsoft Visual Studio.

So in the development of the app, I used Microsoft Visual Studio Community Edition along with the Xamarin plugin. What’s great with this is since it is community edition, you can get it for free. Yes as in free root beer! You will just need to register the software online for both Microsoft and Xamarin which will only take for a few setups before starting.

I had a good time with using Xamarin tools, though there are still some unpleasant time but that’s part of programming since this also happens to other platforms. Here are some of the good parts and not-so-good parts.

The Good Parts

The IDE

Yes Visual Studio, despite of being a bit bloated in your compluter memory, work with a powerful award-winning IDE. This has come a long way even when it was a simple IDE of Visual Basic back in the Windows 3.1 era. You can also use Xamarin IDE as well although there are some things it lack such as the lazy property generator with just a few keystrokes.
Microsoft Visual Studio also comes with various development tools such as the NuGet, a package manager similar to npm or gem in other development platforms that enables you to download and manage 3rd party libraries. There is also an integrated version control system which is great since I don’t need to open Git to make commits. It’s like everything is there in the IDE so there is a reason for it to bloat a bit.

C# is Awesome

C# is Awesome
Yes it is (photo taken from Devcon 2016 Xamarin talks)

There are a lot of great things is C# especially in the code. Features like Linked Queries (LINQ) a high level way of searching through a collection using code similar to SQL, and properties, operator overloaded event handling (C# uses the += along with a fat arrow function approach of attaching events which is much simplier compared to Java).

What’s also great about C# is that even though I used Xamarin.android, most of the code such as syntax rules such as event handling can still be applied when developing in Xamarin.IOS or Xamarin.Forms. This minimizes the effort of learning another language just to develop for different platforms.

The Not-so-good Parts

Kind of Buggy

This is something that can be expected from a third party software rather than using tools that Android has provided. There are times when trying to deploy the app to the emulator, the process takes a long time. Which sometimes it never finishes and I have to break the operation. There seems to be a deadlock happening during the process.

I would also experience a build error that would sometimes show for no reason then disappear. And there are times when building I would need to uninstall the deployed app in the emulator then redo the process. But I think this part is also experienced by those who used Java as well.

Declining Support in Xamarin Native

Most of the community is moving to Xamarin.Forms, a much more flexible approach to developing to multiple platforms. Though this is new, and unstable, it is recommended to move there. The main reason I just used Xamarin.android as I’ve mentioned is because I don’t have any other devices to use. But if you will check some of the code is almost the same since both are using C# and Mono runtime. Even the libraries are also applicable.  I think Xamarin.Forms is Microsoft/Xamarin’s answer to React Native, a tool that allows developing native applications in both Android and IOS using the JavaScript language.

The Set up

I think most of the development time I spent for the app was trying to set up the environment. There are times that upon updating the tools, the project won’t work because you will have to do some configurations and update to the Android SDK as well.

Also there seems to be a problem when running the emulator. Whenever I am using other android IDE’s such as Intellij IDE or Android Studio, when you run the application, it automatically detects if there is already a running emulator and you can configure where to deploy the app. In Visual Studio, there is a simple configuration for selecting the emulator. However, let’s say I have a Nexus emulator running I have just executed using the Android Virtual Device manager, then I ran the project, Visual Studio will spawn another instance of the emulator even though I have selected the target. There are also times when even the emulator was launched by VS, then you terminate the deployment halfway, the next time you run the app, it will also spawn another emulator. I think the IDE needs to establish some sort of handshake with the emulator. Not much of a bug but can be a hassle sometimes.

Just a minor thing but building your app adds an additional 6MB bloat especially if you are just developing a simple app (normally it would take you about 1MB if you use Java). This is not that big if you have fast internet connection unless you target places with slow (and expensive) internet connection

Conclusion

So then I decided not to use Xamarin for my next project or perhaps for the moment. This is just a personal choice though since I would like to use Java instead. I would still recommend it for those who would like to develop their mobile apps and have solid knowledge in C#. Despite of having some problems in development, Visual studio with Xamarin tools is still a great in developing mobile applications and support is always there with the community so I might recommend using Xamarin.Forms as well if you happen to start using Xamarin.

Bandlab: Online music collaboration

Bandlab: Online music collaboration

blog

Got a record you like to improve a music you recorded with someone you know? Or maybe you’d just like to share it hoping someone somewhere in the world might improve your record. Or perhaps you just like to share your music for publicity and have a band page. Then you might want to give Bandlab a try.

Bandlab is a web and mobile application that let’s you collaborate with music creation. Here you can upload a recorded music, either a recorded instrument, or a voice record of you singing, or both and you need to add extra instruments without having to record together. This application comes with a multitrack editor for both mobile and web application.

Multitrack Editor
Multitrack Editor

In Bandlab, you can create a project, upload your audio then publish them either publicly or privately. If you have a band, you can invite them to collaborate with your project. what is great about this is they have a versioning system where you can track the changes made on your project and also revert back to them.

Revision History
Revision History

I mentioned in a previous article the importance of version control and it seems that the developers of Bandlab found a way to apply this concept of software development to music production.

Bandlab also comes with a feature of forking a project. Forking is a method used in version control. This technique is used in software development especially in open source. According to bandlab, “Creating a “Fork” makes a personal copy of someone else’s song – allowing you to develop it further yourself or to move it to a band and work on it with your other regular collaborators.” If you would like to edit an existing project, you can simply fork it. By doing this, a copy of the project will be created in your account. You will also get a copy of the history of changes done. This feature though is only available if the project is set to allow forking. You can turn it of if you don’t wish your music to be edited.

Probably the difference of collaboration in Bandlab with that used in software development is the ability to create branches and pull requests. But that part is a more advanced and very complicated to do in case. Personally I can consider this a flat form of version control. You work on a single branch, although all your edits with the band are still logged. When someone forks your project it is also recorded as those who are inspired from your work. You also get credited on the fork they did as the source of their music they enhanced is also included.

 Recorder in mobile application

So that’s it. You can give Bandlab a try either the web application or the mobile application by checking out on their website. This service is new and still has a lot of room for improvements but the concept they are using is great and we might expect for features to be available in the future.

Flyakeed

Flyakeed

Portfolio
Company: Leandev Inc.
Role: Web Developer
Target Platforms: Web/Mobile Browser
Frameworks and API’s used:Slim Framework, Bootstrap, SammyJS, Socket.io

Flyakeed.com is an online booking system that enables users to plan their flights and also books you to any available schedule based on your preference. It is a single page website and also comes with a mobile version. It also comes with both Android and IOS apps

My role for this project covers both front-end and back-end support. Below are the list of contributions:

  • Real-time loading of flights
  • Real-time back-end socket display
  • Real-time monitoring for administration
  • Payment integration and card verification
  • SMS Notification Integration
  • Front-end design support
  • Back-end API support

For more information you can check out their website:

Flyakeed.com

Get it on Google Play download-on-app-store
MARK

MARK

Portfolio
Company: Journeytech
Role: Lead Developer
Target Platforms: Web Browser
Frameworks and API’s used: Google Maps JS API and Location Services,  JQuery

 

Mobile Assets Real-time Keeper(MARK) is a GPS monitoring system that enables users to track their vehicle.
It integrates technologies such as Google maps to enable tracking of vehicles. Great for tracking business or personal vehicles. Features include(but not limited to) the following:

  • Real-time GPS monitoring
  • User assigned Geofencing
  • GPS reports(Distance Analysis, location, voyage summary)
  • Vehicles Management
  • Sub-client assignment
  • Active-vehicle route tracking with online customer support
  • Automatic Routing
  • Vehicle Immobilization[!]
  • Accessible in Desktop, Android, and IOS platforms

I had a lead role in development and maitenance of this website both front-end and back-end. As for the mobile apps I worked on the Android application and also the web pages used in the IOS app. As they are hybrid in the sense that it combines native code with webviews added for other functionalities.

For more info you can check out the links below:

Visit Website

Get it on Google Play download-on-app-store

 

 

Starting a New Hobby with Arduino and IOT

Starting a New Hobby with Arduino and IOT

Development

I just received the Arduino starter kit I just ordered from Tinkbox, and I’m now excited to learn building things with this. The kit includes an unofficial starter kit, and an Arduino clone which is still compatible to the existing drivers. Well not bad since the original kit and board is expensive. The board is also loaded with a sample blinking light program. Probably added by the owners while testing.

Arduino starter kit
Uno R3 with breadboard running sample blinking led sketch

After a week of waiting, I can finally work on personal projects which I might be using at home as well. Projects like maybe a gas detector (because I’m having suspicions with the gas tank or maybe just paranoia), an irrigation system, or timed water valve switch. Lot’s of possibilities really it’s the Lego™ ordinary building blocks I used to play back then where you can build anything only your imagination is the limit.




 

A few weeks ago, I have attended IOT Summit Philippines, an annual event sponsored by tech companies (such as E-gizmo, Thinklab, etc.), that hosts a development workshop and hackathon for those interested in arduino and internet of things. It was also amazing since I get to work on a gizduino IOT board, a customized Arduino board that includes a LAN port, micro SD slot, and higher flash memory.

iot-board (Large)
The gizDuino IOT-644 by e-gizmo™

A bit pricey compared to the Arduino clone I purchased if you’d ask me but still cheaper rather than expanding your board with Ethernet and micro SD shields.

 

Internet of Things (IOT), at this moment is becoming a new trend in technology. It enables you to connect anything, like a household appliance, or industrial apparatus, or even personal tool and exchange data. Not only you automate things, but you also send them to the cloud and it’s up to you on how you process them.

I believe this is a good hobby and is great for anyone who is interested. Even for kids since it doesn’t require you do use a soldering iron. I’ve been seeing foreign 13-year olds (or thats what they sould like :D) building robots in youtube videos and some instructibles articles. And I believe schools should be teaching things like these since it introduces the exciting world of electronics and programming.

 

The Importance of Distributed Version Control Systems

The Importance of Distributed Version Control Systems

Development

These days, the use of Distributed Version Control Systems (DVCS) has become a standard in most large products. It is an automated to save a lot of tasks, and resources such as disk space.

What is DVCS?

For those who don’t know what distributed version control is, it is an automated way of storing changes on your code while collaborating with other programmers under that shared project. Think of it as creating backup copies of your project on your drive (and probably adding dates on your compressed folders) and merging your latest code with your teammate. Without this, the task would be very tedious and also use a lot of resources especially if you have a very large project.

Even though such system exists, a lot of developers still prefer the old fashioned way of collaboration. Either they are unfamiliar with this kind of workflow or they find it confusing and complicated especially when creating and pushing commits which creates an additional task. Or another reason would probably be the fact that the team is too small to implement this kind of workflow. But even when working alone, it is still recommended to use DVCS especially the fact that you can view your history, and back it up as well on free repository servers such as Github or Bitbucket.

Reasons to Use DVCS

Here are a few common reasons why every programmer or teams should be using distributed version control systems.

 

  1. Backup. file-copiesMost DVCS has this feature called commit. When the developer commits his/her code, it creates a snapshot of the changes made to that project and is stored on the local workstation. Like a time machine, you can view your past revisions, or get some code you have erased in the past. Not only that, you can push your changes on a centralized server like Github, and whenever someone pulls those changes, they too can have a copy of the revisions you did alone with your latest code.
  2. Collaboration and Merging. centralized-collaborationThis is also an important tool especially when working with others. Softwares like Git/Mercurial allow you to merge the changes you have made. In fact, they have a smart way of merging code automatically especially when changes are not made on the same lines. But if the smart merge can’t figure out how to merge it since you’ve edited the same lines which can’t be avoided, a mark is added which can be easilly found that there is a conflict on those files. In fact, there are also free visual tools that make manual merging more easier.
    As I mentioned in #1, all commits are distributed to everyone who pulls the changes (Yes, that’s why it’s called Distributed Version Control). Everyone can see what changes were made by the other developer, you can even check how long was he able to make the change or when was the change made
  3. Branching.branching-concept This is a bit more advanced workflow in collaboration but can also applicable even to those who are working alone. When you don’t want your change to affect what others are doing, like probably you are working on an enhancement and it might interrupt on the work of your teammate or you just want to do some changes to be thrown away later, you can simply use branching. If you’re into sci-fi (like me), branching is somehow like creating alternate timelines. Well basically, you are just making a new path for your revisions which if it turns out right you can merge it to your main branch. In fact everything you work on in either Git or Mercurial is a branch which just happens to be a default branch at start. Merge conflicts even create temporary branches that are merged after they are resolved. Branching is a very powerful feature of DVCS
  4. It’s Free!free Well yeah probably one of the best perks in life come in free. You don’t even need to spend a dime on popular programs like Git or Mercurial. In fact, the creator of Git, Linus Torvalds (the same guy who created Linux), worked on this because the current free closed-source version control system he was using was no longer free. Git and Mercurial will always be free to use as it uses a free and open source license. Although there are also some paid softwares, you’ll do fine with the free ones.
  5. Contributing to Open Source.
    bart_os
    If you would like to contribute to open source projects especially those hosted in Github or Bitbucket, you would need DVCS like Git in order to make pull requests. They have a workflow when it comes to contributing such as forking the project (creating a copy) and you can make a pull request to apply the changes to the original project.

 

Conclusion 

The use of DVCS is a very important practice for developers either working solo or with a team. You can either use Git, Mercurial, or even Bazaar(although I’m not sure if it is still being supported) for your projects if you want to implement this kind of version control.

There are may work flow and strategies on implement this which I haven’t covered but I suggest you check it out first especially before implementing it to your team. Here is a good place to start and find out what is the best work flow that would suit you well.

Here is a list of free resources to start with:

  • Pro Git – Free ebook by written by Scott Chacon and Ben Straub published under Creative Commons Attribution. You can also purchase a hard copy from Amazon.
  • try.github.io – An interactive introduction provided by codeschool for basic commands and concepts in git.
  • hginit.com – A good intruduction for mercurial. Provides illustrations and some basic concepts.
  • Mercurial: The Definitive Guide – Although as far as I know, when you install Mercurial especially on windows, an ebook already included. But you can also purchase a hard copy at Amazon or O’Reilly Medi
JRP

JRP

Portfolio
Company: Journeytech
Role: Lead Developer
Target Platforms: Web Browser
Frameworks and API’s used: Codeigniter, Bootstrap, SQL Server 2012

 

Journeytech Resource Planning (JRP) is an Enterprise Resource Planning based on  the existing the operations of Journeytech Inc. It also includes a CRM, an Inventory manager, a vehicle installation management (for MARK) , and financial reports.

My involvement for this project was focused on leading in development for both design, functionality as well as database structure.

Apparently since this is used internally, links cannot be provided

Olivarez Maps

Olivarez Maps

Portfolio

Main

An android application that enables you to view the interior map of Olivarez college, Paranaque City.

It is a Hybrid mobile application, meaning it is a mixture of android native code and html pages. The original app was in offline mode but eventually moved to the cloud since it causes a massive file size due to the map images.

You can download it on Google play
Get it on Google Play