Making firmware hacking easier


Hello Mqtthiqs,
Thanks for your answer. i’ve tried with and without the 2 jumpers. When they’re off the stinkv2 tries to connect to an external chip. when they’re on, the stinkv2 is linked to the internal chip. (i’ve validated this with the ST Windows tool).
Do you suggest that i comment the PGM_SERIAL_PORT line ?

i’ve ordered a cable and will wait for it ! :slight_smile:


Don’t change anything about the PGM_SERIAL_PORT line. It’s not used anyway but any of the commands you use.


Thanks ! Received the adapter and it works perfectly well with the real hardware :slight_smile: Thanks so much for sharing this hacking environment !


Hi , try this and don’t understand the tutorial , the vagrant ssh must be run in OS X or the GUI of the VBOX ?
i did in the virtual box but ask me for a password

==> default: Checking if box ‘ubuntu/trusty64’ is up to date…
Your VM has become “inaccessible.” Unfortunately, this is a critical error
with VirtualBox that Vagrant can not cleanly recover from. Please open VirtualBox
and clear out your inaccessible virtual machines or find a way to fix
E-s-Pro:mutable-dev-environment-master E_$


“the vagrant ssh must be run in OS X”


“but ask me for a password”

default password is “vagrant”.


hi ! i start from scratch and im going to somewhere , but my /vagrant is empty
why could be that ??

thank again


Ok pardon the noob question (but I assume this environment partially set up to make things easy)…
I have the vagrant up and running on OSX 10.10
I can build the hex and makefile
ALL GOOD! Thank you!

Now, I want to use my FTDI232 to flash Elements (or some other module).
The Customization Page says that to use the stlink you can set your device like so…
export PGM_INTERFACE=stlink-v2

a) how do I know what string to use for my FTDI?
b) what does the “export PGM_INTERFACE_TYPE=hla” line do?


Do you have a FTDI232 device (USB->serial adapter) or a STlink board?


FTDI232 usb


I also have a F4discovery I can test for you.
I’m on OSX 10.10


Then you don’t need to mess with the jtag configuration since you won’t be using jtag.


Ah. Then I think I missed the part where I tell it how to use my FDTI232. Is it in the instructions somewhere?

Just trying the :
make -f clouds/makefile upload_combo_serial

I get :
Traceback (most recent call last):
File “stmlib/programming/serial/”, line 405, in[‘port’], conf[‘baud’])
File “stmlib/programming/serial/”, line 57, in open
timeout=0.5 # set a timeout value, None for waiting forever
File “/usr/lib/python2.7/dist-packages/serial/”, line 261, in init
File “/usr/lib/python2.7/dist-packages/serial/”, line 278, in open
raise SerialException(“could not open port %s: s” (self._port, msg))
serial.serialutil.SerialException: could not open port /dev/ftdi-usbserial: [Errno 2] No such file or directory: '/dev/ftdi-usbserial’
make: ***** [upload_combo_serial] Error 1

And for elements (still had to build the bootloader hex btw)

vagrant@vagrant-ubuntu-trusty-64:/vagrant/eurorack-modules$ make -f elements/makefile upload_combo_serial
cat build/elements/elements.hex build/elements_bootloader/elements_bootloader.hex | \\
awk -f stmlib/programming/merge_hex.awk > build/elements/elements_bootloader_combo.hex
/usr/local/arm-4.8.3/bin/arm-none-eabi-objcopy -I ihex -O binary build/elements/elements_bootloader_combo.hex build/elements/elements_bootloader_combo.bin
python stmlib/programming/serial/ \\
-p /dev/ftdi-usbserial \\
-b 115200 \\
-e -v \\
-w build/elements/elements_bootloader_combo.bin
Traceback (most recent call last):
File “stmlib/programming/serial/”, line 405, in[‘port’], conf[‘baud’])
File “stmlib/programming/serial/”, line 57, in open
timeout=0.5 # set a timeout value, None for waiting forever
File “/usr/lib/python2.7/dist-packages/serial/”, line 261, in init
File “/usr/lib/python2.7/dist-packages/serial/”, line 278, in open
raise SerialException(“could not open port %s: s” (self._port, msg))
serial.serialutil.SerialException: could not open port /dev/ftdi-usbserial: [Errno 2] No such file or directory: '/dev/ftdi-usbserial’
make: ***** [upload_combo_serial] Error 1


