How can I change the arduino board serial number using averdud or avrgc++ without recompiling the sketch again.
I think that the serial number is saved somewhere in the flash memory. close to the bootloader so is there a part to updat that part of the flash memory using the cmd, averdud or avr gc++ ?
It is a Arduino Micro (ATmega32U4 ). Is there away to change the serial number without recompiling the firmware ? I wanna be able to keep track of my .hex files using the date stamp
Is putting a version in your sketch not an option?
Further, the constants DATE and TIME refer to the date/time when the sketch was compiled. Can be useful if you upload using avrdude from the command line (else you have to recompile for an upload resulting in a different date/time).
Are you sure that your Arduino HAS a serial number?
I can't find any reference to loading one up in the core source code, and my (admittedly ancient) leonardo doesn't seem to be reporting an Serial Number to my Mac...
sterretje:
Is putting a version in your sketch not an option?
Further, the constants DATE and TIME refer to the date/time when the sketch was compiled. Can be useful if you upload using avrdude from the command line (else you have to recompile for an upload resulting in a different date/time).
Yes but still i wont be able to find out which chip has which hex file unless I have to save all the hex files
If i added cont date and time, How can I recall them ?
westfw:
Are you sure that your Arduino HAS a serial number?
I can't find any reference to loading one up in the core source code, and my (admittedly ancient) leonardo doesn't seem to be reporting an Serial Number to my Mac...
Yes It does, I had to do few modification to some of the core code and the bootloader that allowed me to add a descriptor to the device. Please refer to my other post (adding a PID and VID to Arduino Micro)
I had to do few modification to some of the core code and the bootloader
So... You've successfully modified the bootloader to include your own VID/PID/SerialNum, and maybe the USB core as well. You have not shown anyone this modified code, and now you want help changing the serialnumber (which doesn't exist in standard arduino code) without re-compiling? As part of uploading? after the sketch is uploaded?
Probably the easiest way it to add additional changes to your code to look for an "updated serial number" at a particular additional flash page or EEPROM location, if you have those available.
if (get_serialnum_magicnumber() == SERNUM_PRESENT) {
usb_sernum_info = get_serialnum_new();
}
westfw:
So... You've successfully modified the bootloader to include your own VID/PID/SerialNum, and maybe the USB core as well. You have not shown anyone this modified code, and now you want help changing the serialnumber (which doesn't exist in standard arduino code) without re-compiling? As part of uploading? after the sketch is uploaded?
Yes I was successfully able to do all that and I also build my own Labview app to burn the bootloader and upload the sketch. However, I am still missing to main points
1- Is the ability to update the serial number without recompliling
2- ability to compile the sketch using my averdud or agc++ so i can build in in my labview app
Yes; if you ever want to go back to an earlier release. My versioning skills are poor so I use directories for each version. One of the subdirectories in these directories contains notes, documentation and the hex file of the final release of that version.
If you use a proper versioning system (e.g. git), you should be able to retrieve earlier hex files (if you did check them in) just like you would extract earlier versions of the software.