[Solved] How to ext...
 
Notifications
Clear all

[Solved] How to extract the stock recovery for HTC M8s? Do I even need it if I have the full RUU package?

0 Posts
1 Users
0 Likes
7 Views
0
Topic starter
JustAMartin Asks: How to extract the stock recovery for HTC M8s? Do I even need it if I have the full RUU package?
While I'm currently fully on stock, is there any way to extract the stock recovery now, before I replace it with TWRP? Do I even need to do that if I have entire RUU zip or will recovery be restored when I flash the ZIP through htc_fastboot?

I have seen links to ruu.lalleman.net with stock recoveries and RUUs, but the links are dead now.

My HTC M8s is fully stock now and I want to try Lineage 15.1 from index · powered by h5ai 0.27.0 ( http://larsjung.de/h5ai/) (unless you can suggest some even more stable ROM with at least Android 7). I found twrp-3.2.3-0-m8qlul.img also on the same website, and also MindTheGapps-8.1.0-arm-20180808_153837.zip, so it should all work together nicely (I hope).

But before I go on, I want to make sure I can return back to stock. So, I have obtained RUU 0PKVIMG_M8_QL_UL_M60_SENSE70_MR_HTC_Europe_2.21.401.1_Radio_1.0.U20410.1@60201_20.05_018_F_release_496316_signed_2_4.zip that matches my radio number and currently installed mainver number. However, I can't find the stock recovery anywhere.

Here's my fastboot info:

Code:
fastboot getvar all
(bootloader) version: 0.5
(bootloader) version-bootloader: 3.19.0.0000
(bootloader) version-baseband: 1.0.U20410.1@60201
(bootloader) version-cpld: None
(bootloader) version-microp: None
(bootloader) version-main: 2.21.401.1
(bootloader) version-misc: PVT SHIP S-ON
(bootloader) serialno: -
(bootloader) imei: -
(bootloader) imei2: Not Support
(bootloader) meid: 00000000000000
(bootloader) product: m8ql_ul
(bootloader) platform: hTCBmsm8939
(bootloader) modelid: 0PKV10000
(bootloader) cidnum: HTC__001
(bootloader) battery-status: good
(bootloader) battery-voltage: 0mV
(bootloader) partition-layout: Generic
(bootloader) security: on
(bootloader) build-mode: SHIP
(bootloader) boot-mode: FASTBOOT
(bootloader) commitno-bootloader: 0b9a12e3
(bootloader) hbootpreupdate: 11
(bootloader) gencheckpt: 0
(bootloader) mfg-name: 0001

Ten-tools.com may not be responsible for the answers or solutions given to any question asked by the users. All Answers or responses are user generated answers and we do not have proof of its validity or correctness. Please vote for the answer that helped you in order to help others find out which is the most helpful answer. Questions labeled as solved may be solved or may not be solved depending on the type of question and the date posted for some posts may be scheduled to be deleted periodically. Do not hesitate to share your response here to help other visitors like you. Thank you, Ten-tools.

 

 


 

Unreplied Posts

[Solved] In Linux guest on windows host: filelocks created by emacs inhibit editing of corresponding files using emacs and are unremovable

cruxl Asks: In Linux guest on windows host: filelocks created by emacs inhibit editing of corresponding files using emacs and are unremovable
After upgrading virtual box guest to Debian 11 on windows 10 host and updating all emacs packages I was not able to edit org files in a shared folder for which earlier a filelock was created and not removed even though I’m certainly the only user on this virtual machine. Emacs works fine when creating and editing new files.

I tried to sudo rm -f, but Operation was not permitted. lsattr and sudo chattr -i resulted in Operation not supported.

Editing and saving in emacs did not remove filelocks. However, I was able to edit them using nano. How to clean up this annoying mess?

Ten-tools.com may not be responsible for the answers or solutions given to any question asked by the users. All Answers or responses are user generated answers and we do not have proof of its validity or correctness. Please vote for the answer that helped you in order to help others find out which is the most helpful answer. Questions labeled as solved may be solved or may not be solved depending on the type of question and the date posted for some posts may be scheduled to be deleted periodically. Do not hesitate to share your response here to help other visitors like you. Thank you, Ten-tools.
 
 
 

[Solved] Add HTML input tag to to site navigation

Stephen Asks: Add HTML input tag to to site navigation
I’m building a site using the twentytwelve theme. I need to add an input text box situation on the far left of the menu navigation bar. Here is the HTML from Header.php and the css from style.css.

HTML

Code:
<nav id="site-navigation" class="main-navigation" role="navigation">

        <h3 class="menu-toggle"><?php _e( 'Menu', 'twentytwelve' ); ?></h3>

        <a class="assistive-text" href="#content" title="<?php esc_attr_e( 'Skip to content', 'twentytwelve' ); ?>"><?php _e( 'Skip to content', 'twentytwelve' ); ?></a>

        <?php wp_nav_menu( array( 'theme_location' => 'primary', 'menu_class' => 'nav-menu' ) ); ?>

    </nav><!-- #site-navigation --

CSS:

Code:
.main-navigation ul.nav-menu,
.main-navigation div.nav-menu > ul {
    border-bottom: 1px solid #000000;
    border-top: 1px solid #000000;
    display: inline-block !important;
    text-align: left;
    width: 100%;
    background-color: #000000;
    text-align: right;
    font-size: 50%;
    position: relative;
}
.main-navigation ul {
    margin: 0;
    text-indent: 0;

}
.main-navigation li a,
.main-navigation li {
    display: inline-block;
    text-decoration: none;

}
.main-navigation li a {
    font-size: 120%;
    font-family: 'calibri';
    border-bottom: 0;
    color: #ffffff;
    line-height: 3.692307692;
    text-transform: uppercase;
    white-space: nowrap;

}

Can anyone help me get an input text and form embedded into the nav bar? I’ll use this for customers to give me their email address.

Ten-tools.com may not be responsible for the answers or solutions given to any question asked by the users. All Answers or responses are user generated answers and we do not have proof of its validity or correctness. Please vote for the answer that helped you in order to help others find out which is the most helpful answer. Questions labeled as solved may be solved or may not be solved depending on the type of question and the date posted for some posts may be scheduled to be deleted periodically. Do not hesitate to share your response here to help other visitors like you. Thank you, Ten-tools.

 

 


 

[Solved] MySQL query posts by Tag and Category?

GenesisBits Asks: MySQL query posts by Tag and Category?
I’m building a custom API for my site that will query WordPress posts. My current query is as follows:

Code:
SELECT p.ID, p.post_title, p.post_author, p.post_date, p.post_excerpt
FROM wph3_posts p
INNER JOIN wph3_term_relationships t ON p.ID = t.object_id
INNER JOIN wph3_term_taxonomy tx ON t.term_taxonomy_id = tx.term_taxonomy_id
INNER JOIN wph3_terms tt ON tx.term_id = tt.term_id
WHERE p.post_status = "publish"
AND 1=1 
AND (tt.slug LIKE 'dragon' AND tx.taxonomy = 'post_tag') 
AND (tt.slug LIKE 'decks' AND tx.taxonomy = 'category') 
ORDER BY p.post_date DESC LIMIT 20 OFFSET 0

I’m struggling to search by both tag and category simultaneously

Code:
AND (tt.slug LIKE 'dragon' AND tx.taxonomy = 'post_tag') 
AND (tt.slug LIKE 'decks' AND tx.taxonomy = 'category')

If I exclude either one of those lines, it will search by either the tag or the category. I can’t seem to get them working together.

Any help would be appreciated!

Ten-tools.com may not be responsible for the answers or solutions given to any question asked by the users. All Answers or responses are user generated answers and we do not have proof of its validity or correctness. Please vote for the answer that helped you in order to help others find out which is the most helpful answer. Questions labeled as solved may be solved or may not be solved depending on the type of question and the date posted for some posts may be scheduled to be deleted periodically. Do not hesitate to share your response here to help other visitors like you. Thank you, Ten-tools.

 

 


 

[Solved] Shift in raster in python 3.6

Anna Riling Asks: Shift in raster in python 3.6
I have a python script for a color anomaly detection study. I am attempting to create two rasters each with three classes: one raster representing a “target” and the other representing “background”, or all pixels except those within the target extent. I have tried using a Con(IsNull()) statement as well as ExtractByMask to create the “donut hole” where the target is in the background raster. These methods work, except that the background raster is shifted a few feet to the northwest. The target raster is in the right spot, however. I have created other rasters in the script prior to this step and all are in the correct location geographically. I set the extent, snapRaster, and cellSize to an original “spectral index” raster. Entire code is below.

Why am I seeing a shift in this one and only raster, and how do I prevent it?


Resulting background raster is created correctly, but shifted to the northwest a few feet

Code:
import arcpy
from arcpy import env
from arcpy.sa import *
import numpy as np
from arcpy import os

# To allow overwriting the outputs change the overwrite option to true.
env.overwriteOutput = True

arcpy.CheckOutExtension("spatial")

# define main directory
main_dir = "F:\color_anomaly_workspace\"
env.workspace = main_dir

# read in main ortho dataset
ortho = Raster("F:\color_anomaly_workspace\purple.tif")

# read in our clippers
# clipper = "D:\Google Drive\School\Color Anomaly Detection\GIS\Backgrounds\color_anomaly\color_anomaly.gdb\ortho_clip4"
bg_clipper = "D:\Google Drive\School\Color Anomaly Detection\GIS\Backgrounds\color_anomaly\color_anomaly.gdb\background_clip"
targets = "D:\Google Drive\School\Color Anomaly Detection\GIS\Backgrounds\color_anomaly\color_anomaly.gdb\target_footprint"

# clip the mosaic to the clipper extent
ortho_clip = arcpy.Clip_management(ortho, "241896.71980000008 4137828.0887 241956.74800000008 4137967.415", "purple_clip.tif")

# create indices
basename = arcpy.Describe(ortho_clip).catalogPath
b1 = Raster(basename + "\Band_1")
b2 = Raster(basename + "\Band_2")
b3 = Raster(basename + "\Band_3")

r = Float(b1)
r.save("index_r")
print("writing index_r")

g = Float(b2)
g.save("index_g")
print("writing index_g")

# create CSV
with open("F:\color_anomaly_workspace\results_purple.csv", "w") as csv:
    csv.write("index,sd,plus_minus,tp,fn,bg_anomaly,bg_not_anomalyn")
    print("wrote csv")

# add indices to a list and then begin loop
index_list = [r, g]
print("begin loop")

for index in index_list:
    # calculate focal mean of spectral index
    index_focal = FocalStatistics(index, NbrRectangle(600, 600, "CELL"), "MEAN")
    basename = arcpy.Describe(index).basename
    index_focal.save(basename + "_focal")

    # perform image difference
    diff = index_focal - index
    diff.save(basename + "_diff")

    # get mean and SD
    mean = float(arcpy.GetRasterProperties_management(diff, "MEAN").getOutput(0))
    sd = float(arcpy.GetRasterProperties_management(diff, "STD").getOutput(0))
    min1 = float(arcpy.GetRasterProperties_management(diff, "MINIMUM").getOutput(0))
    max1 = float(arcpy.GetRasterProperties_management(diff, "MAXIMUM").getOutput(0))

    # begin reclassification loop
    multipliers = np.arange(0.50, 1.1, 0.5)
    for multiplier in multipliers:
        high_threshold = mean + multiplier * sd
        low_threshold = mean - multiplier * sd

        # set extent
        arcpy.env.extent = "MAXOF"
        arcpy.env.snapRaster = index
        arcpy.env.cellSize = index

        # reclassify raster
        rc = [[min1, low_threshold, 1],
              [low_threshold, high_threshold, 2],
              [high_threshold, max1, 3]]

        diff_rc = Reclassify(diff, "Value", RemapRange(rc))
        diff_rc.save(basename + "_diff_rc.tif")

        # select out just purple target polygons
        targets_purple = arcpy.Select_analysis(targets, "target_purple", "color = 'purple'")
        arcpy.AddField_management(targets_purple, "raster_id", "SHORT")
        arcpy.CalculateField_management(targets_purple, "raster_id", 1, "PYTHON")
        targets_rast = arcpy.PolygonToRaster_conversion(targets_purple, "raster_id", "targets_purple_rast.tif")

        # clip raster to target extent
        multiplier_name = str(round(int(multiplier * 100),0)).rjust(3,"0")
        diff_rc_target = ExtractByMask(diff_rc, targets_rast)
        diff_rc_target.save(basename + multiplier_name + "_target.tif")

        # convert background clip polygon to raster
        arcpy.AddField_management(bg_clipper, "raster_id", "SHORT")
        arcpy.CalculateField_management(bg_clipper, "raster_id", 1, "PYTHON")
        bg_clipper_rast = arcpy.PolygonToRaster_conversion(bg_clipper, "raster_id", "background_clip_rast.tif")

        # create background raster
        diff_rc_background = ExtractByMask(diff_rc, bg_clipper_rast)
        diff_rc_background.save(basename + multiplier_name + "_background.tif")

        # build attribute table to get cell counts
        arcpy.BuildRasterAttributeTable_management(diff_rc_target)
        arcpy.BuildRasterAttributeTable_management(diff_rc_background)

arcpy.CheckInExtension("spatial")

Ten-tools.com may not be responsible for the answers or solutions given to any question asked by the users. All Answers or responses are user generated answers and we do not have proof of its validity or correctness. Please vote for the answer that helped you in order to help others find out which is the most helpful answer. Questions labeled as solved may be solved or may not be solved depending on the type of question and the date posted for some posts may be scheduled to be deleted periodically. Do not hesitate to share your response here to help other visitors like you. Thank you, Ten-tools.

 

 


 

[Solved] What is the purpose of BAV70 in this schematic?

Singe Asks: What is the purpose of BAV70 in this schematic?
I’ve found this schematic for an Arduino board:


enter image description here

What is the purpose of the two diodes (BAV70) in these two applications?


2021 addendum (RGB)

This is Sparkfun’s Arduino Mini 05 which is based on an ATMega328. Full schematic here.


Mini 05 schematic

(click image to see it full size)

Ten-tools.com may not be responsible for the answers or solutions given to any question asked by the users. All Answers or responses are user generated answers and we do not have proof of its validity or correctness. Please vote for the answer that helped you in order to help others find out which is the most helpful answer. Questions labeled as solved may be solved or may not be solved depending on the type of question and the date posted for some posts may be scheduled to be deleted periodically. Do not hesitate to share your response here to help other visitors like you. Thank you, Ten-tools.

 

 


 

[Solved] Building DIY TrackIR, need wiring help

Ferkner Asks: Building DIY TrackIR, need wiring help
I’m attempting to build a homemade head tacking unit for use in computer games using infrared LEDs for my kid. I followed one tutorial where they were wired in parallel. After doing more research, I read posts on here and on Nuts & Volts that wiring LEDs in parallel is not ideal because one or more LEDs will hog the current. This appears to be true because the one LED with the longest distance from the power source always seems dimmer.

I figured out the resistance needed to wire the LEDs in parallel. There are three LEDs with a forward voltage of 1.2V and a continuous forward current of 100mA. They are powered by a 3V source (two AA batteries), requiring a resistance of 6 ohms.

If I wire them in series, the LEDs take more voltage (3.6) than the batteries can supply. I don’t want to move to a bigger battery box as this is head mounted. Can the LEDs still work with a bit less voltage. I did a quick test and they did not seem to light up. Maybe moving to a 9V battery is an option, but those things are far more expensive than AAs :)

