[Elphel-support] [#265683] Fwd: RedZone Robotics ELphel Imagers & Boards

Aaron Joseph ajoseph at redzone.com
Tue Oct 15 06:28:05 PDT 2013


Oleg,

I change the code to look like the following:

* /* Select the device */
this->select_chip(mtd, 0);

// while(1) {
/* Send the command for reading device ID */
this->cmdfunc (mtd, NAND_CMD_READID, 0x00, -1);

/* Read manufacturer and device IDs */
nand_maf_id = this->read_byte(mtd);
nand_dev_id = this->read_byte(mtd);

// Added to make flashitall get the right device ID.
nand_dev_id = 0xF1;

printk("nand_scan(): nand_maf_if == 0x%02X; nand_dev_id == 0x%02X\n",
nand_maf_id,
nand_dev_id);

/* Select the device */
this->select_chip(mtd, 0);

// while(1) {
/* Send the command for reading device ID */
this->cmdfunc (mtd, NAND_CMD_READID, 0x00, -1);

/* Read manufacturer and device IDs */
nand_maf_id = this->read_byte(mtd);
nand_dev_id = this->read_byte(mtd);

// Added to make flashitall get the right device ID.
nand_dev_id = 0xF1;

printk("nand_scan(): nand_maf_if == 0x%02X; nand_dev_id == 0x%02X\n",
nand_maf_id,
nand_dev_id);
//printk("1... nand_scan(): this->eccmode == %d\n", (int)this->eccmode);
// }
/* Print and store flash device information */

for (i = 0; nand_flash_ids[i].name != NULL; i++) { ....*



Not sure if this is what you meant for me to do, but now my flashitall
output looks as follows:

0xc0000000
0xc3ffffff

Memory test
1:................................................................
Memory test
2:................................................................Passed
memory test.
PACKET_INFO
0x40000000
0x00020000
NAND_FLASH
0x40000000
0x00000000
0x0003ffff
0x00020000
nand_scan(): nand_maf_if == 0x00; nand_dev_id == 0xF1
nand_scan(): nand_maf_if == 0x2C; nand_dev_id == 0xF1
NAND device: Manufacturer ID: 0x2c, Chip ID: 0xf1 (Micron NAND 128MiB 3,3V
8-bit)
mtd->oobsize == 0x00000080
this->phys_erase_shift == 0x00000010
this->page_shift == 0x0000000D
mtd->oobsize << ... == 0x00000400
No oob scheme defined for oobsize 128


So, we have a new error... which to me seems promising.

Can I just hard code a bunch of values for whatever parameters flashitall
tries to read in? Fixing flashitall may be the best route for me because
no-one here really knows much about the custom firmware that was built--
which makes it very hard to port those changes to 8.2.15. Plus, I can't be
the only person with this issue so sorting out how to fix it will probably
benefit more than just me.

The other route I was exploring was copying my 7.1.5 images into the 8.2.15
nfs folder used by the netboot flashing method with the hope that netboot
could just kinda figure out what to do. But that didn't work.


--Aaron Joseph




On Mon, Oct 14, 2013 at 6:38 PM, Oleg K Dzhimiev <oleg at elphel.com> wrote:

> Aaron,
>
> "flashitall" reads the chip ID incorrectly - "0x01" vs correct one "0xF1"
> at netboot and normal boot - this leads to an error (because of different
> parameters) when flash is being written.
>
> One more thing to try - there is a file elphel353/tools/build-R2_19_3/fsboot/cbl/nand/nand_base.c,
> line ~2660 there are 2 code patterns repeated - hard to remember why, but
> you could try to add the third one (and rebuild) - so it might finally read
> the correct chip ID:
>
>  /* Select the device */
>> this->select_chip(mtd, 0);
>> // while(1) {
>>  /* Send the command for reading device ID */
>> this->cmdfunc (mtd, NAND_CMD_READID, 0x00, -1);
>> /* Read manufacturer and device IDs */
>>  nand_maf_id = this->read_byte(mtd);
>> nand_dev_id = this->read_byte(mtd);
>>         printk("nand_scan(): nand_maf_if == 0x%02X; nand_dev_id ==
>> 0x%02X\n", nand_maf_id, nand_dev_id);
>
>
> If that will not work - fixing that old code of Axis might take a long
> time also.
>
> Can we please continue our discussion on our public mailing list so the
> information will not get lost? (support-list at support.elphel.com)
>
> Thanks,
> Oleg
>
>
> On 14 October 2013 16:13, Aaron Joseph <ajoseph at redzone.com> wrote:
>
>>
>> I've attached the requested files.
>>
>> One note I will make is that the "Passed memory test" message in *
>> flashitall_output.txt* was not appearing before the changes were made to
>> '*nand_ids.c*' and '*mtd_nand.h*'. So making those changes you suggested
>> did something in the right direction.
>>
>> --Aaron
>>
>>
>>
>> On Mon, Oct 14, 2013 at 5:53 PM, Oleg K Dzhimiev <oleg at elphel.com> wrote:
>>
>>> Aaron,
>>>
>>> Could you send the "dmesg" output from 8.2.15 from telnet session and
>>> the bad output from flashitall for the same board.
>>> Want to check if the board reads different chip IDs while the
>>> Manufacturer ID "stays" the same.
>>>
>>> Oleg
>>>
>>
>>
>
>
> --
> Best regards,
> Oleg Dzhimiev
> Electronics Engineer
> phone: +1 801 783 5555 x124
> Elphel, Inc.
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://support.elphel.com/pipermail/support-list_support.elphel.com/attachments/20131015/26c71c3a/attachment-0002.html>


More information about the Support-list mailing list