On Apr 14, 2009, at 12:09 PM, Øyvind Harboe wrote:
On Tue, Apr 14, 2009 at 7:25 PM, Magnus Lundin <lun...@mlu.mine.nu> wrote:Hi I have commited a patch that gives more readable error reporting for STM32 flash writing errors. But still all errors are reported with the error code ERROR_FLASH_OPERATION_FAILED (-902) as return code wich is not very helpul about the cause of the error.My suggestion is to return the more differentiated error codes already available in flash.h without so many verbose messages and then generatemeaningful LOG_ERROR text messages in flash.c . ?????????????I'd rather go the other way, not to try to communicate any information through error codes, i.e. to use it *only* as a boolean fail/success. There are only a few places in which the error codes are checked, and I see little reason to expose error codes to the user. -- Øyvind Harboe PayBack incident management system Reduce costs and increase quality, free Starter Edition http://www.payback.no/index_en.html _______________________________________________ Openocd-development mailing list Openocd-development@lists.berlios.de https://lists.berlios.de/mailman/listinfo/openocd-development
I'd rather know _why_ something failed rather than having to dig through the code to figure out which layer and why. Not every user is a UNIX programmer with intimate knowledge of the targets, interfaces, and general protocols.
-- Rick Altherr kc8...@kc8apf.net"He said he hadn't had a byte in three days. I had a short, so I split it with him."
-- Unsigned
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________ Openocd-development mailing list Openocd-development@lists.berlios.de https://lists.berlios.de/mailman/listinfo/openocd-development