Search found 27 matches

by JumpZero
Fri May 10, 2019 4:09 pm
Forum: Programs, Libraries and Tools
Topic: I'm searching a modbus library
Replies: 6
Views: 590

Re: I'm searching a modbus library

Hi!
Not sure if this help but a few years ago I used pymodbus on Raspberry pi it was not very difficult and worked well, it's Python not microPython but may help
Also there is this micropython-modbus for ESP32 (never tested) https://github.com/techbase123/micropython-modbus
by JumpZero
Fri May 10, 2019 3:50 pm
Forum: General Discussion and Questions
Topic: Structured prog & global variables
Replies: 8
Views: 521

Re: Structured prog & global variables

Hi! Actually very interesting discussion. @dhylands you are right the proper way to access the module global variable "bar" is: "my_module.bar" this avoids confusion, keeping in mind that the main programme global variable "bar" is another variable. @pythoncoder Yes this is a Python strength: the gu...
by JumpZero
Thu May 09, 2019 9:15 am
Forum: General Discussion and Questions
Topic: Structured prog & global variables
Replies: 8
Views: 521

Re: Structured prog & global variables

Hello, We know that using global variables isn't a good practice. But it's sometimes convenient and Python permits it. However I was recently surprised to find that global variables are global to a module not across all modules. Reading the doc teachs me this is normal behavior. So that's ok when yo...
by JumpZero
Wed May 01, 2019 7:39 am
Forum: ESP32 boards
Topic: ESP32 - ADC - Invalid Pin
Replies: 6
Views: 3077

Re: ESP32 - ADC - Invalid Pin

Hi!
MicroPython for ESP32 only allows ADC1 as mentioned here: On the ESP32 ADC functionality is available on Pins 32-39
Adafruit ESP32 Huzzah exposes ADC2 but also pins 32 & 33 for ADC1https://learn.adafruit.com/adafruit-huz ... er/pinouts It should be possible to use one of these.
by JumpZero
Sun Apr 28, 2019 1:14 pm
Forum: ESP32 boards
Topic: Waveshare e-paper display how to rotate?
Replies: 13
Views: 1779

Re: Waveshare e-paper display how to rotate?

Hi @pythoncoder thank you very much for your support. It works! :-) It took me sometime because I’m not comfortable enough with python class definition ( self and super() are still a bit obscure, but I learn!). I had to change some minor things in this DummyDisplay class and this took me time and tr...
by JumpZero
Fri Apr 26, 2019 2:08 pm
Forum: ESP32 boards
Topic: Waveshare e-paper display how to rotate?
Replies: 13
Views: 1779

Re: Waveshare e-paper display how to rotate?

Hello, @pythoncoder: I’d like to have bigger fonts so I’ve check your micropython-font-to-py repo as you suggested here above. But so far I had no success. I understand as per your documentation that when using the writer as in: wri = Writer(device, font) the device must inherit from framebuf But in...
by JumpZero
Thu Apr 25, 2019 12:48 pm
Forum: ESP32 boards
Topic: Waveshare e-paper display how to rotate?
Replies: 13
Views: 1779

Re: Waveshare e-paper display how to rotate?

Hi! @devnull: You can try this code, it's adapted from my 104x212 to your 200x200, maybe I've done some typo. I cannot test it since I don't have a 200x200 e-paper display. If yours is black only remove all lines with reference to red. It may give you a path to follow even if doesn't work out of the...
by JumpZero
Thu Apr 25, 2019 12:04 pm
Forum: ESP32 boards
Topic: Waveshare e-paper display how to rotate?
Replies: 13
Views: 1779

Re: Waveshare e-paper display how to rotate?

Hello, @pythoncoder: after several tests I cannot have the blit method doing a rotation. Even if the method accepts framebuffer of different formats, the problem seems to be, as you mentionned, the transposition of the coordinates. I tried many different combinations but none give the expected resul...
by JumpZero
Wed Apr 24, 2019 2:30 pm
Forum: ESP32 boards
Topic: Waveshare e-paper display how to rotate?
Replies: 13
Views: 1779

Re: Waveshare e-paper display how to rotate?

Hello I did it! It works :-) The method is a bit like you said @pythoncoder. I declare and use a framebuffer in landscape mode: format MONO_VLSB I write text in it, I can also use other framebuffer methods (line, rectangle, etc..) And when ready move it to another buffer to send to the e-paper. And ...
by JumpZero
Tue Apr 23, 2019 6:21 pm
Forum: ESP32 boards
Topic: Waveshare e-paper display how to rotate?
Replies: 13
Views: 1779

Re: Waveshare e-paper display how to rotate?

Hi Peter, thank you for taking the time to answer. You are right the set_rotate method belongs to EPD class and won't rotate a buffer filled with framebuffer methods. Unfortunately there is no framebuffer rotate method, but there is a framebuffer method to write text, and there is no EPD method to w...