Tue, 21 Apr 2020 19:52:43 +0200
MicroPython: started implementing support for the "Calliope mini".
--- a/eric6/MicroPython/MicrobitDevices.py Tue Apr 21 19:47:10 2020 +0200 +++ b/eric6/MicroPython/MicrobitDevices.py Tue Apr 21 19:52:43 2020 +0200 @@ -191,9 +191,16 @@ self.microPython, self.tr("Flash MicroPython Firmware"), self.tr( - 'The BBC micro:bit is not ready for flashing. See the' - ' <a href="https://microbit.org/guide/firmware/">' - 'micro:bit web site</a> for details.' + '<p>The BBC micro:bit is not ready for flashing. Follow' + ' these instructions.</p>' + '<ul>' + '<li>unplug USB cable and any batteries</li>' + '<li>keep RESET pressed an plug USB cable back in</li>' + '<li>a drive called MAINTENANCE should be available</li>' + '</ul>' + '<p>See the ' + '<a href="https://microbit.org/guide/firmware/">' + 'micro:bit web site</a> for details.</p>' )) else: downloadsPath = QStandardPaths.standardLocations(
--- a/eric6/Preferences/ConfigurationPages/MicroPythonPage.py Tue Apr 21 19:47:10 2020 +0200 +++ b/eric6/Preferences/ConfigurationPages/MicroPythonPage.py Tue Apr 21 19:52:43 2020 +0200 @@ -103,6 +103,8 @@ Preferences.getMicroPython("CircuitPythonFirmwareUrl")) self.microbitFirmwareUrlLineEdit.setText( Preferences.getMicroPython("MicrobitFirmwareUrl")) + self.calliopeFirmwareUrlLineEdit.setText( + Preferences.getMicroPython("CalliopeFirmwareUrl")) # documentation URL self.micropythonDocuUrlLineEdit.setText( @@ -111,6 +113,8 @@ Preferences.getMicroPython("CircuitPythonDocuUrl")) self.microbitDocuUrlLineEdit.setText( Preferences.getMicroPython("MicrobitDocuUrl")) + self.calliopeDocuUrlLineEdit.setText( + Preferences.getMicroPython("CalliopeDocuUrl")) def save(self): """ @@ -158,6 +162,9 @@ Preferences.setMicroPython( "MicrobitFirmwareUrl", self.microbitFirmwareUrlLineEdit.text()) + Preferences.setMicroPython( + "CalliopeFirmwareUrl", + self.calliopeFirmwareUrlLineEdit.text()) # documentation URL Preferences.setMicroPython( @@ -169,6 +176,9 @@ Preferences.setMicroPython( "MicrobitDocuUrl", self.microbitDocuUrlLineEdit.text()) + Preferences.setMicroPython( + "CalliopeDocuUrl", + self.calliopeDocuUrlLineEdit.text()) def create(dlg):
--- a/eric6/Preferences/ConfigurationPages/MicroPythonPage.ui Tue Apr 21 19:47:10 2020 +0200 +++ b/eric6/Preferences/ConfigurationPages/MicroPythonPage.ui Tue Apr 21 19:52:43 2020 +0200 @@ -275,6 +275,20 @@ </property> </widget> </item> + <item row="3" column="0"> + <widget class="QLabel" name="label_13"> + <property name="text"> + <string>Calliope mini:</string> + </property> + </widget> + </item> + <item row="3" column="1"> + <widget class="E5ClearableLineEdit" name="calliopeFirmwareUrlLineEdit"> + <property name="toolTip"> + <string>Enter the URL for the Callope mini Firmware</string> + </property> + </widget> + </item> </layout> </widget> </item> @@ -326,6 +340,20 @@ </property> </widget> </item> + <item row="3" column="0"> + <widget class="QLabel" name="label_12"> + <property name="text"> + <string>Calliope mini:</string> + </property> + </widget> + </item> + <item row="3" column="1"> + <widget class="E5ClearableLineEdit" name="calliopeDocuUrlLineEdit"> + <property name="toolTip"> + <string>Enter the URL for the Calliope mini MicroPython documentation</string> + </property> + </widget> + </item> </layout> </widget> </item> @@ -368,9 +396,11 @@ <tabstop>micropythonFirmwareUrlLineEdit</tabstop> <tabstop>circuitpythonFirmwareUrlLineEdit</tabstop> <tabstop>microbitFirmwareUrlLineEdit</tabstop> + <tabstop>calliopeFirmwareUrlLineEdit</tabstop> <tabstop>micropythonDocuUrlLineEdit</tabstop> <tabstop>circuitpythonDocuUrlLineEdit</tabstop> <tabstop>microbitDocuUrlLineEdit</tabstop> + <tabstop>calliopeDocuUrlLineEdit</tabstop> </tabstops> <resources/> <connections/>
--- a/eric6/Preferences/__init__.py Tue Apr 21 19:47:10 2020 +0200 +++ b/eric6/Preferences/__init__.py Tue Apr 21 19:52:43 2020 +0200 @@ -1474,15 +1474,21 @@ # QChart.ChartTheme otherwise "MpyCrossCompiler": "", # path of the mpy-cross compiler "DfuUtilPath": "", # path of the dfu-util flashing tool + # documentation URLs "MicroPythonDocuUrl": "https://docs.micropython.org/en/latest/", "CircuitPythonDocuUrl": "https://circuitpython.readthedocs.io/en/latest/", "MicrobitDocuUrl": "https://microbit-micropython.readthedocs.io/en/latest/", - "MicroPythonFirmwareUrl": "http://micropython.org/download", - "CircuitPythonFirmwareUrl": "https://circuitpython.org/downloads", + "CalliopeDocuUrl": + "https://github.com/calliope-mini/calliope-mini-micropython/", + # MicroPython firmware URLs + "MicroPythonFirmwareUrl": "http://micropython.org/download/", + "CircuitPythonFirmwareUrl": "https://circuitpython.org/downloads/", "MicrobitFirmwareUrl": "https://microbit.org/guide/firmware/", + "CalliopeFirmwareUrl": + "https://github.com/calliope-mini/calliope-mini-micropython/", } if Globals.isWindowsPlatform(): microPythonDefaults["ColorScheme"] = "Windows 10"
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/eric6/icons/breeze-dark/calliope_mini.svg Tue Apr 21 19:52:43 2020 +0200 @@ -0,0 +1,50 @@ +<?xml version="1.0" encoding="UTF-8"?> +<svg id="svg8" width="48" height="48" version="1.1" viewBox="0 0 12.7 12.7" xmlns="http://www.w3.org/2000/svg"> + <g id="layer1" transform="translate(0,-284.3)"> + <g id="calliopemini" transform="matrix(.33591 0 0 .33591 -12.382 267.63)"> + <g id="g915"> + <path id="platine" d="m38.798 67.76c0.16655-0.36884 0.13639-0.31744 0.78203-0.85588s2.13-0.94191 3.2923-2.0634 2.6412-3.4107 3.1557-5.1168c0.51449-1.706 0.22218-3.5224 0.15452-4.6788-0.06765-1.1564 0.82562-1.4991 0.82562-1.4991s0.39807-0.27578 1.137-0.14823c0.73894 0.12756 0.96948 0.28462 1.8446 0.86531 0.8751 0.58068 2.1854 1.188 3.3079 1.4782 1.1225 0.29019 2.5572 0.35641 3.7706 0.21371 1.2134-0.1427 2.2616-0.78078 3.1435-1.2187 0.88195-0.4379 1.8228-1.2698 2.5131-1.4337 0.69031-0.16388 1.1315 0.0049 1.5602 0.21547 0.4287 0.21055 0.58639 0.381 0.82155 1.0126 0.23516 0.63165-0.02661 2.021 0.08822 3.1872 0.11483 1.1662 0.37648 2.5832 0.90806 3.7466 0.53158 1.1634 1.4626 2.1655 2.2986 2.9814s1.8155 1.4402 2.8207 1.929c1.0052 0.4888 1.1517 0.5548 1.4891 1.0236 0.33739 0.46884 0.41624 1.0274 0.186 1.6327-0.23025 0.60535-1.9239 1.3796-2.7725 1.8917-0.84866 0.51214-2.4034 1.8925-3.3778 3.3637-0.97437 1.4712-1.2709 3.701-1.4377 5.1008-0.16684 1.3998 0.41985 2.3275 0.02475 3.0778-0.39509 0.75026-1.032 1.0483-1.7873 1.1132s-1.6942-0.72885-2.2072-1.0413c-0.51304-0.31241-1.3535-0.79254-2.0928-0.96544-0.73928-0.1729-1.7546-0.25-2.1638-0.55844-0.4092-0.30843-0.26974-0.53758-0.42563-0.72475-0.15589-0.18717-0.27842-0.33191-0.46973-0.40616-0.19131-0.07425-0.37465-0.08732-0.55733-0.02498-0.18268 0.06234-0.35439 0.16138-0.4765 0.35499-0.12211 0.1936 0.0109 0.38462-0.29873 0.67729s-0.85168 0.16943-1.5996 0.44295c-0.74792 0.27352-2.0844 0.88026-2.833 1.3029-0.74857 0.42264-1.083 1-1.687 1.1465s-1.1856-0.0329-1.6588-0.37621c-0.47319-0.3433-0.69523-1.5039-0.69454-1.8484 6.87e-4 -0.34444 0.15832-2.1253-0.13233-3.4795-0.29066-1.3542-0.77801-2.7839-1.4721-3.8512-0.69412-1.0673-1.6371-1.8297-2.4927-2.4801-0.85555-0.65035-1.9588-0.95914-2.5482-1.4493-0.5894-0.49021-0.93222-0.80777-1.0752-1.2759s-0.03019-0.8929 0.13636-1.2617z" fill="#eff0f1" stroke-width=".051193px"></path> + <ellipse id="ecke_minus" cx="47.8" cy="54.944" rx="1.7186" ry="1.6918" fill="#eee489" stroke-width=".088711"></ellipse> + <ellipse id="path4302-6" cx="47.774" cy="54.905" rx=".77659" ry=".76448" fill="#232629"/> + <ellipse id="ecke_plus" cx="63.398" cy="54.857" rx="1.7186" ry="1.6918" fill="#eee489" stroke-width=".088711"></ellipse> + <ellipse id="path4302-6-9" cx="63.371" cy="54.819" rx=".77659" ry=".76448" fill="#232629"/> + <ellipse id="ecke_p3" cx="71.374" cy="68.31" rx="1.7186" ry="1.6918" fill="#eee489" stroke-width=".088711"></ellipse> + <ellipse id="path4302-6-2" cx="71.348" cy="68.272" rx=".77659" ry=".76448" fill="#232629"/> + <ellipse id="ecke_p2" cx="63.748" cy="81.92" rx="1.7186" ry="1.6918" fill="#eee489" stroke-width=".088711"></ellipse> + <ellipse id="path4302-6-0" cx="63.722" cy="81.882" rx=".77659" ry=".76448" fill="#232629"/> + <ellipse id="ecke_p1" cx="48.2" cy="82.192" rx="1.7186" ry="1.6918" fill="#eee489" stroke-width=".088711"></ellipse> + <ellipse id="path4302-6-3" cx="48.173" cy="82.154" rx=".77659" ry=".76448" fill="#232629"/> + <ellipse id="ecke_p0" cx="40.155" cy="68.515" rx="1.7186" ry="1.6918" fill="#eee489" stroke-width=".088711"></ellipse> + <ellipse id="path4302-6-6" cx="40.128" cy="68.477" rx=".77659" ry=".76448" fill="#232629"/> + <rect id="usb" x="54.657" y="55.959" width="2.4755" height="2.5545" fill="#232629" stroke-width=".051193"></rect> + <g id="ledmatrix" transform="matrix(.19368 0 0 .19329 34.504 31.838)" fill="#232629"> + <rect id="rect4410" x="110.41" y="152.09" width="1.0636" height="4.4517"/> + <rect id="rect4410-2" x="110.41" y="160.82" width="1.0636" height="4.4517"/> + <rect id="rect4410-6" x="110.41" y="169.8" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-1" x="110.41" y="178.53" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-1-8" x="110.41" y="187.33" width="1.0636" height="4.4517"/> + <rect id="rect4410-7" x="119.02" y="152.09" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-9" x="119.02" y="160.82" width="1.0636" height="4.4517"/> + <rect id="rect4410-6-2" x="119.02" y="169.8" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-1-0" x="119.02" y="178.53" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-1-8-2" x="119.02" y="187.33" width="1.0636" height="4.4517"/> + <rect id="rect4410-7-3" x="101.41" y="152.09" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-9-7" x="101.41" y="160.82" width="1.0636" height="4.4517"/> + <rect id="rect4410-6-2-5" x="101.41" y="169.8" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-1-0-9" x="101.41" y="178.53" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-1-8-2-2" x="101.41" y="187.33" width="1.0636" height="4.4517"/> + <rect id="rect4410-7-2" x="127.83" y="152.09" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-9-8" x="127.83" y="160.82" width="1.0636" height="4.4517"/> + <rect id="rect4410-6-2-9" x="127.83" y="169.8" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-1-0-7" x="127.83" y="178.53" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-1-8-2-3" x="127.83" y="187.33" width="1.0636" height="4.4517"/> + <rect id="rect4410-7-2-6" x="92.604" y="152.09" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-9-8-1" x="92.604" y="160.82" width="1.0636" height="4.4517"/> + <rect id="rect4410-6-2-9-2" x="92.604" y="169.8" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-1-0-7-9" x="92.604" y="178.53" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-1-8-2-3-3" x="92.604" y="187.33" width="1.0636" height="4.4517"/> + </g> + </g> + </g> + </g> +</svg>
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/eric6/icons/breeze-light/calliope_mini.svg Tue Apr 21 19:52:43 2020 +0200 @@ -0,0 +1,50 @@ +<?xml version="1.0" encoding="UTF-8"?> +<svg id="svg8" width="48" height="48" version="1.1" viewBox="0 0 12.7 12.7" xmlns="http://www.w3.org/2000/svg"> + <g id="layer1" transform="translate(0,-284.3)"> + <g id="calliopemini" transform="matrix(.33591 0 0 .33591 -12.382 267.63)"> + <g id="g973"> + <path id="platine" d="m38.798 67.76c0.16655-0.36884 0.13639-0.31744 0.78203-0.85588s2.13-0.94191 3.2923-2.0634 2.6412-3.4107 3.1557-5.1168c0.51449-1.706 0.22218-3.5224 0.15452-4.6788-0.06765-1.1564 0.82562-1.4991 0.82562-1.4991s0.39807-0.27578 1.137-0.14823c0.73894 0.12756 0.96948 0.28462 1.8446 0.86531 0.8751 0.58068 2.1854 1.188 3.3079 1.4782 1.1225 0.29019 2.5572 0.35641 3.7706 0.21371 1.2134-0.1427 2.2616-0.78078 3.1435-1.2187 0.88195-0.4379 1.8228-1.2698 2.5131-1.4337 0.69031-0.16388 1.1315 0.0049 1.5602 0.21547 0.4287 0.21055 0.58639 0.381 0.82155 1.0126 0.23516 0.63165-0.02661 2.021 0.08822 3.1872 0.11483 1.1662 0.37648 2.5832 0.90806 3.7466 0.53158 1.1634 1.4626 2.1655 2.2986 2.9814s1.8155 1.4402 2.8207 1.929c1.0052 0.4888 1.1517 0.5548 1.4891 1.0236 0.33739 0.46884 0.41624 1.0274 0.186 1.6327-0.23025 0.60535-1.9239 1.3796-2.7725 1.8917-0.84866 0.51214-2.4034 1.8925-3.3778 3.3637-0.97437 1.4712-1.2709 3.701-1.4377 5.1008-0.16684 1.3998 0.41985 2.3275 0.02475 3.0778-0.39509 0.75026-1.032 1.0483-1.7873 1.1132s-1.6942-0.72885-2.2072-1.0413c-0.51304-0.31241-1.3535-0.79254-2.0928-0.96544-0.73928-0.1729-1.7546-0.25-2.1638-0.55844-0.4092-0.30843-0.26974-0.53758-0.42563-0.72475-0.15589-0.18717-0.27842-0.33191-0.46973-0.40616-0.19131-0.07425-0.37465-0.08732-0.55733-0.02498-0.18268 0.06234-0.35439 0.16138-0.4765 0.35499-0.12211 0.1936 0.0109 0.38462-0.29873 0.67729s-0.85168 0.16943-1.5996 0.44295c-0.74792 0.27352-2.0844 0.88026-2.833 1.3029-0.74857 0.42264-1.083 1-1.687 1.1465s-1.1856-0.0329-1.6588-0.37621c-0.47319-0.3433-0.69523-1.5039-0.69454-1.8484 6.87e-4 -0.34444 0.15832-2.1253-0.13233-3.4795-0.29066-1.3542-0.77801-2.7839-1.4721-3.8512-0.69412-1.0673-1.6371-1.8297-2.4927-2.4801-0.85555-0.65035-1.9588-0.95914-2.5482-1.4493-0.5894-0.49021-0.93222-0.80777-1.0752-1.2759s-0.03019-0.8929 0.13636-1.2617z" fill="#232629" stroke-width=".051193px"></path> + <ellipse id="ecke_minus" cx="47.8" cy="54.944" rx="1.7186" ry="1.6918" fill="#eee489" stroke-width=".088711"></ellipse> + <ellipse id="path4302-6" cx="47.774" cy="54.905" rx=".77659" ry=".76448" fill="#eff0f1"/> + <ellipse id="ecke_plus" cx="63.398" cy="54.857" rx="1.7186" ry="1.6918" fill="#eee489" stroke-width=".088711"></ellipse> + <ellipse id="path4302-6-9" cx="63.371" cy="54.819" rx=".77659" ry=".76448" fill="#eff0f1"/> + <ellipse id="ecke_p3" cx="71.374" cy="68.31" rx="1.7186" ry="1.6918" fill="#eee489" stroke-width=".088711"></ellipse> + <ellipse id="path4302-6-2" cx="71.348" cy="68.272" rx=".77659" ry=".76448" fill="#eff0f1"/> + <ellipse id="ecke_p2" cx="63.748" cy="81.92" rx="1.7186" ry="1.6918" fill="#eee489" stroke-width=".088711"></ellipse> + <ellipse id="path4302-6-0" cx="63.722" cy="81.882" rx=".77659" ry=".76448" fill="#eff0f1"/> + <ellipse id="ecke_p1" cx="48.2" cy="82.192" rx="1.7186" ry="1.6918" fill="#eee489" stroke-width=".088711"></ellipse> + <ellipse id="path4302-6-3" cx="48.173" cy="82.154" rx=".77659" ry=".76448" fill="#eff0f1"/> + <ellipse id="ecke_p0" cx="40.155" cy="68.515" rx="1.7186" ry="1.6918" fill="#eee489" stroke-width=".088711"></ellipse> + <ellipse id="path4302-6-6" cx="40.128" cy="68.477" rx=".77659" ry=".76448" fill="#eff0f1"/> + <rect id="usb" x="54.657" y="55.959" width="2.4755" height="2.5545" fill="#eff0f1" stroke-width=".051193"></rect> + <g id="ledmatrix" transform="matrix(.19368 0 0 .19329 34.504 31.838)" fill="#eff0f1"> + <rect id="rect4410" x="110.41" y="152.09" width="1.0636" height="4.4517"/> + <rect id="rect4410-2" x="110.41" y="160.82" width="1.0636" height="4.4517"/> + <rect id="rect4410-6" x="110.41" y="169.8" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-1" x="110.41" y="178.53" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-1-8" x="110.41" y="187.33" width="1.0636" height="4.4517"/> + <rect id="rect4410-7" x="119.02" y="152.09" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-9" x="119.02" y="160.82" width="1.0636" height="4.4517"/> + <rect id="rect4410-6-2" x="119.02" y="169.8" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-1-0" x="119.02" y="178.53" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-1-8-2" x="119.02" y="187.33" width="1.0636" height="4.4517"/> + <rect id="rect4410-7-3" x="101.41" y="152.09" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-9-7" x="101.41" y="160.82" width="1.0636" height="4.4517"/> + <rect id="rect4410-6-2-5" x="101.41" y="169.8" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-1-0-9" x="101.41" y="178.53" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-1-8-2-2" x="101.41" y="187.33" width="1.0636" height="4.4517"/> + <rect id="rect4410-7-2" x="127.83" y="152.09" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-9-8" x="127.83" y="160.82" width="1.0636" height="4.4517"/> + <rect id="rect4410-6-2-9" x="127.83" y="169.8" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-1-0-7" x="127.83" y="178.53" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-1-8-2-3" x="127.83" y="187.33" width="1.0636" height="4.4517"/> + <rect id="rect4410-7-2-6" x="92.604" y="152.09" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-9-8-1" x="92.604" y="160.82" width="1.0636" height="4.4517"/> + <rect id="rect4410-6-2-9-2" x="92.604" y="169.8" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-1-0-7-9" x="92.604" y="178.53" width="1.0636" height="4.4517"/> + <rect id="rect4410-2-1-8-2-3-3" x="92.604" y="187.33" width="1.0636" height="4.4517"/> + </g> + </g> + </g> + </g> +</svg>