Shop OBEX P1 Docs P2 Docs Learn Events
Propeller Web Terminal: Download webpages with your Propeller! [UPDATE] — Parallax Forums

Propeller Web Terminal: Download webpages with your Propeller! [UPDATE]

MicrocontrolledMicrocontrolled Posts: 2,461
edited 2010-06-04 14:21 in Propeller 1
It is working at last! This is the sub-pre-version of my new windows app, the Propeller Web Terminal (v.0.0.1). It is so simple on the Propeller side! This is what your prop needs to send to download a webpage:
serial.str(string(10,"/NET/",10,"www.sitetodownload.com",10))

It's that easy! After that is sent the page is transmitted back to the Propeller after the page has loaded. It is·mixed with code examples from throughout the forum, and is just ment to be a quick fix, so it has·ZERO error·handling and·will crash if you enter the wrong COM port·or press "Cancel". This·will be fixed later, but I wanted to realese it now so that people could try it out.·It can just·be left on once connected and send webpage after webpage out to the prop without bothering·your·computer. Now·after this gets·better, I'll have it do something that will verify that·it is mine. Preferably having my webpage come up in the·terminal screen.
I'll now also be able to extend my VB 2008 tutorial and add a part about receiving over the serial terminal. Thanks to all who helped with code examples!

Micro

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Check out my new website!!

Use the Propeller icon!! Propeller.gif

Follow me on Twitter! Search "Microcontrolled"

Post Edited (Microcontrolled) : 6/3/2010 12:26:18 AM GMT

