Search found 40 matches

by enzo
Tue Apr 06, 2021 11:19 pm
Forum: General Discussion and Questions
Topic: ESP32 as an i2c slave: how to set the address?
Replies: 10
Views: 8206

Re: ESP32 as an i2c slave: how to set the address?

Using slave mode is quite difficult because of the way it is implemented. The slave has to be waiting on a transfer before the master will get a response. This doc describes the issue. What is needed is an asynchronous slave mode. It is possible that threading could be used to achieve this, but the...
by enzo
Sun Apr 04, 2021 1:18 pm
Forum: General Discussion and Questions
Topic: ESP32 as an i2c slave: how to set the address?
Replies: 10
Views: 8206

Re: ESP32 as an i2c slave: how to set the address?

pythoncoder wrote:
Sun Apr 04, 2021 12:16 pm
STM based boards (e.g. Pyboards) are the only targets supporting I2C slave mode.
Thanks, can't understand why but... ok!
Can't you tell me anything about the loboris uPython version which seems offering a full comprehensive I2C implementation? Is it fully compliant with "official" MicroPython?
by enzo
Sun Apr 04, 2021 1:15 pm
Forum: General Discussion and Questions
Topic: ESP32 as an i2c slave: how to set the address?
Replies: 10
Views: 8206

Re: ESP32 as an i2c slave: how to set the address?

doublevee wrote:
Sun Apr 04, 2021 8:47 am
I am not entirely certain about the ESP32 support but assuming it uses the standard machine library, this post could be useful to you:

viewtopic.php?t=5320
Thanks, it's what i was looking for but it's related to a STM board while I've a nodeMCU ESP32.
by enzo
Sun Apr 04, 2021 1:13 pm
Forum: General Discussion and Questions
Topic: ESP32 as an i2c slave: how to set the address?
Replies: 10
Views: 8206

Re: ESP32 as an i2c slave: how to set the address?

oyster wrote:
Sun Apr 04, 2021 4:28 am
i2c.scan() ?
Thanks for your answer but scan() is a method for scanning the I2C bus and listing all active devices.
by enzo
Sat Apr 03, 2021 11:20 pm
Forum: General Discussion and Questions
Topic: ESP32 as an i2c slave: how to set the address?
Replies: 10
Views: 8206

ESP32 as an i2c slave: how to set the address?

Hi, I searched everywhere but I couldn't find a way to set an I2C address to an ESP32 with standard MicroPython to make it callable (slave) from another master device. I could only find this Boris Lovosevic https://github.com/loboris/MicroPython_ESP32_psRAM_LoBo/wiki/i2c MicroPython which implements...
by enzo
Fri Mar 12, 2021 1:28 pm
Forum: General Discussion and Questions
Topic: ESP32 RTC.now() is not in MicroPython v1.14?
Replies: 3
Views: 2938

Re: ESP32 RTC.now() is not in MicroPython v1.14?

jimmo wrote:
Thu Mar 11, 2021 5:53 am
enzo wrote:
Tue Mar 09, 2021 3:17 pm
How can I retrieve the date and time?
I don't know why ESP32 is different, but I think rtc.datetime() is what you want.
Thanks! I didn't try that :-)
by enzo
Tue Mar 09, 2021 3:17 pm
Forum: General Discussion and Questions
Topic: ESP32 RTC.now() is not in MicroPython v1.14?
Replies: 3
Views: 2938

ESP32 RTC.now() is not in MicroPython v1.14?

Hi, I get this error >>> rtc.now() Traceback (most recent call last): File "<stdin>", line 1, in <module> AttributeError: 'RTC' object has no attribute 'now' in MicroPython v1.14 on 2021-02-02 I flashed into my ESP32. Indeed "now" isnìt in the dir of rtc but I can't see any other method to retrieve ...
by enzo
Mon Feb 15, 2021 12:51 am
Forum: General Discussion and Questions
Topic: Asyncio in uPython 1.14 has not "run"???
Replies: 18
Views: 11955

Re: Asyncio in uPython 1.14 has not "run"???

In the forum we often refer to using uasyncio for programming, I think it is a core module that should be available everywhere. Even more than modules like btree, who are (as far as I can tell) are not widely used. Yep, I agree. Might be a good idea to revisit the esp8266 1M board definition to see...
by enzo
Mon Feb 08, 2021 9:43 pm
Forum: General Discussion and Questions
Topic: Asyncio in uPython 1.14 has not "run"???
Replies: 18
Views: 11955

Re: Asyncio in uPython 1.14 has not "run"???

Oh I must have missed the information that you use a 1MB firmware. But interesting that the old uasyncio is part of that firmware, that does indeed make no sense at all. So if you want to use the new uasyncio with the 1MB module, you need to build the firmware yourself. you can take a look at my sc...
by enzo
Sun Feb 07, 2021 11:19 pm
Forum: General Discussion and Questions
Topic: Asyncio in uPython 1.14 has not "run"???
Replies: 18
Views: 11955

Re: Asyncio in uPython 1.14 has not "run"???

Uasyncio needs to be part of the firmware. If you install it from upip, you get the old version. Did you download the firmware for the modules with 2MB or more? Because this one should have uasyncio, the smaller ones don't. I quickly checked the repo and it should have uasyncio. I don't have time a...