Skip to content

Commit e78967a

Browse files
committed
Add windows drivers
Former-commit-id: 714c67f
1 parent 71c669d commit e78967a

File tree

8 files changed

+215
-0
lines changed

8 files changed

+215
-0
lines changed

drivers/dpinst-amd64.exe

1020 KB
Binary file not shown.

drivers/dpinst-x86.exe

901 KB
Binary file not shown.

drivers/prewin10/renesas.cat

20.7 KB
Binary file not shown.

drivers/prewin10/renesas.inf

+106
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,106 @@
1+
;************************************************************
2+
; Windows USB CDC ACM Setup File
3+
; Copyright (c) 2000 Microsoft Corporation
4+
5+
6+
[Version]
7+
Signature="$Windows NT$"
8+
Class=Ports
9+
ClassGuid={4D36E978-E325-11CE-BFC1-08002BE10318}
10+
Provider=%MFGNAME%
11+
LayoutFile=layout.inf
12+
CatalogFile=%MFGFILENAME%.cat
13+
DriverVer=07/29/2018,10.0.0.0
14+
15+
[Manufacturer]
16+
%MFGNAME%=DeviceList, NTamd64
17+
18+
[DestinationDirs]
19+
DefaultDestDir=12
20+
21+
22+
;------------------------------------------------------------------------------
23+
; Windows 2000/XP/Vista-32bit Sections
24+
;------------------------------------------------------------------------------
25+
26+
[DriverInstall.nt]
27+
include=mdmcpq.inf
28+
CopyFiles=DriverCopyFiles.nt
29+
AddReg=DriverInstall.nt.AddReg
30+
31+
[DriverCopyFiles.nt]
32+
usbser.sys,,,0x20
33+
34+
[DriverInstall.nt.AddReg]
35+
HKR,,DevLoader,,*ntkern
36+
HKR,,NTMPDriver,,%DRIVERFILENAME%.sys
37+
HKR,,EnumPropPages32,,"MsPorts.dll,SerialPortPropPageProvider"
38+
39+
[DriverInstall.nt.Services]
40+
AddService=usbser, 0x00000002, DriverService.nt
41+
42+
[DriverService.nt]
43+
DisplayName=%SERVICE%
44+
ServiceType=1
45+
StartType=3
46+
ErrorControl=1
47+
ServiceBinary=%12%\%DRIVERFILENAME%.sys
48+
49+
;------------------------------------------------------------------------------
50+
; Vista-64bit Sections
51+
;------------------------------------------------------------------------------
52+
53+
[DriverInstall.NTamd64]
54+
include=mdmcpq.inf
55+
CopyFiles=DriverCopyFiles.NTamd64
56+
AddReg=DriverInstall.NTamd64.AddReg
57+
58+
[DriverCopyFiles.NTamd64]
59+
%DRIVERFILENAME%.sys,,,0x20
60+
61+
[DriverInstall.NTamd64.AddReg]
62+
HKR,,DevLoader,,*ntkern
63+
HKR,,NTMPDriver,,%DRIVERFILENAME%.sys
64+
HKR,,EnumPropPages32,,"MsPorts.dll,SerialPortPropPageProvider"
65+
66+
[DriverInstall.NTamd64.Services]
67+
AddService=usbser, 0x00000002, DriverService.NTamd64
68+
69+
[DriverService.NTamd64]
70+
DisplayName=%SERVICE%
71+
ServiceType=1
72+
StartType=3
73+
ErrorControl=1
74+
ServiceBinary=%12%\%DRIVERFILENAME%.sys
75+
76+
77+
;------------------------------------------------------------------------------
78+
; Vendor and Product ID Definitions
79+
;------------------------------------------------------------------------------
80+
; When developing your USB device, the VID and PID used in the PC side
81+
; application program and the firmware on the microcontroller must match.
82+
; Modify the below line to use your VID and PID. Use the format as shown below.
83+
; Note: One INF file can be used for multiple devices with different VID and PIDs.
84+
; For each supported device, append ",USB\VID_xxxx&PID_yyyy" to the end of the line.
85+
;------------------------------------------------------------------------------
86+
[SourceDisksFiles]
87+
[SourceDisksNames]
88+
[DeviceList]
89+
"Portenta H33"=USB_Install, USB\VID_2341&PID_0068&MI_00
90+
"Santiago"=USB_Install, USB\VID_2341&PID_0069&MI_00
91+
92+
[DeviceList.NTamd64]
93+
"Portenta H33"=USB_Install, USB\VID_2341&PID_0068&MI_00
94+
"Santiago"=USB_Install, USB\VID_2341&PID_0069&MI_00
95+
96+
;------------------------------------------------------------------------------
97+
; String Definitions
98+
;------------------------------------------------------------------------------
99+
;Modify these strings to customize your device
100+
;------------------------------------------------------------------------------
101+
[Strings]
102+
MFGFILENAME="renesas"
103+
DRIVERFILENAME ="usbser"
104+
MFGNAME="Arduino SA"
105+
INSTDISK="Arduino Renesas boards Driver Installer"
106+
SERVICE="USB RS-232 Emulation Driver"

