Giter Club home page Giter Club logo

ols-fwloader's People

Contributors

arthurlutz avatar nickandrew avatar oliv3r avatar robots avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

ols-fwloader's Issues

add a warning when running without root access

... does it need root access ?

It just failed without root, then added sudo, worked, but tried again without sudo and it works now...

arthur@black:~/local/ols-fwloader$ sudo ./src/ols_fwloader -S -f APP -P /dev/OpenLogicSniffer 
[sudo] password for arthur: 
Found OLS HW: 1, FW: 2.3, Boot: 2
Found flash: WINBOND W25X40 
done...
Passed self-test :) 
arthur@black:~/local/ols-fwloader$ ./src/ols_fwloader -S -f APP -P /dev/OpenLogicSniffer 
Found OLS HW: 1, FW: 2.3, Boot: 2
Found flash: WINBOND W25X40 
done...
Passed self-test :) 

Checking flash ... (0x0800 - 0x3c00) Verify failed :(

First it fails without sudo, then it fails on flash (no more logs since libusbx is too verbose and not enough terminal history)

arthur@black:~/local/ols-fwloader$ ./src/ols_fwloader -f BOOT -n -P /dev/OpenLogicSniffer -V -w ~/local/ols-0308/OLS_Upgrader/PIC_firmware/OLSv1.firmware.v3.0.hex 
Found OLS HW: 1, FW: 2.3, Boot: 2
Found flash: WINBOND W25X40 
OLS switched to bootloader mode
[timestamp] [threadID] facility level [function call] <message>
--------------------------------------------------------------------------------
[ 0.007720] [0000414f] libusbx: debug [libusb_get_device_list] 
[ 0.007883] [0000414f] libusbx: debug [discovered_devs_append] need to increase capacity
[ 0.007928] [0000414f] libusbx: debug [libusb_get_device_descriptor] 
[ 0.007958] [0000414f] libusbx: debug [libusb_get_device_descriptor] 
[ 0.007987] [0000414f] libusbx: debug [libusb_get_device_descriptor] 
[ 0.008019] [0000414f] libusbx: debug [libusb_get_device_descriptor] 
[ 0.008116] [0000414f] libusbx: debug [libusb_get_device_descriptor] 
[ 0.008150] [0000414f] libusbx: debug [libusb_get_device_descriptor] 
[ 0.008181] [0000414f] libusbx: debug [libusb_open] open 7.12
[ 0.008270] [0000414f] libusbx: error [_get_usbfs_fd] libusbx couldn't open USB device /dev/bus/usb/007/012: Permission denied
[ 0.008313] [0000414f] libusbx: error [_get_usbfs_fd] libusbx requires write access to USB device nodes.
[ 0.008348] [0000414f] libusbx: debug [libusb_open] open 7.12 returns -3
USB Device (04d8:fc90) not found, is OLS in bootloader mode ?

arthur@black:~/local/ols-fwloader$ sudo ./src/ols_fwloader -f BOOT -n -P /dev/OpenLogicSniffer -V -w ~/local/ols-0308/OLS_Upgrader/PIC_firmware
[snip]
[ 1.156229] [000045ed] libusbx: debug [sync_transfer_cb] actual_length=64
[ 1.156256] [000045ed] libusbx: debug [add_to_flying_list] arm timerfd for timeout in 1000ms (first in line)
[ 1.185216] [000045ed] libusbx: debug [submit_bulk_transfer] need 1 urbs for new transfer with length 64
[ 1.185286] [000045ed] libusbx: debug [libusb_handle_events_timeout_completed] doing our own event handling
[ 1.185302] [000045ed] libusbx: debug [handle_events] poll() 4 fds with timeout in 60000ms
[ 1.186096] [000045ed] libusbx: debug [handle_events] poll() returned 1
[ 1.186130] [000045ed] libusbx: debug [reap_for_handle] urb type=1 status=0 transferred=64
[ 1.186158] [000045ed] libusbx: debug [handle_bulk_completion] handling completion status 0 of bulk urb 1/1
[ 1.186173] [000045ed] libusbx: debug [handle_bulk_completion] last URB in transfer --> complete!
[ 1.186187] [000045ed] libusbx: debug [disarm_timerfd] 
[ 1.186202] [000045ed] libusbx: debug [usbi_handle_transfer_completion] transfer 0x1aa4d58 has callback 0x7f1fcfafa7f0
[ 1.186216] [000045ed] libusbx: debug [sync_transfer_cb] actual_length=64
Checking flash ... (0x0800 - 0x3c00)
Verify failed :(
[ 1.186318] [000045ed] libusbx: debug [libusb_release_interface] interface 0
[ 1.186362] [000045ed] libusbx: debug [libusb_attach_kernel_driver] interface 0
[ 1.192314] [000045ed] libusbx: debug [libusb_close] 
[ 1.192388] [000045ed] libusbx: debug [usbi_remove_pollfd] remove fd 11
[ 1.192420] [000045ed] libusbx: debug [libusb_exit] 
[ 1.192432] [000045ed] libusbx: debug [libusb_exit] destroying default context

ps. how do I disable the debug on libusbx ?

macOS support

Running macOS 10.13 here, and noticed I am unable to read the current firmware on my OpenBench Logic Sniffer using the command provided in the README

ols-fwloader -f BOOT -t HEX -R -r current-pic-firmware.hex

I end up with the following error message when trying to read the FW on the PIC to a local file.

Cannot claim USB device
Unable to set alternative interface
Other error - recv

FWIW, when plugging in the device with the jumper connected as described in the README, macOS doesn't appear to create a entry for the device located within /dev

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.