What do you see when you run the following command:

ls /dev/


in vagrant:
autofs cpu hpet loop4 net pts ram15 ram9 shm tty1 tty17 tty24 tty31 tty39 tty46 tty53 tty60 ttyS0 ttyS16 ttyS23 ttyS30 uinput vcs4 vcsa4
block cpu_dma_latency input loop5 network_latency ram0 ram2 random snapshot tty10 tty18 tty25 tty32 tty4 tty47 tty54 tty61 ttyS1 ttyS17 ttyS24 ttyS31 urandom vcs5 vcsa5
bsg disk kmsg loop6 network_throughput ram1 ram3 rfkill snd tty11 tty19 tty26 tty33 tty40 tty48 tty55 tty62 ttyS10 ttyS18 ttyS25 ttyS4 vboxguest vcs6 vcsa6
btrfs-control dri log loop7 null ram10 ram4 rtc stderr tty12 tty2 tty27 tty34 tty41 tty49 tty56 tty63 ttyS11 ttyS19 ttyS26 ttyS5 vboxuser vcs7 vcsa7
bus ecryptfs loop0 loop-control port ram11 ram5 rtc0 stdin tty13 tty20 tty28 tty35 tty42 tty5 tty57 tty7 ttyS12 ttyS2 ttyS27 ttyS6 vcs vcsa vga_arbiter
char fd loop1 mapper ppp ram12 ram6 sda stdout tty14 tty21 tty29 tty36 tty43 tty50 tty58 tty8 ttyS13 ttyS20 ttyS28 ttyS7 vcs1 vcsa1 zero
console full loop2 mcelog psaux ram13 ram7 sda1 tty tty15 tty22 tty3 tty37 tty44 tty51 tty59 tty9 ttyS14 ttyS21 ttyS29 ttyS8 vcs2 vcsa2
core fuse loop3 mem ptmx ram14 ram8 sg0 tty0 tty16 tty23 tty30 tty38 tty45 tty52 tty6 ttyprintk ttyS15 ttyS22 ttyS3 ttyS9 vcs3 vcsa3


Are you sure you have enabled virtualbox’s USB


I believe so. Here is the screenshot of the VB settings.

However, when I ls that dir in mac terminal, I also do not see it :frowning: I just installed the 32 bit driver on this page
and I had been flashing before from Mac with it before at home. Just tried a flash from mac and no luck either. So obviously not a flaw in the vagrant so far, but any clues what’s going on?