drivers/renesas.cat

20.5 KB
Binary file not shown.

drivers/renesas.inf

+59
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
;
2+
;
3+
; Installs WinUsb
4+
;
5+
6+
[Version]
7+
Signature = "$Windows NT$"
8+
Class = USBDevice
9+
ClassGUID = {88BAE032-5A81-49f0-BC3D-A4FF138216D6}
10+
Provider = %ManufacturerName%
11+
CatalogFile = renesas.cat
12+
DriverVer = 03/03/2020,10.48.00.000
13+
14+
; ========== Manufacturer/Models sections ===========
15+
16+
[Manufacturer]
17+
%ManufacturerName% = Standard,NTamd64
18+
19+
[DeviceList.NTamd64]
20+
"Portenta H33 Bootloader"=USB_Install, USB\VID_2341&PID_0368&MI_00
21+
"Santiago Bootloader"=USB_Install, USB\VID_2341&PID_0369&MI_00
22+
23+
; ========== Class definition ===========
24+
25+
[ClassInstall32]
26+
AddReg = ClassInstall_AddReg
27+
28+
[ClassInstall_AddReg]
29+
HKR,,,,%ClassName%
30+
HKR,,NoInstallClass,,1
31+
HKR,,IconPath,%REG_MULTI_SZ%,"%systemroot%\system32\setupapi.dll,-20"
32+
HKR,,LowerLogoVersion,,5.2
33+
34+
; =================== Installation ===================
35+
36+
[USB_Install]
37+
Include = winusb.inf
38+
Needs = WINUSB.NT
39+
40+
[USB_Install.Services]
41+
Include = winusb.inf
42+
Needs = WINUSB.NT.Services
43+
44+
[USB_Install.HW]
45+
AddReg=Dev_AddReg
46+
47+
[Dev_AddReg]
48+
HKR,,DeviceInterfaceGUIDs,0x10000,"{51de5bfa-d59d-4f3e-9b36-0b4b210dd53f}"
49+
50+
; [DestinationDirs]
51+
; If your INF needs to copy files, you must not use the DefaultDestDir directive here.
52+
; You must explicitly reference all file-list-section names in this section.
53+
54+
; =================== Strings ===================
55+
56+
[Strings]
57+
ManufacturerName="Arduino"
58+
ClassName="Universal Serial Bus devices"
59+
REG_MULTI_SZ = 0x00010000

post_install.bat

+28
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
@echo off
2+
set ARGS=/SE /SW /SA
3+
if "%PROCESSOR_ARCHITECTURE%" == "AMD64" (
4+
drivers\dpinst-amd64.exe %ARGS%
5+
) ELSE IF "%PROCESSOR_ARCHITEW6432%" == "AMD64" (
6+
drivers\dpinst-amd64.exe %ARGS%
7+
) ELSE (
8+
drivers\dpinst-x86.exe %ARGS%
9+
)
10+
11+
@echo off
12+
setlocal
13+
for /f "tokens=4-5 delims=[.] " %%i in ('ver') do @(if %%i==Version (set VERSION=%%j) else (set VERSION=%%i))
14+
if %VERSION% GEQ 10 (
15+
exit /b 0
16+
)
17+
endlocal
18+
19+
REM dpinst /PATH has problems with relative paths, so use absolute path.
20+
if "%PROCESSOR_ARCHITECTURE%" == "AMD64" (
21+
drivers\dpinst-amd64.exe /PATH %cd%\drivers\prewin10 %ARGS%
22+
) ELSE IF "%PROCESSOR_ARCHITEW6432%" == "AMD64" (
23+
drivers\dpinst-amd64.exe /PATH %cd%\drivers\prewin10 %ARGS%
24+
) ELSE (
25+
drivers\dpinst-x86.exe /PATH %cd%\drivers\prewin10 %ARGS%
26+
)
27+
28+
exit /b 0

post_install.sh

+22
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
#!/usr/bin/env bash
2+
3+
rp2040rules () {
4+
echo ""
5+
echo "# Raspberry Pi RP2040 bootloader mode UDEV rules"
6+
echo ""
7+
cat <<EOF
8+
SUBSYSTEMS=="usb", ATTRS{idVendor}=="2e8a", MODE:="0666"
9+
EOF
10+
}
11+
12+
if [ "$EUID" -ne 0 ]
13+
then echo "Please run as root"
14+
exit
15+
fi
16+
17+
rp2040rules > /etc/udev/rules.d/60-rp2040.rules
18+
19+
# reload udev rules
20+
echo "Reload rules..."
21+
udevadm trigger
22+
udevadm control --reload-rules

0 commit comments

Comments
 (0)