General area when it fits no where else

Moderator: Mmiscool

User avatar
By Electroguard
#52156 @joeman2116, you have no need to justify or explain yourself to forlotto... he likes the sound of his own voice so always has much to say about everything and nothing, including things he openly admits he knows little about such as udp, so I'm sure you already know much more about udp than he does.

@forlotto, I am aware that you always look for a way to get the un-invited last word on other peoples conversations so you can turn the forum into 'The Forlotto Show'. But where do you get the arrogance to belittle joeman2116's plans for a network of different udp nodes (including ac controllers with slaves, PIR sensor nodes, light sensor nodes, voice announcer nodes, etc) by calling it "simplistic". If you think your claim is justified by some brilliant achievements, then show him your evidence... when was the last time you published any useful relevent interactive projects that he might follow?

Technical ability and social skills can be opposite poles apart when it comes to the likes of genius, so excuse me if I'm bursting a bubble here, but I'm afraid I don't consider you a genius even though your social skills appear almost non-existent. By your own admission you have almost no experience of using udp... yet still your ego compells you to declare "Cool thing about this is UDP is not even needed but I almost did not want to say anything because I am learning another angle at it as well as I have not experimented much with UDP at all."
Some advice... analyse your stated reluctance to speak, then isolate the uncontrollable urge to blurt out unnecessary diarrhia, cos if you could learn to control your transmissions it could be key to saying things that others may wish to hear, or not - but this is of course assuming that the opinion of others has any significance for you, and you are not just talking for your own sake (for any newcomers who may feel some of my comments may be rather hard, I can assure you that previous soft hints have been like water running off a ducks back).

Regarding your assurances of V3 being rock solid now that you have pointed out to mmiscool the error of his ways, I suggest you do yourself no favours by unashamedly promoting yourself and your abilities above those of your betters.

And my preferred yardstick of whether something is rock-solid is not just because the verbose forlotto says so, it is whether it has remained update-free for some weeks, which it hasn't.

This is the third or fourth time I've had to respond to your disruptive intrusion with your non-constructive waffle on one of my threads - please don't let it happen again, because although you obviously like to hear yourself, I do not.
User avatar
By joeman2116
#52157 Electroguard,

Thanks for the input. Was getting a bit confused.
1. I know your code works.
2. I would say the best piece of code in the ESPbasic forum.
3. It has been and continues to be an excellent learning tool.
4. It is a real working piece of code... I use it in my house.
Thanks!

Question:

During one of my last posts I submitted some codes for udpwrite to my second node.

If I used the udp debugger and sent All on or All OFF I could see my codes acknowledged and relays turned on and off.

So udp works from the debugger but not from my code???
Any suggestions....

Joe
User avatar
By Electroguard
#52162 Hi Joe,

Firstly, be aware that as well as sending udp msgs from cicciocb's debugger utility, you can also use it to show msgs sent by your nodes, which will allow you to check for correct msg syntax and spelling.

Bearing that in mind to check with, I think you might find that you have not included a space between the upper("Node146") & upper("ON"), so effectively the two words have been concatenated into a single name of "Node146ON" which doesn't exist, and isn't followed by an ON or OFF command.
If that's the culprit, you can either try adding a space after the 146 ", or in from of the " ON, or you could permanetly hard code it into place using upper("Node146") & " " & "ON" (or OFF).
Don't forget you'll need to do similar for both the bruadcast entries (ON and OFF).
User avatar
By forlotto
#52165 There really has not been much that changed and the editor in most cases will tell you what is wrong with your code via error messages.

https://docs.google.com/document/d/1EiY ... YyJon8/pub
This is the documentation above for all 3.x code

Here is message branch:
https://docs.google.com/document/d/1EiY ... 6ep3w7frt5

Here is wget:
https://docs.google.com/document/d/1EiY ... 4g8o5xev7c

If you look at the following code we can equate a few things and get familiar with it.

Code: Select allprint "Server is waiting for requests."
msgbranch [mybranch]
wait
 
[mybranch]
pinno = val(msgget("pin")) 
pinstatus = val(msgget("stat"))
pinaction = msgget("action") 
if pinaction == "po" then gosub [pomypin] 
msgreturn myreturnmsg
wait
 
[pomypin]
io(po,pinno,pinstatus)
myreturnmsg = "Request Recieved"
return
 


Let us imagine for one second that our IP of the ESP we are working with is 192.168.1.1 !

With the following code above if we wanted to turn pin 2 on we can do it really easily.

We log on to any computer on the same network or tablet or phone or whatever and simply open the web browser and request it like so:
http://192.168.1.12/msg?pin=2&stat=1&action=po
To turn it off it would be just changing the stat from a 1 to a 0
http://192.168.1.12/msg?pin=2&stat=0&action=po
If you would prefer to turn on pin 4 instead just change the pin value to 4 like so
http://192.168.1.12/msg?pin=4&stat=1&action=po
And off for pin 4 would be
http://192.168.1.12/msg?pin=4&stat=0&action=po

Now if we wanted we could add multiple actions with if statements which opens the door to a multituide of subs we could execute lets imagine we would want to execute action xxx we would open our browser and request it as follows:
http://192.168.1.12/msg?action=xxx

The main take away here is we can pick out whatever we wish to read from a url simply put using msgget and we can craft it to preform any action...

We can even make a request to another device that has msgbranch enabled on it using wget to run code on our other device.

You see it is not that difficult really msgbranch is a very powerful tool it is a solution that is better than all of these services that are out there to send messages to a device to preform tasks because you can customize its function to whatever your heart desires and it requires no third party to operate!

