Skip to Content
Product Information
Author's profile photo Tanmoy Roy

How To Debug SAP Fiori Client Apps In Android

Application debugging on android phones form a major part of the application development cycle. SAP Fiori Client Cordova android app can offer an easy way to get into the nuts and bolts of a SAP Fiori application through an android device for the purpose of debugging the code and ensuring it works as expected. The Fiori Client App is based in Android and allows for interaction with all of the basic functions of the handset such as the camera, geo-location, and pretty much anything that the android device offers in terms of functionality to its native applications. For this particular explanation, we’re going to use a standard android device for the handset and a MacBook Pro, with Google Chrome installed on it. Let’s dive right into debugging our SAP Fiori app through our android handset.

Setting up Our Debugging

The first thing we’re going to do is to run the SAP Fiori app we’re intending to debug on the handset and login to the system. Following this, we’re going to connect the handset to our computer. After we establish the connection, we’re going to open Chrome and set up our dev environment by opening DevTools. In the settings tab, we need to ensure that Discover USB Devices is selected. Now we enter the following address into our Chrome browser: chrome://inspect/#devices

This opens up a window showing our connected devices. If no connected devices show up, then we will need to enable the developer mode on our Android handset. To get into developer mode, we navigate to the Settings menu, under About Phone, and tap on the build version a few times (usually it’s about five [5] times, but different proprietary installs may require more taps to enable the developer mode trigger). A notification should appear on the phone acknowledging the switching on of the developer mode on this handset. If we still don’t see the device come up in our browser page, we may need to enable the USB debugging setting on our device. Enabling developer mode allows us to get access to a new settings menu named Developer Settings. in there we can find the toggle to activate USB Debugging. Once we have that activated, the handset should show up in our list of devices connected to our computer through the Chrome inspector.

Getting Down to Business

Now that we have successfully managed to connect our phone to the browser, where you can search a list of direct installment lenders, we can look at the actual debugging of code. The connection allows us to remotely launch the app in Chrome, making it much easier to debug the actual code and see what works and what doesn’t. By using the inspector, we make our lives easier, since Android doesn’t have any native debugging IDE’s that we can use to get access to the code. The system simply runs the APK as is and it’s up to us to figure out what’s causing the problems on the device. Remote debugging forms one of the most essential tools that an app developer targeting Android has. The flexibility of the Chrome browser allowing us to inspect code and correct it makes for an indispensable tool for any app developer.

Fixing Problems on Android Devices

Applications probably won’t run as expected all the time. In fact, sometimes they won’t run as expected at all. The idea behind debugging on an android device is to see if the coding done on a PC would be feasible in a mobile environment. In order to cover the largest amount of devices, testing should be done with a wide range of handsets covering all the most recent releases of the Android OS to ensure compatibility across the board. Constant testing and improvement is the only way to ensure that an application keeps functioning with each new operating system update.

Assigned Tags

      You must be Logged on to comment or reply to a post.
      Author's profile photo Cristiano Marques
      Cristiano Marques

      Hi. My phone appears in the list, but not happens when I run apps in SAP Fiori Client. How to start debugging the app source code? This part is not clear.

      Author's profile photo Arushi Singhal
      Arushi Singhal

      Hi Christiano, After our mobile appears in the list then our device is connected. After this step, we need to open the app to be debugged in our SAP Fiori Client. If you click on Share button in the app, we can get a URL. Open this URL in Google Chrome of your mobile phone. This generates a link on your connected Desktop's Google Chrome. Click on 'Inspect' for that link on Desktop's chrome and a new window with debugger with open.

      Author's profile photo Cristiano Marques
      Cristiano Marques

      Thanks Arushi. I already had discovered it: that I need to open the lauchpad url in a regular browser tab in mobile device. It is the browser screen that is showed and is inspected in desktop, not the sap fiori app screen.

      Author's profile photo Carole Philibien
      Carole Philibien

      Hello Arushi,

      Could you add more screenshot to explain the last part to debug SAP Fiori CLient. I show my device in the Inspect chrome part, but any "inspect" buton available. In th SAP fiori Client App, I can't find a share button. What I need to do?

      Thank's a lot