here is what I see in Mac terminal (10.11.2 work computer)
mattjacksonsoma:~ mattjackson$ ls /dev
afsc_type5 ptyw7
auditpipe ptyw8
auditsessions ptyw9
autofs ptywa
autofs_control ptywb
autofs_homedirmounter ptywc
autofs_notrigger ptywd
autofs_nowait ptywe
bpf0 ptywf
bpf1 random
bpf2 rdisk0
bpf3 rdisk0s1
bpf4 rdisk0s2
console rdisk0s3
cu.Bluetooth-Incoming-Port rdisk1
disk0 rdisk10
disk0s1 rdisk10s1
disk0s2 rdisk10s2
disk0s3 rdisk11
disk1 rdisk11s1
disk10 rdisk11s2
disk10s1 rdisk12
disk10s2 rdisk12s1
disk11 rdisk12s2
disk11s1 rdisk2
disk11s2 rdisk2s1
disk12 rdisk2s2
disk12s1 rdisk3
disk12s2 rdisk3s1
disk2 rdisk3s2
disk2s1 rdisk4
disk2s2 rdisk4s1
disk3 rdisk4s2
disk3s1 rdisk5
disk3s2 rdisk5s1
disk4 rdisk5s2
disk4s1 rdisk6
disk4s2 rdisk6s1
disk5 rdisk6s2
disk5s1 rdisk7
disk5s2 rdisk7s1
disk6 rdisk7s2
disk6s1 rdisk8
disk6s2 rdisk8s1
disk7 rdisk8s2
disk7s1 rdisk9
disk7s2 rdisk9s1
disk8 rdisk9s2
disk8s1 stderr
disk8s2 stdin
disk9 stdout
disk9s1 systrace
disk9s2 tty
dtrace tty.Bluetooth-Incoming-Port
dtracehelper ttyp0
fbt ttyp1
fd ttyp2
fsevents ttyp3
io8log ttyp4
io8logmt ttyp5
io8logtemp ttyp6
klog ttyp7
lockstat ttyp8
machtrace ttyp9
nsmb0 ttypa
null ttypb
pf ttypc
pfm ttypd
pmCPU ttype
profile ttypf
ptmx ttyq0
ptyp0 ttyq1
ptyp1 ttyq2
ptyp2 ttyq3
ptyp3 ttyq4
ptyp4 ttyq5
ptyp5 ttyq6
ptyp6 ttyq7
ptyp7 ttyq8
ptyp8 ttyq9
ptyp9 ttyqa
ptypa ttyqb
ptypb ttyqc
ptypc ttyqd
ptypd ttyqe
ptype ttyqf
ptypf ttyr0
ptyq0 ttyr1
ptyq1 ttyr2
ptyq2 ttyr3
ptyq3 ttyr4
ptyq4 ttyr5
ptyq5 ttyr6
ptyq6 ttyr7
ptyq7 ttyr8
ptyq8 ttyr9
ptyq9 ttyra
ptyqa ttyrb
ptyqb ttyrc
ptyqc ttyrd
ptyqd ttyre
ptyqe ttyrf
ptyqf ttys0
ptyr0 ttys000
ptyr1 ttys001
ptyr2 ttys1
ptyr3 ttys2
ptyr4 ttys3
ptyr5 ttys4
ptyr6 ttys5
ptyr7 ttys6
ptyr8 ttys7
ptyr9 ttys8
ptyra ttys9
ptyrb ttysa
ptyrc ttysb
ptyrd ttysc
ptyre ttysd
ptyrf ttyse
ptys0 ttysf
ptys1 ttyt0
ptys2 ttyt1
ptys3 ttyt2
ptys4 ttyt3
ptys5 ttyt4
ptys6 ttyt5
ptys7 ttyt6
ptys8 ttyt7
ptys9 ttyt8
ptysa ttyt9
ptysb ttyta
ptysc ttytb
ptysd ttytc
ptyse ttytd
ptysf ttyte
ptyt0 ttytf
ptyt1 ttyu0
ptyt2 ttyu1
ptyt3 ttyu2
ptyt4 ttyu3
ptyt5 ttyu4
ptyt6 ttyu5
ptyt7 ttyu6
ptyt8 ttyu7
ptyt9 ttyu8
ptyta ttyu9
ptytb ttyua
ptytc ttyub
ptytd ttyuc
ptyte ttyud
ptytf ttyue
ptyu0 ttyuf
ptyu1 ttyv0
ptyu2 ttyv1
ptyu3 ttyv2
ptyu4 ttyv3
ptyu5 ttyv4
ptyu6 ttyv5
ptyu7 ttyv6
ptyu8 ttyv7
ptyu9 ttyv8
ptyua ttyv9
ptyub ttyva
ptyuc ttyvb
ptyud ttyvc
ptyue ttyvd
ptyuf ttyve
ptyv0 ttyvf
ptyv1 ttyw0
ptyv2 ttyw1
ptyv3 ttyw2
ptyv4 ttyw3
ptyv5 ttyw4
ptyv6 ttyw5
ptyv7 ttyw6
ptyv8 ttyw7
ptyv9 ttyw8
ptyva ttyw9
ptyvb ttywa
ptyvc ttywb
ptyvd ttywc
ptyve ttywd
ptyvf ttywe
ptyw0 ttywf
ptyw1 urandom
ptyw2 vboxdrv
ptyw3 vboxdrvu
ptyw4 vboxnetctl
ptyw5 zero


Found out that Apple installs FTDI drivers that conflict with the VCP drivers in the Yosemite/El Capitan updates.
Will try the fix here tomorrow


No luck. Not showing up even in my apple system profiler in the USB. It’s getting the red power light though. Tried different cables.


Tried on two other computers using mac terminal to connect. No luck. Maybe my programer is fried. I ordered two new ones. If it still doesn’t work with a brand new one, then I’m curious what the missing info to install the FTDI driver is and will find out elsewhere and post to a new discussion.


Why don’t you just order an FTDI Friend from Adafruit, as Olivier recommends on the relevant web pages? It is known to work.