If I am stuck with wiring in parallel I read it’s better to put a resistor on each LED diode. How do I calculate the resistor value I on each LED. I know wiring resistors in parallel halves their resistance (thanks Element14!), so if there are three paths, do I need 18 ohm resistors at each LED to get to the 6 overall ohms the circuit needs?

Yes, I am very new to all of this.

Ten-tools.com may not be responsible for the answers or solutions given to any question asked by the users. All Answers or responses are user generated answers and we do not have proof of its validity or correctness. Please vote for the answer that helped you in order to help others find out which is the most helpful answer. Questions labeled as solved may be solved or may not be solved depending on the type of question and the date posted for some posts may be scheduled to be deleted periodically. Do not hesitate to share your response here to help other visitors like you. Thank you, Ten-tools.

 

 


 

[Solved] What are the different types of controllers in control system?

ert Asks: What are the different types of controllers in control system?
What are the different types of controllers in control system?

By my study, i am able to understand that there are only two main types:

  1. On-off controller

  2. PID controller

Please guide me,Are there any other types also?

Ten-tools.com may not be responsible for the answers or solutions given to any question asked by the users. All Answers or responses are user generated answers and we do not have proof of its validity or correctness. Please vote for the answer that helped you in order to help others find out which is the most helpful answer. Questions labeled as solved may be solved or may not be solved depending on the type of question and the date posted for some posts may be scheduled to be deleted periodically. Do not hesitate to share your response here to help other visitors like you. Thank you, Ten-tools.

 

 


 

