Take the 2-minute tour ×
Android Enthusiasts Stack Exchange is a question and answer site for enthusiasts and power users of the Android operating system. It's 100% free, no registration required.

Is it possible to write an apk file to a NFC tag for it to be downloaded when a user desires? bWe are trying to create a solution in which our reps in the field can simply turn on NFC in specific locations then download an apk file for our custom app. Normally simply providing a link to the file on our server would be ideal by using URI type of tag however these devices (Android phones) may not have WiFi nor Cellular data connection in order to install the app's apk file via a link embedded to the NFC tag.

The NFC tags would be "installed" by a separate team. While it makes perfect sense to have our reps preloaded with the application, the consideration is to also allow customers to download the apk file for installation on their device if they desire as well. The apk is a 6 - 7 MB file.

share|improve this question
    
As far as I know this hasn't been done before although I imagine it would be theoretically possible. Quite a few questions about the usage scenario though: So the NFC tags would be taken out in the field with the reps? Or they would already be out there? How would the NFC tags be put there? Why not just install the application beforehand? –  Peanut Mar 29 '13 at 2:44
    
It's unlikely you could store the .apk on the tag itself, as it would not fit (see Matthew's answer below). The URL to download it could be stored to trigger the download, but then you still need a data connection (WiFi or mobile) for the download itself. –  Izzy Mar 29 '13 at 10:58
    
@Peanut I edited the original post to give clarification –  SmoothTony Mar 29 '13 at 14:14
    
The 'theoretical' bit of my answer was due to the fact that the size of NFC tags is quite limited currently, if you had a large enough tag then it would work. However it's unlikely that there will be large enough tags brought out because NFC's data transfer rate is so slow any large files would take an unacceptable amount of time to be transferred. –  Peanut Mar 30 '13 at 0:21
add comment

1 Answer 1

Some resources I've found regarding NFC tags seems to indicate this would not be possible:

NFC Chip Types
The highest memory available is only about 7600 bytes. Which is quite a bit more than most apks.

NFC Data Exchange Format
The standardized data format specification that is supported by NFC Devices.

At a basic level, an NDEF record contains two components: (1) the data and (2) a descriptor of that data which is used to contextualize the data. [ . . . ] NDEF supports a fairly limited set of actions. More complex actions can be implemented with customized software running on the touching device.

So the default actions that may be supported by NFC devices are:

  • Url
  • Text
  • Email
  • VCard
  • Phone
  • SMS
  • URI

In order to support a non-standard action, you would have to completely implement that in a separate app. Then to transport your apk, it would have to be within the data limitations of all modern NFC tags.

share|improve this answer
    
The actual important bit of this answer is the size limitation I think, the fact that NDEF doesn't support an app type isn't really an issue. –  Peanut Mar 30 '13 at 0:22
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.