BLYNK
HOME       📲 GETTING STARTED       📗 DOCS       ❓HELP CENTER       👉 SKETCH BUILDER

Image gallery url property setting not working


#24

Hi Gunner,

First, I really appreciate your contributions to the Blynk community.

I’m using one and only one Image Gallery widget. I “flip” (infrequently) through the 41 images in order to “animate” a keg level.

I only display one image at a time. I know you’re generous with your time in terms of recreating others problems. If you have nothing better to do, try taking your 20th URL and re-add it 30 or 40 more times. I don’t know if the issue is simply the number of URL’s (you’d think that would be rather easy for Eugene to recreate) or whether the issue is related to the size of images. I’m not sure. I’d love to hear from someone who’s successfully created an Image Gallery widget consisting of, say 100 x 3 MB images.

Again, I appreciate your help, Gunner.

Joe


#25

There’s a very simple solution to this - live up to your username and drink more beer!
That way you only need two images, empty and nearly empty :rofl:

Pete.


#26

Well, I have a file of 208 images for a tachometer gauge I experimented with using a Nextion display. So I loaded up the images in my Local Server’s image folder and made up this fansnazy routine to load them all in…

BLYNK_WRITE(V2) {
  if (param.asInt()) {
    for (int i = 0; i <= 208; i++) {
      gaugeImage= "http://10.10.3.13:8000/";
      gaugeImage+= i;
      gaugeImage+= ".jpg";
      Blynk.setProperty(V0, "url", i + 1, gaugeImage);
      Blynk.virtualWrite(V4, gaugeImage);
      delay (10);
    }
  }
}

I actually confirmed that it does exactly what I want with a Display Widget showing the full URL… but absolutely nothing happens in the Image Widget… So I think the “url” property has issues (I seem to recall another topic about this, but not bothering to search for it right now) :thinking:

So, Plan B… use one command and the whole “urls” method… loaded with 60 images (go ahead and count them :stuck_out_tongue: )…

BLYNK_WRITE(V5) {
  Blynk.setProperty(V0, "urls", "http://10.10.3.13:8000/0.jpg", "http://10.10.3.13:8000/1.jpg", "http://10.10.3.13:8000/2.jpg", "http://10.10.3.13:8000/3.jpg", "http://10.10.3.13:8000/4.jpg", "http://10.10.3.13:8000/5.jpg", "http://10.10.3.13:8000/6.jpg", "http://10.10.3.13:8000/7.jpg", "http://10.10.3.13:8000/8.jpg", "http://10.10.3.13:8000/9.jpg", "http://10.10.3.13:8000/10.jpg", "http://10.10.3.13:8000/11.jpg", "http://10.10.3.13:8000/12.jpg", "http://10.10.3.13:8000/13.jpg", "http://10.10.3.13:8000/14.jpg", "http://10.10.3.13:8000/15.jpg", "http://10.10.3.13:8000/16.jpg", "http://10.10.3.13:8000/17.jpg", "http://10.10.3.13:8000/18.jpg", "http://10.10.3.13:8000/19.jpg", "http://10.10.3.13:8000/20.jpg", "http://10.10.3.13:8000/21.jpg", "http://10.10.3.13:8000/22.jpg", "http://10.10.3.13:8000/23.jpg", "http://10.10.3.13:8000/24.jpg", "http://10.10.3.13:8000/25.jpg", "http://10.10.3.13:8000/26.jpg", "http://10.10.3.13:8000/27.jpg", "http://10.10.3.13:8000/28.jpg", "http://10.10.3.13:8000/29.jpg", "http://10.10.3.13:8000/30.jpg", "http://10.10.3.13:8000/31.jpg", "http://10.10.3.13:8000/32.jpg", "http://10.10.3.13:8000/33.jpg", "http://10.10.3.13:8000/34.jpg", "http://10.10.3.13:8000/35.jpg", "http://10.10.3.13:8000/36.jpg", "http://10.10.3.13:8000/37.jpg", "http://10.10.3.13:8000/38.jpg", "http://10.10.3.13:8000/39.jpg", "http://10.10.3.13:8000/40.jpg", "http://10.10.3.13:8000/41.jpg", "http://10.10.3.13:8000/42.jpg", "http://10.10.3.13:8000/43.jpg", "http://10.10.3.13:8000/44.jpg", "http://10.10.3.13:8000/45.jpg", "http://10.10.3.13:8000/46.jpg", "http://10.10.3.13:8000/47.jpg", "http://10.10.3.13:8000/48.jpg", "http://10.10.3.13:8000/49.jpg", "http://10.10.3.13:8000/50.jpg", "http://10.10.3.13:8000/51.jpg", "http://10.10.3.13:8000/52.jpg", "http://10.10.3.13:8000/53.jpg", "http://10.10.3.13:8000/54.jpg", "http://10.10.3.13:8000/55.jpg", "http://10.10.3.13:8000/56.jpg", "http://10.10.3.13:8000/57.jpg", "http://10.10.3.13:8000/58.jpg", "http://10.10.3.13:8000/59.jpg");
}

