![]() |
Forum Index : Microcontroller and PC projects : 4 $ WiFi Serial Transceiver Module
![]() ![]() ![]() ![]() |
|||||
Author | Message | ||||
Oldbitcollector![]() Senior Member ![]() Joined: 16/05/2014 Location: United StatesPosts: 172 |
I'll see if I can work up a more "complex" form of the Micromite webserver over the next day or two. I can't see any reason why we couldn't control some LEDs with this.. ... and everyone knows that if you can control LEDs, you can control ANYTHING.. MUHAHA! (eh.. ahem..) Jeff My Propeller/Micromite mini-computer project. |
||||
Oldbitcollector![]() Senior Member ![]() Joined: 16/05/2014 Location: United StatesPosts: 172 |
I'll leave it running live over dinner.. Here's the server : http://76.5.115.151 Those of you lucky enough to get connection 0 will get an answer. :) My Propeller/Micromite mini-computer project. |
||||
viscomjim Guru ![]() Joined: 08/01/2014 Location: United StatesPosts: 925 |
This is getting good real quick like!!!! |
||||
Oldbitcollector![]() Senior Member ![]() Joined: 16/05/2014 Location: United StatesPosts: 172 |
It just occurred to me.. I've just created a <> $10 webserver. :) I've actually got a real use of temperature monitoring of a reptile room over the winter. My Propeller/Micromite mini-computer project. |
||||
WhiteWizzard Guru ![]() Joined: 05/04/2013 Location: United KingdomPosts: 2944 |
So what power do these things need? Is it a continuous requirement, or, just when RF is 'chatting'? Hope your 5v reg hasn't melted yet! WW |
||||
Oldbitcollector![]() Senior Member ![]() Joined: 16/05/2014 Location: United StatesPosts: 172 |
Actually, I switched from DC 12v-1amp to DC 7.5v-1amp tonight, and it's been running all evening with the 5 regulator just slightly warm, not burning hot like the night before. The datasheet says these regulators are rated for anything up to 35v, but I don't really like things that I can't keep my fingers on. I probably should have put a counter on this tonight, as I think I'm around 30 requests since I posted it. (I've been watching the MMC display requests for the last couple of hours) My Propeller/Micromite mini-computer project. |
||||
bigmik![]() Guru ![]() Joined: 20/06/2011 Location: AustraliaPosts: 2950 |
Hi Jeff, It will be OK up to 35V input BUT if it is supplying a board that requires 100ma @ 5V then you would be expecting the regulator to sink the rest ie. (35-5) or 30V @ 100ma which is a whopping 3W even at 1W you would need a heatsink to keep it `sane' and the TO-220 devices are generally 1W maximum.. It is usually better to keep the input voltage as low as possible while staying above its forward drop limit.. (usually 2V or there abouts) so feeding with 7.5-8V would be your optimum supply voltage. Regards, Mick Mick's uMite Stuff can be found >>> HERE (Kindly hosted by Dontronics) <<< |
||||
TassyJim![]() Guru ![]() Joined: 07/08/2011 Location: AustraliaPosts: 6283 |
About 60mA when idle and up to ~250 mA when 'chatting' There are some low power standby modes but that would not be much use for a 'server' Jim VK7JH MMedit |
||||
Oldbitcollector![]() Senior Member ![]() Joined: 16/05/2014 Location: United StatesPosts: 172 |
@Thanks for the data to chew on Jim... Here's a somewhat more intelligent MMBASIC webserver which can change pages depending on which checkbox is selected. [code] Open "Com1:115200" As #1 Print #1,"AT+CIPMUX=1" Pause 1000 Print #1,"AT+CIPSERVER=1,80" servepage=0 webserver: Line Input #1,c$ Print c$ If Mid$(c$,12,6) = "GET / " Then servepage=1 If Mid$(c$,12,17) = "GET /?toggle=LED1" Then servepage=2 If Mid$(c$,12,17) = "GET /?toggle=LED2" Then servepage=3 If Left$(c$,2) = "OK" Then GoSub serve c$="" GoTo webserver serve: If servepage=1 Then http "<TITLE>MICROMITE WEBSERVER</TITLE>" http "<H3>Welcome to my Micromite Companion Webserver!</H3><BR><BR>" http "The time is: "+Time$+"<BR>" http "<BR><BR>Select One<BR>" http "<FORM>" http "<BR><INPUT TYPE=checkbox name=toggle VALUE=LED1>Led #1" http "<BR><INPUT TYPE=checkbox name=toggle VALUE=LED2>Led #2" http "<BR><BR><INPUT TYPE=submit value=Submit>" http "</FORM>" servepage=0 EndIf If servepage=2 Then http "<TITLE>MICROMITE WEBSERVER PAGE 2</TITLE>" http "You might have toggled Led #1" http "<BR><BR>" http "<A HREF=http://192.168.1.20>Go Back</a>" servepage=0 EndIf If servepage=3 Then http "<TITLE>MICROMITE WEBSERVER PAGE 3</TITLE>" http "You might have toggled Led #2" http "<BR><BR>" http "<A HREF=http://192.168.1.20>Go Back</a>" servepage=0 EndIf Pause 500 Print #1,"AT+CIPCLOSE=0" Return Sub http output$ Print #1,"AT+CIPSEND=0,"+Str$(Len(output$)+2) Pause 50 Print #1,output$; Print #1,Chr$(13)+Chr$(10); Pause 50 End Sub [/code] My Propeller/Micromite mini-computer project. |
||||
Oldbitcollector![]() Senior Member ![]() Joined: 16/05/2014 Location: United StatesPosts: 172 |
Here's a little Instructable to help folks get up and running, including a little primer on basic networking and connecting to the outside world. http://www.instructables.com/id/Using-the-ESP8266-module/ My Propeller/Micromite mini-computer project. |
||||
viscomjim Guru ![]() Joined: 08/01/2014 Location: United StatesPosts: 925 |
Very Freakin' Cool. uMite on the Iot bandwagon!!!! yeah! |
||||
Oldbitcollector![]() Senior Member ![]() Joined: 16/05/2014 Location: United StatesPosts: 172 |
How about an simple IRC client and bot written in MMBASIC? :) [code] ' MCIRC V1.0 - By Jeff Ledger ' http://www.propellerpowered.com ' Uses the ESP8266 module. ' This program assumes you have already programmed the wireless ' ESP8266 unit for your network and have it connected. IRCSERVER$="irc.newnet.net" IRCPORT$="6667" IRCNICK$="MCompanion" 'Irc Nick IRCNAME$="Joe User" 'Irc Realname CHANNEL$="#PROPELLERPOWERED" 'Irc Channel Open "Com1:115200" As #1 Randomize Timer Print "*** PLEASE WAIT WHILE WE LOG INTO "+CHANNEL$+" ***" Print " " Print "Connecting...." Print " " Print #1,"AT+CIPSTART="+Chr$(34)+"TCP"+Chr$(34); Print #1,","+Chr$(34)+IRCSERVER$+Chr$(34)+","+IRCPORT$ pong=0 login=0 IRC: a$="" b$="" a$=Inkey$ If a$="`" Then a$="" Line Input ":] ";d$ output "privmsg "+CHANNEL$+" : "+d$ EndIf If a$="-" Then a$="" output "quit" EndIf If a$ <> "" Then Print #1,a$; If Loc(#1) >=1 Then b$=Input$(1,#1) char = Asc(b$) If char >31 Then c$=c$+b$ If char =13 Then If Right$(c$,1)="~" Then output "nick "+IRCNICK$ If Mid$(c$,9,4)="PING" Then output "PONG :"+Mid$(c$,15,Len(c$)) pong=1 EndIf If pong=1 And login=0 Then Pause 1000 output "user "+IRCNICK$+" localhost localhost:"+IRCNAME$ Pause 1000 output "join "+CHANNEL$ login=1 Pause 1000 CLS Print "*** LOGGED INTO CHANNEL: "+CHANNEL$+" ***" Print " " Print "(`) to start typing a message, enter to send." Print "(-) to logout of the IRC connection." Print " " Print "Channel Commands: " Print " " Print "!time = Display current time on the Micromite" Print "!date = Display current date on the Micromite" Print "!random = Display a random number from 1-100" Print "!magic8ball = Consult the magic8ball." Print " " EndIf If Right$(c$,5)="!time" Then output "privmsg "+CHANNEL$+" : "+Time$ EndIf If Right$(c$,5)="!date" Then output "privmsg "+CHANNEL$+" : "+Date$ EndIf If Right$(c$,7)="!random" Then output "privmsg "+CHANNEL$+" : Random Number is "+Str$(Int(100*Rnd)) EndIf If Right$(c$,11)="!magic8ball" Then aa=Int(6*Rnd) If aa=0 Then output "privmsg "+CHANNEL$+" : Outlook uncertain" If aa=1 Then output "privmsg "+CHANNEL$+" : It is certain" If aa=2 Then output "privmsg "+CHANNEL$+" : Without a Doubt" If aa=3 Then output "privmsg "+CHANNEL$+" : As I see it, yes" If aa=4 Then output "privmsg "+CHANNEL$+" : Don't count on it" If aa=5 Then output "privmsg "+CHANNEL$+" : My reply is no" If aa=6 Then output "privmsg "+CHANNEL$+" : Concentrate & Ask again" EndIf If Right$(c$,2)="OK" Then c$="" If Right$(c$,4)="busy" Then c$="" If Left$(c$,4)="+IPD" Then Print c$ c$="" EndIf GoTo IRC Sub output out$ Print #1,"AT+CIPSEND=0"+Str$(Len(out$)+2) Pause 200 Print #1,out$ Print #1,Chr$(13)+Chr$(10); Pause 100 End Sub Sub CLS Print Chr$(27)+"[f";:Print Chr$(27)+"[2J"; End Sub [/code] My Propeller/Micromite mini-computer project. |
||||
paceman Guru ![]() Joined: 07/10/2011 Location: AustraliaPosts: 1329 |
Here is a US website devoted to ESP8266 - lots of current discussion. esp8266.com |
||||
viscomjim Guru ![]() Joined: 08/01/2014 Location: United StatesPosts: 925 |
I just got my ESP8266 boards in from ebay, wired one up and tried the somewhat more intelligent MMBASIC webserver that OBC posted in this thread. Once it grabbed on to my network and I found the IP address, all worked perfectly! Can't say I've been this excited since the first uMite beta release. This is great!!! I appreciate the info from OBC's instructable, it really made it easy to get up and running. The basic example of the webserver shows what it takes to get rolling and expanding to do some cool things via WiFi and uMite. Time to learn some HTTP stuff! Next step is IRC client also in this thread. On the PropellerPowered forum, they are using the MMC running this program to chat with fellow MMCers on Saturday night at 9:00pm (I believe this is eastern standard time?) I hope to be there using my little uMite and teraterm. (I hope this doesn't mean I am turning into a true nerd who does this instead of partying on Sat. night... Jeeez.) The IOT fun begins!!!!!! |
||||
mindrobots Newbie ![]() Joined: 21/05/2014 Location: United StatesPosts: 32 |
You mean Saturday night on IRC isn't partying??? |
||||
viscomjim Guru ![]() Joined: 08/01/2014 Location: United StatesPosts: 925 |
I guess, due to my age and other things, this probably is what partying is going to be.... |
||||
Oldbitcollector![]() Senior Member ![]() Joined: 16/05/2014 Location: United StatesPosts: 172 |
Oh yes, this is partying at my age as well. :) I guess I could go all crazy like and untuck my shirt and grab a cooler while I'm on the IRC Saturday night but that's probably as extreme as I get. :) BTW, folks here are more than welcome to join the chat night on Saturdays. We're a small group of friends who have met because of the Propeller, but honestly the discussions have been on a variety of topics, Micromite, Retro Computers, Propellers, other Micro controller boards, and Squirrels.. If you've got a ESP8266, grab the IRC code and rope it to your Micromite. I've put some "IRC bot" ideas in the code which are begging to be changed to your own. The chat takes place on Saturday nights, 9pm EDT. irc.newnet.net #propellerpowered My Propeller/Micromite mini-computer project. |
||||
plasma Guru ![]() Joined: 08/04/2012 Location: GermanyPosts: 437 |
Iam prepared ! It really fun if you see the micromite join the channel ! Neat code . Btw : any ideas to fight against the ident error on Other Server? I have a esp-05 module which works fine but Beware : it becomes really hot if no Antenne connectet ! Maybe it destroy itself without antenna. |
||||
viscomjim Guru ![]() Joined: 08/01/2014 Location: United StatesPosts: 925 |
Hi OBC, I copied and pasted the code for the IRC into my setup. I get the "connecting..." and that is all. I know my esp setup is working as the webserver worked quite well. Is there any direction you can give me? I did not change any of the code and am not sure if there is anything that needs to be changed for my setup, ie. ip address or anything unique like that. I would like to get this going before saturdays nights IRC party, so any info at this point would be great. Thanks again, this is getting fun now... EDIT... I just noticed in the propellerpowered forum the code you have for the MMC IRC uses an IP address of IRCSERVER$="130.240.22.202". Should I try that instead? |
||||
Oldbitcollector![]() Senior Member ![]() Joined: 16/05/2014 Location: United StatesPosts: 172 |
Yes, there appears to be a deal IP in IRC.NEWNET.NET's round robin IP system. Remark the irc.newnet.net line and try the other. I've seen that same "Connection" issue when it tries to the dead ip. Or just stop the program withe - command and F2 to re-run the program until you get a different IP. It should be noted that I'm using VT100 windows to create the two sections of the screen. If you CTRL-BREAK the program, type NORMAL at the prompt to reset the screen settings to full screen. My Propeller/Micromite mini-computer project. |
||||
![]() ![]() ![]() ![]() |
![]() |
![]() |
The Back Shed's forum code is written, and hosted, in Australia. | © JAQ Software 2025 |