Romlog referring to seemingly non-existing file called dwWrtBuf.c - General Help and Assistance on using CHDK stable releases - CHDK Forum

Romlog referring to seemingly non-existing file called dwWrtBuf.c

  • 8 Replies
  • 5939 Views
Advertisements
I've been using CHDK and CHDK-PTP for a while now and it has been working reliably, with the exception of one recent camera crash.

I use CHDK-PTP to issue shoot commands. Yesterday after about 10 successful shoot commands, the camera crashed or otherwise powered down. I have not been able to reproduce this issue.

The ROMLOG.LOG file started with the following:

Code: [Select]
ASSERT!! dwWrtBuf.c Line 621
Occured Time  2017:02:10 14:18:46
Task ID: 47186014
Task name: DvlpSeqTask
...
See attachment for full log.

While CHDK reported (the same error is shown when you cut power to the camera):

Code: [Select]
...
[2017-02-10 11:35:29] shoot -tv=1/200 -isomode=800
[2017-02-10 11:35:34] ERROR: I/O error
attempted to close non-present device 001:010
connected: Canon PowerShot SX130 IS, max packet size 512
[2017-02-10 11:35:35] ERROR: no matching devices found
ERROR: not connected
...

The problem is that I can't find the file dwWrtBuf.c. It seems like it doesn't exist anywhere. I tried searching the source code (both contents and filenames).
Also using google and bing I was unable to find anything. The only matches were from people using wrtBuf as a variable name. But as a filename, both the searches WrtBuf and dxWrtBuf give basically zero search results.

Does anyone know where to find dwWrtBuf.c or what the attached ROMLOG indicates?


Re: Romlog referring to seemingly non-existing file called dwWrtBuf.c
« Reply #1 on: 11 / February / 2017, 12:31:14 »
The problem is that I can't find the file dwWrtBuf.c. It seems like it doesn't exist anywhere. I tried searching the source code (both contents and filenames). Also using google and bing I was unable to find anything. The only matches were from people using wrtBuf as a variable name. But as a filename, both the searches WrtBuf and dxWrtBuf give basically zero search results.
The file names in the ROMLOG.LOG refer to the original source code files used when Canon compiled the code for the camera.  So you are not going to find it anywhere in CHDK source or online - it's not something Canon shares.
Ported :   A1200    SD940   G10    Powershot N    G16

*

Offline reyalp

  • ******
  • 14119
Re: Romlog referring to seemingly non-existing file called dwWrtBuf.c
« Reply #2 on: 11 / February / 2017, 14:11:49 »
To add to what waterwingz said, the file name and line number is still useful. You can use them to find the assert in disassembled firmware code form the ROM dump, which sometimes allows you to figure out the cause of the crash.

If you look at the lower section of the the romlog with the camera log messages, they can sometimes give you an idea where in the shooting sequence it happened.

If you aren't able to follow the disassembly yourself, let us know which Canon firmware your sx130 has, someone here may be able to take a look at it.

The error messages from chdkptp are not really informative for this kind of thing, they just tell you the connection went away due to the camera crashing.
Don't forget what the H stands for.

Re: Romlog referring to seemingly non-existing file called dwWrtBuf.c
« Reply #3 on: 13 / February / 2017, 06:43:37 »
@waterwingz & @reyalp: Thanks for the clarification.

If I understand correctly I should execute following two tutorials in order:

http://chdk.wikia.com/wiki/Canon_Basic/Scripts/Dumper
http://chdk.wikia.com/wiki/Capdis_Disassembly_Tool

Will I find matches in disassembled output when searching using queries found in ROMLOG.LOG like "dwWrtBuf.c", "UI:DispSw: Lock", "ShtCon_PrepareCapture"?

Or should I try searching for the 0x addresses? Or the numbers that prefix the (log messages?) like: 00777630: UI:DispSw: Lock





Romlog referring to seemingly non-existing file called dwWrtBuf.c
« Reply #4 on: 13 / February / 2017, 07:40:05 »
You can do either one. But be aware that this is a huge task with a steep learning curve that you are apparently taking on.  And even if you somehow figure out what the camera was doing at the time of the crash, that may not tell you much about why it happened.
Ported :   A1200    SD940   G10    Powershot N    G16

Re: Romlog referring to seemingly non-existing file called dwWrtBuf.c
« Reply #5 on: 13 / February / 2017, 12:35:36 »
I suppose you might be right. Although I'm very familiar with C/C++, Assembly code and disassembly output is possibly a bridge too far.

Does anyone have a hypothesis what could be causing the incidental crash after triggering the shoot command using CHDK-PTP? I might be able to rule out potential causes by simple deduction.

I will make sure the power supply is stable and I will also see if I can reproduce the amount of EM noise that was being present at the time of failure (camera was mounted on a UAS). I have already partially tested this and have not been able to reproduce the issue.

I will post a link to the Canon firmware I'm using in case anyway one is willing to take diagnose my ROMLOG.LOG file.

*

Offline reyalp

  • ******
  • 14119
Re: Romlog referring to seemingly non-existing file called dwWrtBuf.c
« Reply #6 on: 13 / February / 2017, 13:45:51 »
I will post a link to the Canon firmware I'm using in case anyway one is willing to take diagnose my ROMLOG.LOG file.
We just need to know the version, the developers already have a dump for every camera in the autobuilds.
Don't forget what the H stands for.

Re: Romlog referring to seemingly non-existing file called dwWrtBuf.c
« Reply #7 on: 13 / February / 2017, 14:24:25 »
These are the camera, firmware and CHDK versions:
Canon PowerShot SX130 IS
Firmware: 101c
CHDK version: stable 1.4.1

If anyone has any idea about why CHDK crashed, or wants to take a look at the ROMLOG I posted in my first post, it would be greatly appreciated.


*

Offline reyalp

  • ******
  • 14119
Re: Romlog referring to seemingly non-existing file called dwWrtBuf.c
« Reply #8 on: 13 / February / 2017, 17:27:27 »
These are the camera, firmware and CHDK versions:
Canon PowerShot SX130 IS
Firmware: 101c
CHDK version: stable 1.4.1

If anyone has any idea about why CHDK crashed, or wants to take a look at the ROMLOG I posted in my first post, it would be greatly appreciated.
The assert call is at FFB2394C. It's triggered based on comparing two registers values from memory, so unfortunately the underlying cause isn't something obvious like a malloc failing.

I'm not sure what dwWrtBuf.c does (presumably Write Buffer for something, but what?) It's being called from DvlpSeqTask, which is not modified by CHDK in this port.

I don't remember anyone reporting errors in this file before, and the only google result is this thread.

The stack trace in the romlog might give some clues, but I don't have time to go through it at the moment.

It might also help if you can describe more about your setup, for example if the chdkptp shoot command is part of a larger script.
Don't forget what the H stands for.

 

Related Topics


SimplePortal 2.3.6 © 2008-2014, SimplePortal