Search found 15 matches

by scardig
Wed Nov 07, 2018 4:02 pm
Forum: The MicroPython pyboard
Topic: Pyboard and SMBUS
Replies: 1
Views: 63

Pyboard and SMBUS

Hello, I have to use a Pyboard V1.1 to monitor a LTC4015 Battery charger (datasheet here: https://www.analog.com/media/en/technical-documentation/data-sheets/4015fb.pdf ) that can be controlled via Smbus: is the I2C lib of the pyboard suitable for this purpose or do I need to adapt it given the requ...
by scardig
Thu Nov 01, 2018 9:52 am
Forum: The MicroPython pyboard
Topic: Pyboard + WIZ850io
Replies: 0
Views: 58

Pyboard + WIZ850io

Hello, I'm using a Pyboard1.1 + a WIZ850io ethernet module. I installed a pyboard firmware with network module and followed instructions at: http://docs.micropython.org/en/latest/library/network.WIZNET5K.html but with no success, that is: nic = network.WIZNET5K(pyb.SPI(1), pyb.Pin.board.X5, pyb.Pin....
by scardig
Wed May 02, 2018 5:51 pm
Forum: The MicroPython pyboard
Topic: Advices for "mission-critical" applications
Replies: 4
Views: 376

Re: Advices for "mission-critical" applications

I think you need to clarify what you mean by "dangerous situations". If you mean danger to life and limb (fire, electrocution and suchlike) you need much more specialist advice, both technical and legal, than you are likely to receive in this forum. Even if the only risk is of (say) burning out a m...
by scardig
Tue May 01, 2018 2:24 pm
Forum: The MicroPython pyboard
Topic: Advices for "mission-critical" applications
Replies: 4
Views: 376

Advices for "mission-critical" applications

Ok, maybe "mission-critical" is a bit exagerated but I refer to real world applications where a failing control unit may lead to a damage to the system. As an example: if at some point in time my main script will crash it will leave the pyboard in the last state (ie timers go on, outputs will remain...
by scardig
Mon Apr 23, 2018 10:06 am
Forum: The MicroPython pyboard
Topic: Interrupt and ADC
Replies: 3
Views: 352

Re: Interrupt and ADC

It looks OK, but it won't terminate because there's no exit from the while True loop. You might want to look at the ADC.read_timed_multi in the latest firmware which provides a means of reading multiple ADC's in response to a timer tick. This might offer smaller code. Thanx. Two questions: 1. Since...
by scardig
Mon Apr 23, 2018 8:33 am
Forum: The MicroPython pyboard
Topic: Interrupt and ADC
Replies: 3
Views: 352

Interrupt and ADC

Hello, here is a code snippet to achieve the following: 1. Read 10 digital values on X1,X2,X3,X4,X5,X6 at 5 Hz 2. Perform a "calculation" on such values 3. goto 1 Do you find it correct ? import array import utime, time import micropython micropython.alloc_emergency_exception_buf(100) NSAMPLES = 10 ...
by scardig
Mon Feb 05, 2018 4:17 pm
Forum: The MicroPython pyboard
Topic: Pyboard debugging while embedded: powering
Replies: 3
Views: 343

Re: Pyboard debugging while embedded: powering

If you had a USB->UART module like a CP2102 or FTDI, isn't it possible just to connect common GND and RX/TX? Then you can monitor without having to wire through the Micro USB port (and therefore avoid automatically joining V+ to your laptop). You're right but I will "waste" two pins on the pyboard ...
by scardig
Mon Feb 05, 2018 3:34 pm
Forum: The MicroPython pyboard
Topic: Pyboard debugging while embedded: powering
Replies: 3
Views: 343

Pyboard debugging while embedded: powering

Hello, we have to embed a pyboard into a dedicated board that will feed power to the V+,GND pins of the Pyboard. With the Pyboard powered in such way, I may need to hot-connect via USB to see what's going on from my PC via Putty (and eventually update my Python code) then reset and hot-disconnect wh...
by scardig
Fri Jan 26, 2018 10:27 am
Forum: The MicroPython pyboard
Topic: Infrared communications between 2 Pyboard
Replies: 6
Views: 3057

Re: Infrared communications between 2 Pyboard

I think that's right. ok. In the docs I read: "Each channel can be configured to perform pwm, output compare, or input capture. All channels share the same underlying timer, which means that they share the same timer clock." So may I use UART2 on (X3,X4) and, at the same time, generate a PWM at 153...
by scardig
Thu Jan 25, 2018 9:41 am
Forum: The MicroPython pyboard
Topic: Infrared communications between 2 Pyboard
Replies: 6
Views: 3057

Re: Infrared communications between 2 Pyboard

pythoncoder wrote:
Tue Jan 23, 2018 5:16 pm
The Pyboard can do that using one of the onboard timers.
So, for example:

from pyb import Pin, Timer

p = Pin('X1')
tim = Timer(2, freq=153600)
ch = tim.channel(1, Timer.PWM, pin=p)

It results in:

>>> tim.freq()
153846.2

Am I on the right way ?

Thanx

Thanx