Author Topic: Infineon C166 Family  (Read 8009 times)

0 Members and 2 Guests are viewing this topic.

Offline Fixed_Until_BrokenTopic starter

  • Regular Contributor
  • *
  • Posts: 98
  • Country: us
Re: Infineon C166 Family
« Reply #25 on: August 31, 2020, 09:06:14 pm »
Today I got my logic analyzer in. So here is exactly whats being sent Top line is TX (from MCU, RX to pc) and bottom line is RX (for MCU Tx from PC)

Minimon is trying to write to it. Here are 2 samples.
 

Offline abyrvalg

  • Frequent Contributor
  • **
  • Posts: 837
  • Country: es
Re: Infineon C166 Family
« Reply #26 on: September 01, 2020, 01:11:58 pm »
I see the problem now: you are trying to "load to memory" instead of "program to flash". Use the blue "P" button.
 

Offline Fixed_Until_BrokenTopic starter

  • Regular Contributor
  • *
  • Posts: 98
  • Country: us
Re: Infineon C166 Family
« Reply #27 on: September 01, 2020, 04:23:29 pm »
When I try the P I just get "*IProgram:0 bytes successfully programmed" It doesn't even try to send anything over uart. So Nothing to capture there.

Edit: If I try the S I get an error "*ERROR: download not successful" and it doesn't try to send anything.
« Last Edit: September 01, 2020, 04:31:45 pm by Fixed_Until_Broken »
 

Offline Fixed_Until_BrokenTopic starter

  • Regular Contributor
  • *
  • Posts: 98
  • Country: us
Re: Infineon C166 Family
« Reply #28 on: September 01, 2020, 07:31:25 pm »
I'm not sure what change got the status send status request. It returns 0000 for all of it.  I played with what kernel it was loading and that seemed make make the status request to send. still nothing from program
 

Offline Fixed_Until_BrokenTopic starter

  • Regular Contributor
  • *
  • Posts: 98
  • Country: us
Re: Infineon C166 Family
« Reply #29 on: September 20, 2020, 07:48:22 pm »
I got some test boards in and can confirm erase works, Read works but program does nothing.
 

Offline abyrvalg

  • Frequent Contributor
  • **
  • Posts: 837
  • Country: es
Re: Infineon C166 Family
« Reply #30 on: September 21, 2020, 01:26:24 pm »
So the flash driver is ok, but the problem is that sw thinks you are trying to program data of size 0 for some reason:
When I try the P I just get "*IProgram:0 bytes successfully programmed" It doesn't even try to send anything over uart. So Nothing to capture there.

Two more ideas to try:
1. The flash burst size is 0x40, maybe sw doesn't like data size not a multiple of that. Try selecting exactly 0x40 bytes, then hit P.
2. The first part of flash is remapable (0x10000->0), maybe something is wrong with these addresses (i.e. you must use 0x10000 instead of 0). Try writing to nonremapable part first (at 0x18000).
 

Offline Fixed_Until_BrokenTopic starter

  • Regular Contributor
  • *
  • Posts: 98
  • Country: us
Re: Infineon C166 Family
« Reply #31 on: September 21, 2020, 03:57:42 pm »
Ok I had a little success last night. It it still wont program it but if remove the Activate for the program flash it will try to program it. It then has an X next program flash in the A column. When you click program it erases the section you are in and then tries to program it but then fails. attached is a capture of it on the signal analyzer its too long for screenshots. puslesview can open it.
 

Offline abyrvalg

  • Frequent Contributor
  • **
  • Posts: 837
  • Country: es
Re: Infineon C166 Family
« Reply #32 on: September 21, 2020, 05:50:42 pm »
Pulseview UART decoder is buggy (decoding some bits to wrong values). Could you use some software-only "serial port monitor" instead? Extracting the comms bit by bit manually is too much.
 

Offline Fixed_Until_BrokenTopic starter

  • Regular Contributor
  • *
  • Posts: 98
  • Country: us
