Skip to content

Updating firmware for SARA module do not work #60

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
umbynos opened this issue Jun 16, 2021 · 1 comment
Closed

Updating firmware for SARA module do not work #60

umbynos opened this issue Jun 16, 2021 · 1 comment
Labels
type: imperfection Perceived defect in any part of project

Comments

@umbynos
Copy link
Contributor

umbynos commented Jun 16, 2021

Bug Report

Current behavior

./FirmwareUploader firmware flash --log-level trace -b arduino:samd:mkrnb1500 -a /dev/ttyACM0 -m [email protected]_01_to_99 -v

Apparently, the update of the firmware for the SARA module do not work properly:
This is the output of the command run above:

INFO[0000] FirmwareUploader Version: git-snapshot Commit: 75bffe3 Date: 2021-06-16T13:03:35Z 
INFO[0000] Checking signature                            index=/tmp/5577006791947779410977017813/index.json signatureFile=/tmp/5577006791947779410977017813/index.json.sig trusted=true
INFO[0000] Checking signature                            index=/tmp/fwuploader/package_index.json signatureFile=/tmp/fwuploader/package_index.json.sig trusted=true
INFO[0000] Checking signature                            index=/tmp/fwuploader/module_firmware_index.json signatureFile=/tmp/fwuploader/module_firmware_index.json.sig trusted=true
INFO[0001] Putting board into bootloader mode           
INFO[0003] Found port to upload Loader: %s/dev/ttyACM0  
Set binary mode
readWord(addr=0)=0x20007ffc
readWord(addr=0xe000ed00)=0x410cc601
readWord(addr=0x41002018)=0x10010305
version()=v2.0 [Arduino:XYZ] Mar 26 2018 12:29:38
chipId=0x10010005
Connected at 921600 baud
readWord(addr=0)=0x20007ffc
readWord(addr=0xe000ed00)=0x410cc601
readWord(addr=0x41002018)=0x10010305
Atmel SMART device 0x10010005 found
write(addr=0x20004000,size=0x34)
writeWord(addr=0x20004030,value=0x10)
writeWord(addr=0x20004020,value=0x20008000)
Device       : ATSAMD21G18A
readWord(addr=0)=0x20007ffc
readWord(addr=0xe000ed00)=0x410cc601
readWord(addr=0x41002018)=0x10010305
Chip ID      : 10010005
version()=v2.0 [Arduino:XYZ] Mar 26 2018 12:29:38
Version      : v2.0 [Arduino:XYZ] Mar 26 2018 12:29:38
Address      : 8192
Pages        : 3968
Page Size    : 64 bytes
Total Size   : 248KB
Planes       : 1
Lock Regions : 16
Locked       : readWord(addr=0x41004020)=0xffff
readWord(addr=0x41004020)=0xffff
readWord(addr=0x41004020)=0xffff
readWord(addr=0x41004020)=0xffff
readWord(addr=0x41004020)=0xffff
readWord(addr=0x41004020)=0xffff
readWord(addr=0x41004020)=0xffff
readWord(addr=0x41004020)=0xffff
readWord(addr=0x41004020)=0xffff
readWord(addr=0x41004020)=0xffff
readWord(addr=0x41004020)=0xffff
readWord(addr=0x41004020)=0xffff
readWord(addr=0x41004020)=0xffff
readWord(addr=0x41004020)=0xffff
readWord(addr=0x41004020)=0xffff
readWord(addr=0x41004020)=0xffff
none
readWord(addr=0x41004018)=0
Security     : false
Boot Flash   : true
readWord(addr=0x40000834)=0
BOD          : false
readWord(addr=0x40000834)=0
BOR          : false
Arduino      : FAST_CHIP_ERASE
Arduino      : FAST_MULTI_PAGE_WRITE
Arduino      : CAN_CHECKSUM_MEMORY_BUFFER
Erase flash
chipErase(addr=0x2000)
done in 0.848 seconds
Write 11312 bytes to flash (177 pages)
write(addr=0x20005000,size=0x1000)
writeBuffer(scr_addr=0x20005000, dst_addr=0x2000, size=0x1000)
[==========                    ] 36% (64/177 pages)write(addr=0x20005000,size=0x1000)
writeBuffer(scr_addr=0x20005000, dst_addr=0x3000, size=0x1000)
[=====================         ] 72% (128/177 pages)write(addr=0x20005000,size=0xc40)
writeBuffer(scr_addr=0x20005000, dst_addr=0x4000, size=0xc40)
[==============================] 100% (177/177 pages)
done in 0.061 seconds
Verify 11312 bytes of flash with checksum.
checksumBuffer(start_addr=0x2000, size=0x1000) = 828f
checksumBuffer(start_addr=0x3000, size=0x1000) = 391
checksumBuffer(start_addr=0x4000, size=0xc30) = fc43
Verify successful
done in 0.010 seconds
CPU reset.
readWord(addr=0)=0x20007ffc
readWord(addr=0xe000ed00)=0x410cc601
readWord(addr=0x41002018)=0x10010305
writeWord(addr=0xe000ed0c,value=0x5fa0004)
INFO[0007] Opened port /dev/ttyACM0 at 115200           
INFO[0007] Flashing firmware /tmp/fwuploader/firmwares/SARA/5.6A2_01_to_99/5.6A2_01_to_99.pkg 
Flashing firmware /tmp/fwuploader/firmwares/SARA/5.6A2_01_to_99/5.6A2_01_to_99.pkg
DEBU[0007] sending command data 0, 0, 0, [65 84 43 85 76 83 84 70 73 76 69 13 10] 
ERRO[0037] Expected +ULSTFILE:, got                     
ERRO[0037] Expected +ULSTFILE:, got                     
Error during firmware flashing: Expected +ULSTFILE:, got 
ERRO[0037] Error during firmware flashing: Expected +ULSTFILE:, got  

