Search found 108 matches

by chrismas9
Sun Oct 13, 2019 10:15 am
Forum: Other Boards
Topic: STM32F103C8T6 Data Acquisition board
Replies: 3
Views: 204

Re: STM32F103C8T6 Data Acquisition board

STM32F103C8T6 only has 64K flash. That's not enough. The smallest working port for STM32 is L073 at 192K. I have managed to get it down to 149K but I gave up trying to get to 128K.
by chrismas9
Sat Oct 12, 2019 4:34 am
Forum: General Discussion and Questions
Topic: Micropython Education - Project proposals, ideas and help requested.
Replies: 11
Views: 277

Re: Micropython Education - Project proposals, ideas and help requested.

One of the big advantages of MicroPython is ease of debugging in the field, especially by field technicians who are not professional programmers. Often a full machine is not available during software development and debugging is done at least partly with LEDs, switches, meters, etc. Then the control...
by chrismas9
Wed Aug 28, 2019 2:31 pm
Forum: General Discussion and Questions
Topic: Using LSI instead of LSE
Replies: 6
Views: 242

Re: Using LSI instead of LSE

From the data sheet: Multispeed internal RC oscillator (MSI), trimmable by software, able to generate 12 frequencies from 100 kHz to 48 MHz. When a 32.768 kHz clock source is available in the system (LSE), the MSI frequency can be automatically trimmed by hardware to reach better than ±0.25% accurac...
by chrismas9
Tue Aug 27, 2019 3:38 pm
Forum: General Discussion and Questions
Topic: Using LSI instead of LSE
Replies: 6
Views: 242

Re: Using LSI instead of LSE

USB needs a 0.25% accurate 48Mhz clock.On the L4 this is normally derived from a PLL multiplier from LSE. LSI is very inaccurate and cannot be used for USB or UART. The MSI is ok for UART at commercial temp, but not for USB. The L4 can derive a clock from USB SOF (1 kHz) but I don't know if MicroPyt...
by chrismas9
Sun Aug 11, 2019 2:45 am
Forum: Other Boards
Topic: Teensy 4.0
Replies: 5
Views: 1031

Re: Teensy 4.0

Rocky Song from NXP has ported MicroPython and OpenMV to the RT1060.

https://github.com/RockySong
by chrismas9
Fri Aug 02, 2019 1:02 am
Forum: Pyboard D-series
Topic: Programming a D-series in Win64
Replies: 7
Views: 477

Re: Programming a D-series in Win64

I had issues with dfuse demo on another recent MCU and have changed to STMcubeprogrammer on Windows. It seems to support the newer MCUs. You have to follow the instructions to completely remove the dfuse USB driver before installing STMcubeprogrammer. It took a few attempts to get the driver to upda...
by chrismas9
Wed Jul 17, 2019 12:20 pm
Forum: Other Boards
Topic: [STM32L471] Port for STM32 without USB connectivity
Replies: 4
Views: 205

Re: [STM32L471] Port for STM32 without USB connectivity

You also need to remove #define MICROPY_HW_ENABLE_USB (1) and define a REPL UART. Use mpconfigboard.h from the NUCLEO_L432KC port as a starting point. I did the L452 port based on the L432. It doesn't have USB enabled (no connector on NUCLEO board) and it compiles error free for L451 by just changin...
by chrismas9
Thu Jun 27, 2019 5:09 am
Forum: MicroPython pyboard
Topic: ADC measure negative voltage??
Replies: 23
Views: 1006

Re: ADC measure negative voltage??

On Pyboard Aref is derived from the main 3V3 regulator. If you want really good absolute accuracy connect a reference to another ADC input and scale your reading with the reference reading. Taking a large number or readings and averaging them will help. 4 readings should give about one more bit, 16 ...
by chrismas9
Wed Jun 26, 2019 12:27 am
Forum: MicroPython pyboard
Topic: ADC measure negative voltage??
Replies: 23
Views: 1006

Re: ADC measure negative voltage??

I think there is a typo in your formula. With 100k resistors you will need a small cap on the ADC input as switched cap ADCs will draw transient current spikes from the inputs. You don't say what MCU you are using but some STM32 ADC pins are completely intolerant of voltages outside supply and GND s...
by chrismas9
Tue Jun 25, 2019 3:10 pm
Forum: MicroPython pyboard
Topic: ADC measure negative voltage??
Replies: 23
Views: 1006

Re: ADC measure negative voltage??

I have used the method suggested by @roberthh. Here's how it works. Say you want to measure down to -12V. Make a 5:1 voltage divider, eg 10k and 40k. Connect 10k between Aref (3V3) and ADC input. Connect 40k from ADC input to negative voltage. When Vin = 0V ADCin = 3.3 - (3.3 + 0)/5 = 2.44V. When Vi...