[Solved] Lightning Web Component Slots in App Builder

Tiaan Swart Asks: Lightning Web Component Slots in App Builder
Need some help, not even sure if this is possible…

In Lightning App Builder, the standard tabs component has “Slots” where tab content can be placed.

My question, is this available for LWC through slots?

I have tried adding <slot><slot> to a component and tried dragging other components into it in the Builder, the UI does not allow this action though.

Ten-tools.com may not be responsible for the answers or solutions given to any question asked by the users. All Answers or responses are user generated answers and we do not have proof of its validity or correctness. Please vote for the answer that helped you in order to help others find out which is the most helpful answer. Questions labeled as solved may be solved or may not be solved depending on the type of question and the date posted for some posts may be scheduled to be deleted periodically. Do not hesitate to share your response here to help other visitors like you. Thank you, Ten-tools.

 

 


 

[Solved] How to set my custom view as Default view admin grid Magento 2

kanidhaya Asks: How to set my custom view as Default view admin grid Magento 2
I want to set my custom view as Default view the admin grid section. I tried by saving the view but that is only per user. I want to set it for all the users.

Ten-tools.com may not be responsible for the answers or solutions given to any question asked by the users. All Answers or responses are user generated answers and we do not have proof of its validity or correctness. Please vote for the answer that helped you in order to help others find out which is the most helpful answer. Questions labeled as solved may be solved or may not be solved depending on the type of question and the date posted for some posts may be scheduled to be deleted periodically. Do not hesitate to share your response here to help other visitors like you. Thank you, Ten-tools.

 

 


 