Re: Infineon C166 Family
« Reply #33 on: September 23, 2020, 04:42:05 pm »
OK you will probably find this annoying because of how its captured but I cant find any good software for capturing the com port on windows. I ended up using a second FTDI adapter and just captured it as it sends.  I decided to capture both what gets TX'd for Erase and Program and its the same so Minimon still isn't actually tying to program it.

Code: [Select]
Program TX:
8400C000440348803D5AF05AF06B66FDC0FF2892E6F3AAAAE6F45000D7000200B843DC0BA84A08A218B0DC0EB84D2892E6F3F2A0DC0BA84A08A218B0D7000200B843B0293DF7E6F3AAAAE6F4AA00D7000200B843E6F35455E6F45500D7000200B843E6F3AAAAE6F4A000D7000200B843DC0BA84ADC0EB84DE6F3AAAAE6F4FA00D7000200B843E001D7000200A8918AF9F300F0A5F0B6E6F94000E00FDC0BA94ADC0EA95D08A118B008D118E041452D03E6FF1100DB00289148903DF0DB0046F820003D2CE6F3AAAAE6F4AA00D7000200B843E6F35455E6F45500D7000200B843E6F35E5EE6F45E00D7000200B843E6F35455E6F4AA00D7000200B843E6F3AAAAE6F45500D7000200B843E6F35A5AE6F45A00D7000200B843E00FDB0046F821003D2A9A8902C0E0170D01E007E6F3AAAAE6F4AA00D7000200B843E6F35455E6F45500D7000200B843E6F33C3CE6F43C00D7000200B843E6F6F83F2892DC0BA85A08A218B0DC07B856DC07A8560862B0093DF5E00FDB0048813D37BB45E6F3AAAAE6F4AA00D7000200B843E6F35455E6F45500D7000200B843E6F3AAAAE6F48000D7000200B843E6F35455E6F4AA00D7000200B843E6F3AAAAE6F45500D7000200B843E6F43000DC02B841E6F3AAAAE6F4FA00D7000200B843E001D7000200A8918AF9F300E00FDB0048863D52E018BB0BE6F3AAAAE6F4FA00D7000200B843DC02A891E00FDB0048E03D07E0019A8902C0E012CB00E002CB0048E13D06E6F100409A89F8C0E012CB0048E23D06E6F100609A89F0C0E012CB0048E33D04E6F10080E012CB0048E43D03E001E022CB0048E53D04E6F10080E022CB0048E63D03E001E032CB0048E73D04E6F10080E032CB0046FE08003D03E001E042CB0046FE09003D04E6F10080E042CB00E6FF3300CB0046F810003D28BBB7E6F3AAAAE6F4AA00D7000200B843E6F35455E6F45500D7000200B843E6F3AAAAE0F4D7000200B843E6F35455E6F4AA00D7000200B843E6F3AAAAE6F45500D7000200B843E0A4DC02B841E00FDB0046F811003D2D9A8902C0E0170D01E007BB87E6F3AAAAE6F4AA00D7000200B843E6F35455E6F45500D7000200B843E6F3AAAAE004D7000200B843E6F6F83F2892DC0BA85A08A218B0DC07B856DC07A8560862B0093DF5E054DC02B841E00FDB00E01FDB0033