Enjoy hope this may aid you a little in your journey.

PS I am not no guru of code either about a few months messing around with this stuff honestly but that is the beauty of basic its well.... BASIC. There is so much though that I have yet to even attempt I have a laundry list of things I would like to do long term but right now my goals are realistic poke away at things a little at a time get to know and understand them heck I haven't even touched udp so you have one up on me.


@ electrogaurd

Yes, I carefully consider all opinions even your own. This last one has led me to believe that you may need to seek help for your condition though whatever it is that is the real underlying issue I hope you get down to the bottom of it and learn to forgive yourself or someone else to harbor all of this hate is not healthy for anyone to be honest.

I sincerely wish you the best you are welcome though to share your opinions any time even if I don't like them I suppose at first I was a bit startled and posted something that looked a bit like your post and I figured no its best not to do so maybe I should take it in stride and try to listen to what it is you have to say then I read more and I really don't think anything I say could help make your life better as I am not a professional shrink either.

But I really do appreciate your work and most of what you have to say as well. Maybe some day you will learn not to mistake my joining in on a discussion as something to undermine your authority it is nothing more then sharing in the conversation I'm sorry in your mind that you think that someone with less knowledge in a certain area should not speak at all. But I believe this is unhealthy this is a forum made for discussions for all levels I hope you are aware I do not suffer from much other than your attacks to be honest but they are forgiven and I will continue to do so.

I welcome all of your speech because this is an important freedom and we should never lose sight of what a forum built on discussion is about this very thing. There is an error in your thinking as well what your ideals would bring is zero discussion on this forum because people would live in fear that they would be attacked from people like yourself for saying anything. I will not be one of those people nor will I promote such an agenda. But I will allow you to continue on freely to errr is human I believe. Ego does get the best of all of us at time it is important to reflect on what you say and the society you would like to see as it all starts with you and what you say is a contribution to building that very thing.

You are welcome to any one of my posts and to be rather frank you can even chime in and scrutinize if that is what makes you feel better whatever it is that is going to help you feel better about you. I assure you this is all not about me I personally love discussion you obviously do not when it comes to social skills I believe you mentioned I was lacking them but at the same time you don't want anyone without a genius IQ to talk a bit ironic but again I will consider this maybe it is me who does not have the correct social skills.

To be rather honest I would like to see more discussion from everybody on the basic forums I do not want the same silence as you I like to see feedback I like to see comments I like to see discussion from people of all IQ levels or no matter where they are at a specific time.

You did a great job with driving lessons excellent post.

I just really wish you would chime in and discuss more then I may not feel the need to chime in and help out the best I can this is not done for fame or to make myself look good as you say heck I am just trying to repay a favor that was given to me I've said this many times mmiscool gave me a hand with learning some of this stuff and I'm just kind of passing it along. Trying to build a community based on discussion from anyone who wants to talk basic.

Maybe this is wrong but again I have nothing to prove here electrogaurd if I was trying to build anything in that manner I would likely use my name and a facebook account however this is not the case. I wish you the best in your journey as well sad thing that you really feel this way but I am not going to try to change your mind I've learned a hard lesson years ago I have met a couple of people in my entire life other than you maybe about five out of the countless I have met who share your views I couldn't tell them the error in their ways and I likely am wasting my time typing here as well.

But just think for one moment what type of society are you building when you would like to limit peoples ability to discuss things on an open discussion? How likely is it that someone will post without fear of being attacked by your comments after reading something like this people will be less likely to contribute!
This is what you are bringing to the table with your actions. While you may not like what I have to say I ask that you be an adult and reflect on these things as well.

I would like to see more discussions and more posts answered by yourself I would like to see you put time and energy into doing it more your way really I would this would be great I don't know how much more clear I could be when I say I want to see more discussions. I see posts where there are hundreds of views good posts and some of those posts looking for feedback as well and no one says a word and it is partially due to people like yourself promoting this you should shut up if you don't know type of agenda I just beg to differ and again agree to disagree I suppose but you are welcome to continue on this issue.

But lets clarify a few things once and for all.

No I am not chiming in for any nefarious reason or to be special or have the last comment none of these things really matter to me it is the discussion, the community, the learning, the teaching, and espbasic in general I actually enjoy this go figure a guy wants to discuss something he enjoys how terrible! I know I know.

And I am NOT the all knowing all seeing overlord with a genius IQ sorry just did not turn out that way at least I don't think so never did test myself but I would bet I'm pretty average maybe a bit above I really cannot say for sure.

As far as social skills you define them a bit differently than me the ability to socialize with people of all different IQ's, ideas, amount of talk off topic and on to me those are social skills. Socializing requires acceptance of both things you like and topics that may not be your favorite. The minute you need to start attacking someone for contributing to the conversation you introduce antisocial tendencies. Open up your mind a bit think a little beyond you. I am different I am not you nor do I want to become like you in a social aspect I am more accepting and open and as I said your comments have been dead for a long time I am interested to see what you have to say on every topic really I'd love it if you chimed in more and got the last word it would actually be a boost and a help to the community I'd guess as long as you did not insult people it would be healthy and heck maybe even if you did I really don't care I guess I'd like to see you share more of all of that knowledge you are not no dummy chime in help more folks out obviously not all of my answers are eloborate as they could be I would be grateful if you were to best every one of my comments or share your opinion even if it is defaming me and mine as long as at the end of the day it was something productive!!!