Any general discussion around the firmware, what is does, how it does it etc.
By 960
#39986
What needs to be edited for W25Q32 or W25Q128?

I cant get it working..

I guess this block needs to be edited, but dont understand it completly

#define FLASHSIZEUSED 1757184 //must be a multiple of sectorsize //1757184 = 6006 bytes of EEPROM
#define BYTESPERSECTOR 14
#define SECTORSIZE 4096
#define INFOBYTESSECTOROFFSET 512
#define FLASH_PAGESIZE 256
#define MAGICNUMBER1 0xC0
#define MAGICNUMBER2 0xFF
#define MAGICNUMBER3 0xEE
#define MAGICNUMBER_OFFSET 4
#define BITS_PER_BYTE 8
Last edited by 960 on Sat Dec 21, 2019 4:39 am, edited 1 time in total.
By fram
#39991
I would strongly suggest to go for automotive grade for the passive components, especially the ceramic capacitors (AEC-Q200).
And prices are not so high compare to industrial grade, and you'll avoid reliability issue in the long term. (Keep in mind ECU is running into a HARSH environment).
By Tjeerd
#41209
960 wrote: Fri Dec 20, 2019 5:59 am What needs to be edited for W25Q32 or W25Q128?

I cant get it working..

I guess this block needs to be edited, but dont understand it completly

#define FLASHSIZEUSED 1757184 //must be a multiple of sectorsize //1757184 = 6006 bytes of EEPROM
#define BYTESPERSECTOR 14
#define SECTORSIZE 4096
#define INFOBYTESSECTOROFFSET 512
#define FLASH_PAGESIZE 256
#define MAGICNUMBER1 0xC0
#define MAGICNUMBER2 0xFF
#define MAGICNUMBER3 0xEE
#define MAGICNUMBER_OFFSET 4
#define BITS_PER_BYTE 8
Need to change in speeduino/src/SPIAsEEPROM/SPIAsEEPROM.cpp line 48
SpiFlashAvialable = winbondSPIFlash.begin(_W25Q16,SPI, pinSPIFlash_CS);
to
SpiFlashAvialable = winbondSPIFlash.begin(_W25Q128,SPI, pinSPIFlash_CS);

If you checkout my github master branch and are using microsoft visual studio code to compile you can change the Chipselect pin number in the platformio.ini file line 7:
-DUSE_SPI_EEPROM=56

Change to whatever pin number your CS is connected
By Ilotalo
#41297
Rene325 wrote: Fri Oct 18, 2019 5:05 pm 1. When using a pre-used board, there is a possibility that the data inside the 25Q16 can upset the software. I have seen one occasion where tunerstudio connects and after 1 sec. looses connection.
I have this problem. I have STM32F407VGT6 and programming goes fine. It find's board from Bluetooth but connection on just 1 sec.
It gives me firmware mismatch and then that Error reading.
Here is specs of that board: https://github.com/mcauser/MCUDEV_DEVEBOX_F407VGT6

Flash memory reading problem?
Attachments
STM32Problem.jpg
STM32Problem.jpg (611.67 KiB) Viewed 25582 times
By NickZ
#41298
because your not using the correct INI? Did you load the INI from the stm32 package?
By Ilotalo
#41300
NickZ wrote: Thu Mar 05, 2020 9:31 am because your not using the correct INI? Did you load the INI from the stm32 package?
I beleave this is for mismatch problem.

Speeduino 202002 firmware and. ini. What should be STM32 firmware revision and ini file?
By iLeeeZi
#41301
Ilotalo wrote: Thu Mar 05, 2020 12:12 pm
NickZ wrote: Thu Mar 05, 2020 9:31 am because your not using the correct INI? Did you load the INI from the stm32 package?
I beleave this is for mismatch problem.

Speeduino 202002 firmware and. ini. What should be STM32 firmware revision and ini file?
Seems like you are connected to the CANSerial and not the one which is used to communicate with tunerstudio. I don't remember what serial the STM32 uses for main communication but switching to correct serial pins should work.
By dazq
#41305
Stm32 uses the usb as its primary serial for TS just as teensy does.
Also in a similar way that usb is native not via a serial to usb interface like the mega2560 does.
To use Bluetooth you will need either a usb to Bluetooth module or modify the firmware so primary serial is routed to a normal hardware serial port.
User avatar
By pazi88
#41335
I'm using same board and it works fine with USB when using these settings in Arduino IDE:
Settings.png
Settings.png (8.89 KiB) Viewed 25491 times
But I have problems when trying to change any values in TS. No matter what I touch, I get this error:
Error.png
Error.png (6.69 KiB) Viewed 25491 times
Probably something related to eeprom emulation, but not sure where to start looking for the fault.
  • 1
  • 8
  • 9
  • 10
  • 11
  • 12
  • 30

Hi, I am trying to assign Signed values to the x-a[…]

Vr Conditioner Noise when cranking

New version 202305 don't fix the issue. Now after[…]

blitzbox

I've finally figured out why MAP and Lambda weren'[…]

Hello, I bring news!! Let me tell you that after […]

Still can't find what you're looking for?