Search found 165 matches

by bitninja
Fri Nov 17, 2017 7:07 pm
Forum: Programs, Libraries and Tools
Topic: ws: tiny asynchronous webserver framework without uasyncio
Replies: 23
Views: 18831

Re: ws: tiny asynchronous webserver framework without uasyncio

jacob019 wrote:
Fri Nov 17, 2017 6:21 pm
I would really like to figure out why you are not getting the same results:
1. Are you on the ESP8266?
2. Is the device connected to the network in STA mode?
Yes, I am using a Wemos D1 Mini and I am connecting to my local wifi in STA mode.
by bitninja
Fri Nov 17, 2017 7:01 pm
Forum: Programs, Libraries and Tools
Topic: PicoWeb Shared Processing
Replies: 6
Views: 5208

Re: PicoWeb Shared Processing

When you say
# In the picoweb run() routine
I thought you meant to modify this...

https://github.com/pfalcon/picoweb/blob ... __.py#L266

Sorry for being dense...
by bitninja
Fri Nov 17, 2017 6:12 pm
Forum: Programs, Libraries and Tools
Topic: ws: tiny asynchronous webserver framework without uasyncio
Replies: 23
Views: 18831

Re: ws: tiny asynchronous webserver framework without uasyncio

OK, that fixed it. Well after my testing with Chrome and Edge (I'm on Windows) I still don't see the performance gains between the two, so I'm not sure what to think. I'm using the profiling tool in Chrome and the times are pretty consistent... Here is the capture of ws loading the webrepl.html... w...
by bitninja
Fri Nov 17, 2017 5:35 pm
Forum: Programs, Libraries and Tools
Topic: PicoWeb Shared Processing
Replies: 6
Views: 5208

Re: PicoWeb Shared Processing

Thank you Peter! I'll have to learn to usage of asyncio so I can understand what it is doing, but I get the jist of what I need to do. My only question is, am I pretty much required to make modifications to PicoWeb itself to accomplish this? I'm ok with this... I already have a fork that I keep for ...
by bitninja
Fri Nov 17, 2017 5:26 pm
Forum: Programs, Libraries and Tools
Topic: ws: tiny asynchronous webserver framework without uasyncio
Replies: 23
Views: 18831

Re: ws: tiny asynchronous webserver framework without uasyncio

Thanks for the test code. Unfortunately I could only get it to serve the root level files and none of the ones in sub-directories like the style sheet and the image. Even when I build the routes for those files... import ws import os rootdir = '/wwwroot' ws.routefile('/',rootdir+'/index.html') def a...
by bitninja
Fri Nov 17, 2017 4:46 am
Forum: Programs, Libraries and Tools
Topic: PicoWeb Shared Processing
Replies: 6
Views: 5208

PicoWeb Shared Processing

I am using PicoWeb, and I had a question about simultaneously running a small DNS service, to redirect any web requests to the device itself aka a captive portal. I have a smaller working script that handles DNS and HTTP requests in the same "main" loop, but with PicoWeb I do not know how to get my ...
by bitninja
Fri Nov 17, 2017 4:24 am
Forum: Programs, Libraries and Tools
Topic: ws: tiny asynchronous webserver framework without uasyncio
Replies: 23
Views: 18831

Re: ws: tiny asynchronous webserver framework without uasyncio

I'm going to admit that I am lost by the last two posts... :oops: I'm new to Python in general and not very strong in the http protocol itself. Jacob, can you generate a simple script using ws that would serve the contents of a path that I pass in? That way I could test it for my needs. Here is the ...
by bitninja
Thu Nov 16, 2017 6:04 am
Forum: Programs, Libraries and Tools
Topic: ws: tiny asynchronous webserver framework without uasyncio
Replies: 23
Views: 18831

Re: ws: tiny asynchronous webserver framework without uasyncio

Wow, you really spent some effort to prove your point. :) I guess it depends on your use-case for your server. You are dealing with tiny (scripted) requests and (simple) responses... is that what your end goal will look like? If you are aiming for a more general purpose framework, then I would do mo...
by bitninja
Thu Nov 16, 2017 4:25 am
Forum: Programs, Libraries and Tools
Topic: picoweb - Web micro (well, pico) framework (with webserver, etc.)
Replies: 25
Views: 39595

Re: picoweb - Web micro (well, pico) framework

Thanks for pointing that out. Not very helpful for what I need. But thanks. I am using the sendfile() function and it already uses the standard header... # handle the root URL def index(req, resp): yield from app.sendfile(resp, rootdir + "index.html") # handle all other resource (file) requests def ...
by bitninja
Tue Nov 07, 2017 11:19 pm
Forum: ESP8266 boards
Topic: FTP Server
Replies: 27
Views: 33241

Re: FTP Server

First of all... thanks everyone for all the work... I find it runs very well indeed. I did have one question about using the ftp.py application though. From what I understand it is like a one-shot run of the FTP server and then it quits when the connection is closed. The question I had was, what wou...