This actually worked! But this only allowed up to index 34… So I think that is the limit allowed with a single Image Widget?? Or at least by this method.

And it does scroll through them nicely with a slider and code… but my RPM is governed :wink:

@wickedbeernut So there you go… you can have only 34 bottles of beer on the wall :joy:


Android Open Beta. Version 2.27.2
#27

Small update… the limit is NOT 34… but for some reason the “urls” property command ended there??

I was able to manually and teadiously add in more (so far up to 50 images) one at a time :scream: And no crashes or issues using them.


#28

AH HA!! OK, the “url” method WILL work… IF you already have an image in the indexed spot.

So as frustrating as it is… after fast loading in the apparent limit of 34 (possibly due to an Arduino command length limit :thinking: ) if you copy/paste something (seems to need a valid image, even the same one again and again will work) into the remailing needed indexes, then run a for() routine or whatever method to automatically update your file names, then it WILL repopulate the indexes with the correct images.

@wickedbeernut I hope some of this helps you get where you need to be in your project.


#29

I think the mistake comes from there :
guageImage instead of gaugeImage
:thinking:


#30

Heh… well, as long as I spell it incorrectly everywhere it should work :stuck_out_tongue: But I fixed my post anyhow.

It was actually running through the entire 60 URL’s correctly… but the Widget stopped “listening” after 34


#31

:rofl::rofl:


#32

Actually, that’s the subject of this topic (“Image gallery url property setting not working”) before I hijacked it.

It’s helpful to know the “urls” setProperty works (at least somewhat).

In my first post on this topic, I mentioned Blynk started crashing around index 37 in manually adding URL’s. I don’t know if this is related to the 34 limit or not. I was able to get to 41 (after repeated failed attempts) by first adding the same URL 41 times. I then edited each URL starting with index 41 working backwards. After that, Blynk crashed and I’ve never been able to manually edit the widget since. The 41 URL’s in the Image Gallery work fine. I simply can’t edit them (at least not manually). I tried using the “url” setProperty (which didn’t work), however, I’m not sure I tried the “url” setProperty on an index that was pre-populated.

Hopefully, Eugene can recreate the issue with the information you’ve provided.

Again, I appreciate your efforts. I’ll experiment with all of the work-arounds you’ve discovered.

Joe


#33

Yup… so it is :blush:

If you haven’t seen it yet, I expanded on my tests, and images used :wink: a wee bit here - Tachometer using Image Widget


#34

While there are many improvements to image widget planned, the particular keg example could use way less images without affecting user experience. Simply because image is used as a reference of a general state. Having a number (percentage or actual volume) would improve the experience and will work with <10 images.

I bet, if you user-test it, you will see that users won’t notice 0.5 difference by the image.


#35

@Pavel for more than 10 images I would be expecting the latest blockbuster movie on my phone :slight_smile:


#36

0-100% = 99 bottles (kegs) of beer on the wall, thus the idea number of images for max accuracy and tone deaf singing… Although, yes, after the first kegger, a 10x reduction to 10 total images, or 10% each will hardly be noticed through the beer goggles :nerd_face:


#37

finally, this code don’t work :
Blynk.setProperty(V16,urls,image)
where image is a string that contains all https link


#38

I assume you meant,

Blynk.setProperty(V16, “urls”, image);

But, same here. How’d you get this to work, Gunner?

Joe


#39

Yes ! Blynk.setProperty(V16, “urls”, image); :wink:


#40

And I can’t get,

Blynk.setProperty(V16, “url”, 1, image);

to work regardless of whether I have an image in the indexed spot or not. Gunner’s either got a beta release or he’s had a few too many. No wonder my kegs always show empty.

Joe


#41

I have the last beta release too


#42

Like I said,

Sorry for no updates so far, very busy lately! But will publish an iOS app update later this week (with updated Tabs widget :wink: )


#43

Thank you, Eugene … the implication being Gunner is running Android and Alexis and I are running iOS. That’s why Blynk.setProperty url/urls somewhat works for Gunner.

Any luck recreating iOS app issues related to the number of URL’s? In publishing the iOS app update, how many URL’s would you expect it to support?

Joe