FHEM Forum

FHEM => Anfängerfragen => Thema gestartet von: MarkusAutomaticus am 26 Juli 2016, 19:02:40

Titel: Jeelink V3 flashen
Beitrag von: MarkusAutomaticus am 26 Juli 2016, 19:02:40
Hallo zusammen,

ich möchte meinen neuen Jeelink V3 flashen und bin mir unsicher, welche USB-Schnittstelle ich eintragen soll.

Vor dem Anschließen hat ein lsusb folgendes erbracht:

Bus 001 Device 005: ID 0403:6001 Future Technology Devices International, Ltd FT232 USB-Serial (UART) IC
Bus 001 Device 004: ID 0658:0200 Sigma Designs, Inc.
Bus 001 Device 003: ID 0424:ec00 Standard Microsystems Corp. SMSC9512/9514 Fast Ethernet Adapter
Bus 001 Device 002: ID 0424:9514 Standard Microsystems Corp.
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub


nach dem Einstöpseln des Jeelink:

Bus 001 Device 005: ID 0403:6001 Future Technology Devices International, Ltd FT232 USB-Serial (UART) IC
Bus 001 Device 004: ID 0658:0200 Sigma Designs, Inc.
Bus 001 Device 006: ID 0403:6001 Future Technology Devices International, Ltd FT232 USB-Serial (UART) IC
Bus 001 Device 003: ID 0424:ec00 Standard Microsystems Corp. SMSC9512/9514 Fast Ethernet Adapter
Bus 001 Device 002: ID 0424:9514 Standard Microsystems Corp.
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub


Woraus ich schließe, dass es sich um folgendes handelt:
Bus 001 Device 006: ID 0403:6001 Future Technology Devices International, Ltd FT232 USB-Serial (UART) IC

Was ich suche, ist das "x" bei folgendem define:

define myJeeLink JeeLink /dev/ttyUSBx@57600

Ich vermute, es ist die 6?!

Kann jemand die Richtigkeit des Vorgehens und der Vermutung bestätigen?

Gruß
Markus
Titel: Antw:Jeelink V3 flashen
Beitrag von: MarkusAutomaticus am 26 Juli 2016, 20:11:56
antworte ich mir halt selber.
Die 6 wollte er nicht akzeptieren.

Aber Linux wäre nicht Linux wenn man nicht mit einem gezielten "-t" weitere Infos bekäme:

/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=dwc_otg/1p, 480M
    |__ Port 1: Dev 2, If 0, Class=Hub, Driver=hub/5p, 480M
        |__ Port 1: Dev 3, If 0, Class=Vendor Specific Class, Driver=smsc95xx, 4                          80M
        |__ Port 2: Dev 6, If 0, Class=Vendor Specific Class, Driver=ftdi_sio, 1                          2M
        |__ Port 4: Dev 4, If 0, Class=Communications, Driver=cdc_acm, 12M
        |__ Port 4: Dev 4, If 1, Class=CDC Data, Driver=cdc_acm, 12M
        |__ Port 5: Dev 5, If 0, Class=Vendor Specific Class, Driver=ftdi_sio, 1                          2M


Device 6 liegt auf Port 2.
Also mal mit der 2 probieren.
Titel: Antw:Jeelink V3 flashen
Beitrag von: MarkusAutomaticus am 26 Juli 2016, 20:16:29
Leider ist er mit der 2 auch nicht zufrieden:

flashing JeeLink myJeeLink
detected Firmware: LaCrosse.hex
hex file: ./FHEM/firmware/JeeLink_LaCrosse.hex
port: /dev/ttyUSB2
log file: ./log/JeeLinkFlash.log
myJeeLink closed
command: avrdude -p atmega328P -c arduino -P /dev/ttyUSB2 -D -U flash:w:./FHEM/firmware/JeeLink_LaCrosse.hex 2>./log/JeeLinkFlash.log

--- AVRDUDE ---------------------------------------------------------------------------------
avrdude: ser_open(): can't open device "/dev/ttyUSB2": No such file or directory

avrdude done.  Thank you.

--- AVRDUDE ---------------------------------------------------------------------------------

myJeeLink opened


Hat noch jemand eine Idee?

Gruß
Markus
Titel: Antw:Jeelink V3 flashen
Beitrag von: MarkusAutomaticus am 26 Juli 2016, 20:37:24
was mache ich mir eigentlich die Mühe per ssh und shell kommandos den richtigen Port zu ermitteln,
wenn man durch rumprobieren schneller ans Ziel kommt?

flashing JeeLink myJeeLink
detected Firmware: LaCrosse.hex
hex file: ./FHEM/firmware/JeeLink_LaCrosse.hex
port: /dev/ttyUSB0
log file: ./log/JeeLinkFlash.log
myJeeLink closed
command: avrdude -p atmega328P -c arduino -P /dev/ttyUSB0 -D -U flash:w:./FHEM/firmware/JeeLink_LaCrosse.hex 2>./log/JeeLinkFlash.log

--- AVRDUDE ---------------------------------------------------------------------------------

avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.00s

avrdude: Device signature = 0x1e950f
avrdude: reading input file "./FHEM/firmware/JeeLink_LaCrosse.hex"
avrdude: input file ./FHEM/firmware/JeeLink_LaCrosse.hex auto detected as Intel Hex
avrdude: writing flash (28690 bytes):

Writing | ################################################## | 100% 4.17s

avrdude: 28690 bytes of flash written
avrdude: verifying flash memory against ./FHEM/firmware/JeeLink_LaCrosse.hex:
avrdude: load data flash data from input file ./FHEM/firmware/JeeLink_LaCrosse.hex:
avrdude: input file ./FHEM/firmware/JeeLink_LaCrosse.hex auto detected as Intel Hex
avrdude: input file ./FHEM/firmware/JeeLink_LaCrosse.hex contains 28690 bytes
avrdude: reading on-chip flash data:

Reading | ################################################## | 100% 3.20s

avrdude: verifying ...
avrdude: 28690 bytes of flash verified

avrdude done.  Thank you.

--- AVRDUDE ---------------------------------------------------------------------------------

myJeeLink opened


ttyUSB0 klar!