Search found 5956 matches

by pythoncoder
Wed Aug 31, 2016 6:39 am
Forum: WiPy and CC3200 boards
Topic: Pre-Compiled files using more memory?
Replies: 11
Views: 13238

Re: Pre-Compiled files using more memory?

@Roberthh Not quite, I'm afraid. The const() statement works as follows. If you write MYCONST = const(5) def foo(): a = MYCONST the compiler will compile a = 5. In other words it will be faster and the code will be smaller because it won't perform a read from the MYCONST global. However the global w...
by pythoncoder
Mon Aug 29, 2016 3:57 pm
Forum: ESP8266 boards
Topic: MQTT and SSL
Replies: 8
Views: 8680

MQTT and SSL

Is anyone using MQTT with SSL? I'd like to try it but am puzzled as to how to go about it. A beginners' guide would be great, perhaps posted in the unofficial MQTT FAQ http://forum.micropython.org/viewtopic.php?f=16&t=2239.
by pythoncoder
Mon Aug 29, 2016 9:59 am
Forum: ESP8266 boards
Topic: Socket behaviour: advice sought
Replies: 6
Views: 5031

More n00b networking questions

On a normal network, TCP packets are guaranteed to be delivered in the order that they're sent, and they will be retried until the receiver acknowledges reception... I'm still trying properly to understand the umqtt.simple library. The socket is instantiated with self.sock = socket.socket() Presuma...
by pythoncoder
Mon Aug 29, 2016 9:09 am
Forum: Other Boards
Topic: My MicroPython PYB Nano board
Replies: 8
Views: 7705

Re: My MicroPython PYB Nano board

Very nice, I like the breadboard friendly form factor.
by pythoncoder
Mon Aug 29, 2016 9:01 am
Forum: ESP8266 boards
Topic: SyntaxError at boot with esp8266-20160809-v1.8.3.bin
Replies: 4
Views: 4541

Re: SyntaxError at boot with esp8266-20160809-v1.8.3.bin

False is indeed bad and indicates that the firmware image is invalid. Does your device have sufficient flash to accommodate it?
by pythoncoder
Mon Aug 29, 2016 8:59 am
Forum: ESP8266 boards
Topic: Memory Error Strikes Back
Replies: 6
Views: 5920

Re: Memory Error Strikes Back

...Embedding the pre-compiled files directly into the image is not actually a solution (for me) as there is always some debugging... For programs of any size on the ESP there isn't much choice. Obviously PC's differ but here the turn-round time for building and deploying is 5 seconds over a minute:...
by pythoncoder
Mon Aug 29, 2016 8:11 am
Forum: WiPy and CC3200 boards
Topic: Wipy no float and math!
Replies: 20
Views: 111646

Re: Wipy no float and math!

OK but some algorithms require floating point. One example is Madgwick sensor fusion used in robotics and drones. Also astronomical calculations such as predicting sun and moon rise and set. Other algorithms can be performed using integers but with limitations: fast fourier transforms being an examp...
by pythoncoder
Sun Aug 28, 2016 9:30 am
Forum: ESP8266 boards
Topic: error on create file
Replies: 8
Views: 7457

Re: error on create file

Re erasing flash. I'm not a Windows user but this should work if you change the port to the correct Windows serial port:

Code: Select all

esptool.py --port /dev/ttyUSB0 erase_flash
Then install the firmware normally. You'll need to set up any WiFi connection details again as erase_flash erases everything.
by pythoncoder
Sat Aug 27, 2016 5:42 am
Forum: General Discussion and Questions
Topic: out of memory
Replies: 17
Views: 12661

Re: out of memory

dhylands wrote:...I think adding a function that just returns a tuple of names would be useful, especially from a debugging context.
Great idea!
by pythoncoder
Fri Aug 26, 2016 4:02 pm
Forum: General Discussion and Questions
Topic: out of memory
Replies: 17
Views: 12661

Re: out of memory

Interesting and unexpected (by me). Yet os.listdir('') lists the contents of the SD card and always seems to yield the same result as os.listdir('/sd').