EraseTX:
8400C000440348803D5AF05AF06B66FDC0FF2892E6F3AAAAE6F45000D7000200B843DC0BA84A08A218B0DC0EB84D2892E6F3F2A0DC0BA84A08A218B0D7000200B843B0293DF7E6F3AAAAE6F4AA00D7000200B843E6F35455E6F45500D7000200B843E6F3AAAAE6F4A000D7000200B843DC0BA84ADC0EB84DE6F3AAAAE6F4FA00D7000200B843E001D7000200A8918AF9F300F0A5F0B6E6F94000E00FDC0BA94ADC0EA95D08A118B008D118E041452D03E6FF1100DB00289148903DF0DB0046F820003D2CE6F3AAAAE6F4AA00D7000200B843E6F35455E6F45500D7000200B843E6F35E5EE6F45E00D7000200B843E6F35455E6F4AA00D7000200B843E6F3AAAAE6F45500D7000200B843E6F35A5AE6F45A00D7000200B843E00FDB0046F821003D2A9A8902C0E0170D01E007E6F3AAAAE6F4AA00D7000200B843E6F35455E6F45500D7000200B843E6F33C3CE6F43C00D7000200B843E6F6F83F2892DC0BA85A08A218B0DC07B856DC07A8560862B0093DF5E00FDB0048813D37BB45E6F3AAAAE6F4AA00D7000200B843E6F35455E6F45500D7000200B843E6F3AAAAE6F48000D7000200B843E6F35455E6F4AA00D7000200B843E6F3AAAAE6F45500D7000200B843E6F43000DC02B841E6F3AAAAE6F4FA00D7000200B843E001D7000200A8918AF9F300E00FDB0048863D52E018BB0BE6F3AAAAE6F4FA00D7000200B843DC02A891E00FDB0048E03D07E0019A8902C0E012CB00E002CB0048E13D06E6F100409A89F8C0E012CB0048E23D06E6F100609A89F0C0E012CB0048E33D04E6F10080E012CB0048E43D03E001E022CB0048E53D04E6F10080E022CB0048E63D03E001E032CB0048E73D04E6F10080E032CB0046FE08003D03E001E042CB0046FE09003D04E6F10080E042CB00E6FF3300CB0046F810003D28BBB7E6F3AAAAE6F4AA00D7000200B843E6F35455E6F45500D7000200B843E6F3AAAAE0F4D7000200B843E6F35455E6F4AA00D7000200B843E6F3AAAAE6F45500D7000200B843E0A4DC02B841E00FDB0046F811003D2D9A8902C0E0170D01E007BB87E6F3AAAAE6F4AA00D7000200B843E6F35455E6F45500D7000200B843E6F3AAAAE004D7000200B843E6F6F83F2892DC0BA85A08A218B0DC07B856DC07A8560862B0093DF5E054DC02B841E00FDB00E01FDB0033
 

Offline Fixed_Until_BrokenTopic starter

  • Regular Contributor
  • *
  • Posts: 98
  • Country: us
Re: Infineon C166 Family
« Reply #34 on: October 05, 2020, 03:13:21 am »
Not much of an update other than I have dumped a few more got the same results. I made a video and uploaded to youtube sharing whats been figured out so far and asking if anyone has any ideas. https://youtu.be/lvFUQ_b-JZo
 

Offline Fixed_Until_BrokenTopic starter

  • Regular Contributor
  • *
  • Posts: 98
  • Country: us
Re: Infineon C166 Family
« Reply #35 on: October 11, 2020, 06:17:33 pm »
Ok I got an email from some one this morning saying it will work if you program 768 bytes at a time. I figured out from there it will work up to 832 bytes It still gives an error that program failed but thats not the case it is successful. the really annoying part is that you have restart minimon and the MCU every 832 bytes you program so this is going to take all day to do the 128kb on the blank MCU I am working with.

Edit you don't actually have to restart minimon its just the mcu. Is there a way to call reset with minimon? if so I could do a user script with minimon. Srst doesn't rest into BSL it goes into user program if you do that.
« Last Edit: October 11, 2020, 08:09:00 pm by Fixed_Until_Broken »
 

Offline Larsoners

  • Newbie
  • Posts: 1
  • Country: ru
Re: Infineon C166 Family
« Reply #36 on: November 02, 2020, 03:10:36 pm »
Integrated On-Chip Memory
• 2 KByte internal RAM for variables, register banks, system stack and code
• 8 KByte on-chip high-speed XRAM for variables, user stack and code
• 256 KByte on-chip Program ROM (not for ROMless devices)
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf