Avatar for fanoush

fanoush

Member since Jul 2018 • Last active Sep 2019
  • 4 conversations
  • 168 comments

Most recent activity

  • in ESP8266
    Avatar for fanoush

    Hard to guess without seeing the code. When in WebIDE you may dump the Graphics object via oled.dump() method (it will show as picture in the IDE) so you can make sure the framebuffer data is OK (and e.g. width is really 64, not more), then if data is OK it is either in flip command sending (too many or too few?) data or can be also in display initialization.

  • in Projects
    Avatar for fanoush

    I was just looking into good bitmap fonts and found that Nordic SDK 15 has GFX and Font support described here and they suggest The Dot Factory generator which is really neat. Runs on Windows but thanks to it it can generate truetype fonts into C soruce code and the quality is very good - typically fonts like Tahoma include hints for (previously patented) bytecode hinting interpreter and that feature is often turned off in freetype builds on linux producing ugly fonts at small sizes.

    There are lot of settings how to generate the font into C source so e.g empty parts are removed while keeping info about each character width/height. Never heard of it before and love it.

  • in General
    Avatar for fanoush

    You want no saved code at all? really? so just replace those three '10' values by '0' but then you don't need e.g. Flash or Storage module. I'd keep at least 2 pages like this

    'address' : ((118 - 2) * 4096), 
    'pages' : 2,
    'flash_available' : 512 - ((31 + 8 + 2 + 2)*4) 
    

    this will give you 32KB more for code.

  • in General
    Avatar for fanoush

    Should be enough to reduce number 10 on three lines (65,67,68) here
    https://github.com/espruino/Espruino/blo­b/master/boards/MDBT42Q.py#L65

  • in ESP8266
    Avatar for fanoush

    No, you need to fix that line I linked so it does not start at zero and end at 127. Then you can draw at zero and that line will take care of moving it where it belongs. The SSD1306 controller works with 128pixel width so smaller displays show just some subset of available memory, typically in the middle, so when sending data the destination column should be e.g. 31, not 0. Then you must also reduce the WIDTH down from 128 to match width of that 31-95 window (=64).

  • in General
    Avatar for fanoush

    Wow, great. So does it make sense to integrate it into WebIDE so you could reuse same connection and develop/debug such web page together with the code? Or maybe even just provide UI for prototyping like asked in this topic? Maybe the testing plugin is something similar?

  • in General
    Avatar for fanoush

    Oh so you already have something similar for the puck.js that would interact with web page and WebIDE could be such web page too?

    Oh what an interesting concept in general. So I could e.g. have page on the web that would easily work as a frontend to my espruino based smart watch so I could e.g. set time or alarms or change watch face from my computer via the page instead of using the phone.

  • in General
    Avatar for fanoush

    Interesting. So you would expect it to work only if WebIDE is connected to the device? This is just for prototyping and debugging? And if you disconnect IDE you don't expect to have any alternative for the input?

    It could work i similar way like the Graphics.dump() so that it could print some specific stuff to output that WebIDE would act upon and present a dialog and then trigger callback with the result via pasting some code into console (like e.g. setTimeout(callback,10)).

    Maybe even some generic way that would call into WebIDE browser runtime so you could really call the real window.prompt() yourself and get the result via some callback.

  • in ESP8266
    Avatar for fanoush

    Everything is shifted over to the left. so to make the text be lined up I have to start it as if it's 30 pixels to the RIGHT.What value could be causing this?

    It is this line https://github.com/bocajs/NodeBotDays/bl­ob/master/Espruino/ssd1306.js#L54 you need to start and end it on right column, e.g. 31,95

  • in General
    Avatar for fanoush

    this pretokenise flag is still effective just for code in RAM,right? Recently there appeared some beta flag "Pretokenise code before upload (BETA)" in web IDE - minification section. I tried it but it doesn't look like it did change anything to code size stored in flash. Is it supposed to work with flash memory? Couldn't espruino pretokenize the file while saving it into storage .bootcde file? if I processed the file on the device and replaced just all occurrences of 'function' or 'this' (which may be the longest and most frequent ones) by correct byte token would it work including the rest of file which is not tokenised?

Actions