Comments

  • CoronaKidCoronaKid Posts: 25
    edited 2010-06-02 02:11
    Micro...
    I downloaded the WAV Player code PropPod 008.spin from your website.
    Code gave me error on line 355, expected an instruction or variable.
    +if ina[noparse][[/noparse]Play] == 1 or ina[noparse][[/noparse]Stop] == 1

    Do you have a patch for this?
    CK
    cool.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ________________________________

    Work:www.vhf.ca··Play:www.Costalegre.ca
  • MicrocontrolledMicrocontrolled Posts: 2,461
    edited 2010-06-02 02:17
    Im not at a PC right now, but you are using the old Prop Pod version. I have my entire liberary uploaded there so there will be some code that are not working. I will upload tomorrow if I can get my server connection working and upload my newly improved super simple music player. It will scroll through the files and play all the WAVs on the SD. You can skip through a pause the music using 2 buttons that can be easily configured. I'll get it tomorrow.

    Thanks,
    Micro

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Check out my new website!!

    Use the Propeller icon!! Propeller.gif

    Follow me on Twitter! Search "Microcontrolled"
  • MicrocontrolledMicrocontrolled Posts: 2,461
    edited 2010-06-02 02:20
    Upon looking at the code you gavem remove the plus sign at the beginning and it should work. This PropPod though needs a user created text file that has to be in a certain format. Be aware. Its so unrefined, ugly, and not practical that you should just wait until I upload my new one tomorrow. I'm a better programmer now. smile.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Check out my new website!!

    Use the Propeller icon!! Propeller.gif

    Follow me on Twitter! Search "Microcontrolled"
  • CoronaKidCoronaKid Posts: 25
    edited 2010-06-02 04:18
    Micro,
    Tks for the quick reply.
    Took out the + and the code compiled ok, but guess I need tv or vga monitor to go further.
    I will look·for your new player after you upload it to your site.
    Will the code work without the video?

    I'm also interested in your Web Terminal code.
    I have been trying to boot up my uController ENC28J60 board on the proto usb board, but no luck so far.
    One of my goals is to stream audio from my favorite Mexican radio station.
    Hasta Luego,
    Ck
    cool.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ________________________________

    Work:www.vhf.ca··Play:www.Costalegre.ca
  • MicrocontrolledMicrocontrolled Posts: 2,461
    edited 2010-06-02 10:33
    The reason I made this is because I couldnt get the ENC to work. I have been having problems connecting to my server and have not been able to upgraade my website for a while. When I can I will upgrade my code system and put the Propeller Web Terminal up. If you are interested in streaming internet radio then you should look at Harrisons Thumper. It's the first place winner in this year's Propeller design contest so you will be able to find it on the Parallax site. The code should be useful for what you are tring to do.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Check out my new website!!

    Use the Propeller icon!! Propeller.gif

    Follow me on Twitter! Search "Microcontrolled"
  • Oldbitcollector (Jeff)Oldbitcollector (Jeff) Posts: 8,091
    edited 2010-06-02 13:34
    Some years ago, I toyed with the idea of sending an abbreviated webpage to the Commodore64.
    The concept was to send a type of shorthand HTML which could be hidden inside an HTML comments section <!--
    The concept would work for the Propeller, as like the C64 it's is short on memory, and no GUI for a browser.
    Like your system, I was using a PC to grab, parse, and send the data to the micro.

    You might find some ideas in the old threads I linked to above.

    OBC

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Propeller Feature Projects: PropellerPowered.com
    Visit the: PROPELLERPOWERED SIG forum kindly hosted by Savage Circuits.
  • MicrocontrolledMicrocontrolled Posts: 2,461
    edited 2010-06-02 22:03
    @OBC: Thanks for the link!
    @CoronaKid: I've got the server working and I have uploaded the new version of the WAV player. I think that you will find this one to be better.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Check out my new website!!

    Use the Propeller icon!! Propeller.gif

    Follow me on Twitter! Search "Microcontrolled"
  • MicrocontrolledMicrocontrolled Posts: 2,461
    edited 2010-06-03 00:31
    Minor Update: I have added the "/CON/" and "/TIME/" functions. They go as follows:

    /CON/ returns a "*" to verify that the Propeller is connected to the PC. This will be useful when useing a Propeller connected with a pair of Xbees and the Xbee USB adapter.

    /TIME/ returns the time as gathered from the internet. It is gathered from http://zmdkl.com/?a=0&0=0·and is in decimal format as follows (amounts in bytes):

    Year(2)
    Month(1)
    Day(1)
    Day of Week(1)
    Hour(1)
    Minute(1)
    Second(1)

    I hope this is useful. Thanks for the support.

    Micro

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Check out my new website!!

    Use the Propeller icon!! Propeller.gif

    Follow me on Twitter! Search "Microcontrolled"
  • BluhairBluhair Posts: 7
    edited 2010-06-04 04:25
    Ok Microcontrolled. You lost me on this one.
    Best I can tell is you compiled an application in VB that allows spin to download a web page.

    No Objects or further explanation. Just "Its so simple".
    serial.str(string(10,"/NET/",10,"www.sitetodownload.com",10))

    Could you please give a simple explanation on what it really does and maybe an object.
    That would help me.

    Thank you in advance. Also, hope I didn't miss the post that explained this previously.confused.gif
  • CoronaKidCoronaKid Posts: 25
    edited 2010-06-04 04:26
    Hi Micro,
    Although it's a cool concept, I'm not really·interested in·a windows server app.
    Like I mentioned before, I'd like to stream audio directly to a demo board prop.

    Your code may be just·what I need to use though, if I can find out how to impliment it.
    serial.str(string(10,"/NET/",10,"www.sitetodownload.com",10))

    Here is a typical live web audio:
    http://www.rcinet.ca/radio/index.php?language=en&type=program&media=audio&id=474

    I have talked to Harrison before, and have been expermenting with his code, and need to buy/build a YBOX2.
    Being a prop novice, it's a challenge to keep focused on a single project.· Ha. ha.

    Funny you should mention Xbees, as that's next on my·project list, especially after buying the official Propeller guide.
    This new book has some neat projects, and is a valuable learning tool.

    Just freed up a VGA monitor at work so hope to try your WAV Player tomorrow.
    Hello & Greetings to OBC for his input.
    Later,
    CK
    cool.gif



    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ________________________________

    Work:www.vhf.ca··Play:www.Costalegre.ca
  • MicrocontrolledMicrocontrolled Posts: 2,461
    edited 2010-06-04 14:21
    Here is the demo code I used to download a webpage with the app:
    CON
    
      _clkmode = xtal1 + pll16x
      _xinfreq = 5_000_000
    
    OBJ
    
      tv  :  "tv_text"
      ser :  "FullDuplexSerial"
    
    PUB Start | data, i
    
      tv.start(12)
      ser.start(31,30,0,9600)
      tv.str(string("This is a VB 2008 testing device",13))
      ser.str(string(10,"/NET/",10,"http://microcontrolled.propmodule.com/",10))
      repeat
        tv.out(ser.rx)
      repeat
      
    
    



    @CoronaKid: If you are wanting to stream internet radio, then this is not your best option. I built this because I know little about web codeing and TCP/IP stacks and such. This is meant to simply download webpages. If you are interested in internet radio, check out this: www.parallax.com/Thumper/tabid/848/Default.aspx
    I think that this is what you are looking for. Also the Xbees are awesome for streaming data between 2 Propellers or other serial devices. They act just like a virtual wire.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Check out my new website!!

    Use the Propeller icon!! Propeller.gif

    Follow me on Twitter! Search "Microcontrolled"
Sign In or Register to comment.