[Solved] How do I use API versioning?

Matt Korostoff Asks: How do I use API versioning?
I’m using the Services module to produce a REST API. According to the official documentation, there is a way to version services resources. I believe version here means supplying a single API (e.g. example.com/api) and allowing clients to specify which version they want per resource with headers.

So I think that means that these two requests would return different results, despite living at the same URL:

Version 1.0:

Code:
POST /api/v1/system/set_variable HTTP/1.1
Host: example.com
Accept: application/json
Content-Type: application/json

Version 1.2:

Code:
POST /api/v1/system/set_variable HTTP/1.1
Host: example.com
Accept: application/json
Content-Type: application/json
services_system_set_variable_version: 1.2

I cannot make this work for the life of me. Here are the steps I took:

  1. Enabled the system/set_variable service

    {
    “lightbox_close”: “Close”,
    “lightbox_next”: “Next”,
    “lightbox_previous”: “Previous”,
    “lightbox_error”: “The requested content cannot be loaded. Please try again later.”,
    “lightbox_start_slideshow”: “Start slideshow”,
    “lightbox_stop_slideshow”: “Stop slideshow”,
    “lightbox_full_screen”: “Full screen”,
    “lightbox_thumbnails”: “Thumbnails”,
    “lightbox_download”: “Download”,
    “lightbox_share”: “Share”,
    “lightbox_zoom”: “Zoom”,
    “lightbox_new_window”: “New window”,
    “lightbox_toggle_sidebar”: “Toggle sidebar”
    }

    system
  2. Added the following code to mymodule.module (cribbed directly from services.versions.api.php)