This seems to be broken even before the recent refactoring:

./FirmwareUploader -flasher firmwares/SARA/SerialSARAPassthrough.ino.bin -firmware firmwares/SARA/5.6A2_01/5.6A2_01_to_99.pkg  -address arduino.cc:443 -port /dev/ttyACM0 -programmer ~/.arduino15/packages/arduino/tools/bossac/1.7.0-arduino3/bossac
2021/06/16 16:02:33 Flashing firmware uploader sara
2021/06/16 16:02:33 Entering board into bootloader mode
2021/06/16 16:02:35 Flashing firmwares/SARA/SerialSARAPassthrough.ino.bin
Atmel SMART device 0x10010005 found
Erase flash
done in 0.849 seconds
Write 11312 bytes to flash (177 pages)
[==============================] 100% (177/177 pages)
done in 0.060 seconds
CPU reset.
2021/06/16 16:02:42 Connecting to programmer
2021/06/16 16:02:42 Opened the serial port with baud rate 115200
2021/06/16 16:02:44 Sync with programmer
2021/06/16 16:02:44 Sending ATE0
2021/06/16 16:03:14 
2021/06/16 16:03:14 Sending ATE0
2021/06/16 16:03:44 
2021/06/16 16:03:44 Sending ATE0
2021/06/16 16:04:14 
2021/06/16 16:04:14 Sending AT
2021/06/16 16:04:44 
2021/06/16 16:04:44 Error: Expected OK, got 

Expected behavior

Environment

  • Updater version: pulled from main (e5f422a)
  • OS and platform: linux

Additional context

@umbynos
Copy link
Contributor Author

umbynos commented Jun 24, 2021

support for it was removed in #65

@umbynos umbynos closed this as completed Jun 24, 2021
@rsora rsora added the type: imperfection Perceived defect in any part of project label Sep 22, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: imperfection Perceived defect in any part of project
Projects
None yet
Development

No branches or pull requests

2 participants