.

Code:
function _system_resource_set_variable_update_1_1() {
  $new_set = array(
    'help' => 'Create a node with an nid test',
  );
  return $new_set;
}

function _system_resource_set_variable_update_1_2() {
  $new_set = array(
    'help' => 'Create a node with an nid optional prams.',
    'args' => array(
      array(
        'name' => 'name',
        'optional' => TRUE,
        'source' => array('data' => 'name'),
        'description' => t('The name of the variable to set.'),
        'type' => 'string',
      ),
      array(
        'name' => 'value',
        'optional' => TRUE,
        'source' => array('data' => 'value'),
        'description' => t('The value to set.'),
        'type' => 'string',
      ),
    ),
  );
  return $new_set;
}

  1. Cleared cache
  2. Attempted to use the system/set_variable service with postman.
  3. Saw that the system/set_variable service was working

    postman
  4. Attempted to use the system/set_variable service without arguments, per _system_resource_set_variable_update_1_2

  5. Saw that arguments were still required
    postman1

So what am I doing wrong here? I’m pretty sure I followed all the instructions.

Ten-tools.com may not be responsible for the answers or solutions given to any question asked by the users. All Answers or responses are user generated answers and we do not have proof of its validity or correctness. Please vote for the answer that helped you in order to help others find out which is the most helpful answer. Questions labeled as solved may be solved or may not be solved depending on the type of question and the date posted for some posts may be scheduled to be deleted periodically. Do not hesitate to share your response here to help other visitors like you. Thank you, Ten-tools.

 

 


 

Share: