Quando pressiono Enter, o VS Code adiciona um espaço extra (5º) ao início da nova linha - mesmo que eu tenha definido o tamanho da tabulação para 4 espaços. Como posso fazer com que ele pare de fazer isso?
Cyman's questions
Estou usando o seguinte script que não produz erros, mas também não funciona, infelizmente:
if WinActive("ahk_exe wmplayer.exe") or WinActive("ahk_exe Spotify.exe")
{
Left::Send {RCtrl}{Left}
Right::Send {RCtrl}{Right}
}
A ideia é que, pressionando uma tecla arrow quando o WMP (Windows Media Player) tem foco, o atalho global (RCtrl+Arrow) deve ser acionado, o que é definido no PowerToys para Prev/Next Track
. O atalho global funciona, mas não (ainda) via Autohotkey...
A saída do console parece estar correta?
---- M:\Software\Standalone\Apps.ahk
001: if WinActive("ahk_exe wmplayer.exe") || WinActive("ahk_exe Spotify.exe")
006: Exit (14.50)
004: Send,{RCtrl}{Right} (0.03)
004: Return (2.41)
Eu uso um atalho que roda como admin (isso é definido nas opções de atalho) para rodar um arquivo .bat que requer privilégios de admin. Agora, toda vez que ele roda, eu tenho que permitir devido à janela de aviso do Windows.
Tentei https://superuser.com/a/1613169/313763 , mas isso parece funcionar apenas para arquivos .ps1 e não .bat?
É possível executar o atalho sem precisar permiti-lo?
Depois que o Windows entrou no modo de suspensão, meus alto-falantes USB pararam de funcionar.
O que eu tentei:
- Desabilitou a economia seletiva de energia USB nas opções de energia
Soluções alternativas:
- Desconectar/reconectar o cabo USB: funciona, mas é um pouco tedioso, pois isso acontece várias vezes ao dia
- Hub USB com botão liga/desliga: funciona melhor, mas o áudio às vezes falha (provavelmente por causa do hub)
- Usando o USB Device Tree Viewer: reiniciar o dispositivo não funciona, mas reiniciar a porta funciona; no entanto, fazer isso manualmente todas as vezes também é um pouco tedioso
Nota adicional:
No meu PC antigo, os alto-falantes ainda funcionavam após o modo de hibernação se eu usasse uma porta USB muito específica, mas esse não parece ser o caso com meu PC novo. Não faço ideia do porquê.
A solução alternativa 3 pode ser automatizada para ser executada após o modo de suspensão (ou existe uma solução ainda melhor)?
O Microsoft Photos não permite navegar pelas imagens se você estiver ampliado em uma, apenas quando estiver no nível de zoom padrão. Isso é um pouco confuso, então decidi criar uma direção de chave automática para suavizar esse problema.
Como a roda de rolagem sempre navega pelos itens no Microsoft Photos (por qualquer motivo), minha lógica era sempre acionar a rolagem da roda do mouse quando uma tecla de navegação (seta) é pressionada. Em teoria, isso funciona muito bem, na realidade, porém, não funciona.
Alguem sabe por quê? A direção do Autohotkey está errada ou é outra coisa?
#IfWinActive, ahk_exe Microsoft.Photos.exe
Left::Send {WheelUp}
Right::Send {WheelDown}
#If
O problema é (e isso realmente é uma merda) que de vez em quando (sem motivo aparente) as teclas alternativas não estão funcionando no meu teclado. Eu realmente tentei TUDO (layout do teclado, suporte do fabricante do teclado, suporte da Microsoft várias vezes, ...), não funcionou. Portanto, o principal problema é que, nesse caso, não consigo pressionar o @, o que é totalmente irritante. Então, eu queria saber se eu poderia simplesmente forçar meu teclado a SEMPRE gerar um @ quando eu pressionar AltGr + 2?
Eu tentei o Microsoft PowerToys, mas lá posso apenas atribuir teclas no teclado, não símbolos. Então isso não ajuda. Provavelmente é possível com o AutoHotkey, mas não sei como fazer isso com esta ferramenta avançada. Alguma ideia?
Apenas alguns dias atrás, o Windows reconheceu meu novo disco USB (também no meu segundo PC e smart tv) - com alguns problemas, no entanto: HD USB externo não é reconhecido após o início do Windows - somente depois de plugá-lo e inseri-lo primeiro .
Agora, desde hoje, o Windows não reconhece mais o disco. Nem o gerenciamento de disco do Windows. No entanto, ele é listado no gerenciador de dispositivos:
Quando verifico com o USB Tree Viewer, posso ver o disco aparecendo com os seguintes detalhes:
=========================== USB Port2 ===========================
Connection Status : 0x01 (Device is connected)
Port Chain : 1-2
========================== Summary =========================
Vendor ID : 0x0BC2 (Seagate Technology LLC)
Product ID : 0x231A
USB version : 2.10
Port maximum Speed : High-Speed
Device maximum Speed : SuperSpeed
Device Connection Speed : High-Speed
Self Powered : no
Demanded Current : 500 mA
Used Endpoints : 5
======================== USB Device ========================
+++++++++++++++++ Device Information ++++++++++++++++++
Device Description : Per USB angeschlossenes SCSI (UAS)-Massenspeichergerät
Device Path 1 : \\?\USB#VID_0BC2&PID_231A#MSFT30NAC25CA9#{2accfe60-c130-11d2-b082-00a0c91efb8b} (GUID_DEVINTERFACE_STORAGEPORT)
Device Path 2 : \\?\USB#VID_0BC2&PID_231A#MSFT30NAC25CA9#{a5dcbf10-6530-11d2-901f-00c04fb951ed} (GUID_DEVINTERFACE_USB_DEVICE)
Kernel Name : \Device\USBPDO-16
Device ID : USB\VID_0BC2&PID_231A\MSFT30NAC25CA9
Hardware IDs : USB\VID_0BC2&PID_231A&REV_0710 USB\VID_0BC2&PID_231A
Driver KeyName : {4d36e97b-e325-11ce-bfc1-08002be10318}\0001 (GUID_DEVCLASS_SCSIADAPTER)
Driver : \SystemRoot\System32\drivers\uaspstor.sys (Version: 10.0.19041.1023 Date: 2021-06-27)
Driver Inf : C:\WINDOWS\inf\uaspstor.inf
Legacy BusType : PNPBus
Class : SCSIAdapter
Class GUID : {4d36e97b-e325-11ce-bfc1-08002be10318} (GUID_DEVCLASS_SCSIADAPTER)
Service : UASPStor
Enumerator : USB
Location Info : Port_#0002.Hub_#0007
Location IDs : PCIROOT(0)#PCI(1602)#USBROOT(0)#USB(2), ACPI(_SB_)#ACPI(PCI0)#ACPI(UHC6)#USBROOT(0)#USB(2)
Container ID : {d7c61337-0c5f-5445-b3f6-b084fcfcf042}
Manufacturer Info : Per USB angeschlossenes SCSI (UAS)-kompatibles Gerät
Capabilities : 0x14 (Removable, UniqueID)
Status : 0x0180600A (DN_DRIVER_LOADED, DN_STARTED, DN_DISABLEABLE, DN_REMOVABLE, DN_NT_ENUMERATOR, DN_NT_DRIVER)
Problem Code : 0
HcDisableSelectiveSuspend: 0
EnableSelectiveSuspend : 0
SelectiveSuspendEnabled : 0
EnhancedPowerMgmtEnabled : 0
IdleInWorkingState : 0
WakeFromSleepState : 0
Power State : D0 (supported: D0, D2, D3, wake from D0, wake from D2)
Child Device 1 : Seagate Expansion SCSI Disk Device (Laufwerk)
Device ID : SCSI\DISK&VEN_SEAGATE&PROD_EXPANSION\6&1EC56E78&0&000000
Class : DiskDrive
Driver KeyName : {4d36e967-e325-11ce-bfc1-08002be10318}\0002 (GUID_DEVCLASS_DISKDRIVE)
Service : disk
Location : Bus Number 0, Target Id 0, LUN 0
+++++++++++++++++ Registry USB Flags +++++++++++++++++
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\usbflags\0BC2231A0710
osvc : REG_BINARY 00 00
---------------- Connection Information ---------------
Connection Index : 0x02 (Port 2)
Connection Status : 0x01 (DeviceConnected)
Current Config Value : 0x01 (Configuration 1)
Device Address : 0x01 (1)
Is Hub : 0x00 (no)
Device Bus Speed : 0x02 (High-Speed)
Number Of Open Pipes : 0x04 (4 pipes to data endpoints)
Pipe[0] : EndpointID=1 Direction=OUT ScheduleOffset=0 Type=Bulk
Pipe[1] : EndpointID=2 Direction=IN ScheduleOffset=0 Type=Bulk
Pipe[2] : EndpointID=3 Direction=IN ScheduleOffset=0 Type=Bulk
Pipe[3] : EndpointID=4 Direction=OUT ScheduleOffset=0 Type=Bulk
Data (HexDump) : 02 00 00 00 12 01 10 02 00 00 00 40 C2 0B 1A 23 ...........@...#
10 07 01 02 03 01 01 02 00 01 00 04 00 00 00 01 ................
00 00 00 07 05 01 02 00 02 00 00 00 00 00 07 05 ................
82 02 00 02 00 00 00 00 00 07 05 83 02 00 02 00 ................
00 00 00 00 07 05 04 02 00 02 00 00 00 00 00 ...............
--------------- Connection Information V2 -------------
Connection Index : 0x02 (2)
Length : 0x10 (16 bytes)
SupportedUsbProtocols : 0x03
Usb110 : 1 (yes, port supports USB 1.1)
Usb200 : 1 (yes, port supports USB 2.0)
Usb300 : 0 (no, port not supports USB 3.0)
ReservedMBZ : 0x00
Flags : 0x02
DevIsOpAtSsOrHigher : 0 (Device is not operating at SuperSpeed or higher)
DevIsSsCapOrHigher : 1 (Device is SuperSpeed capable or higher)
DevIsOpAtSsPlusOrHigher : 0 (Device is not operating at SuperSpeedPlus or higher)
DevIsSsPlusCapOrHigher : 0 (Device is not SuperSpeedPlus capable or higher)
ReservedMBZ : 0x00
Data (HexDump) : 02 00 00 00 10 00 00 00 03 00 00 00 02 00 00 00 ................
---------------------- Device Descriptor ----------------------
bLength : 0x12 (18 bytes)
bDescriptorType : 0x01 (Device Descriptor)
bcdUSB : 0x210 (USB Version 2.10)
bDeviceClass : 0x00 (defined by the interface descriptors)
bDeviceSubClass : 0x00
bDeviceProtocol : 0x00
bMaxPacketSize0 : 0x40 (64 bytes)
idVendor : 0x0BC2 (Seagate Technology LLC)
idProduct : 0x231A
bcdDevice : 0x0710
iManufacturer : 0x01 (String Descriptor 1)
Language 0x0409 : "Seagate"
iProduct : 0x02 (String Descriptor 2)
Language 0x0409 : "Expansion"
iSerialNumber : 0x03 (String Descriptor 3)
Language 0x0409 : "NAC25CA9"
bNumConfigurations : 0x01 (1 Configuration)
Data (HexDump) : 12 01 10 02 00 00 00 40 C2 0B 1A 23 10 07 01 02 .......@...#....
03 01 ..
------------------ Configuration Descriptor -------------------
bLength : 0x09 (9 bytes)
bDescriptorType : 0x02 (Configuration Descriptor)
wTotalLength : 0x0055 (85 bytes)
bNumInterfaces : 0x01 (1 Interface)
bConfigurationValue : 0x01 (Configuration 1)
iConfiguration : 0x00 (No String Descriptor)
bmAttributes : 0x80
D7: Reserved, set 1 : 0x01
D6: Self Powered : 0x00 (no)
D5: Remote Wakeup : 0x00 (no)
D4..0: Reserved, set 0 : 0x00
MaxPower : 0xFA (500 mA)
Data (HexDump) : 09 02 55 00 01 01 00 80 FA 09 04 00 00 02 08 06 ..U.............
50 00 07 05 81 02 00 02 00 07 05 02 02 00 02 00 P...............
09 04 00 01 04 08 06 62 00 07 05 01 02 00 02 00 .......b........
04 24 01 00 07 05 82 02 00 02 00 04 24 02 00 07 .$..........$...
05 83 02 00 02 00 04 24 03 00 07 05 04 02 00 02 .......$........
00 04 24 04 00 ..$..
---------------- Interface Descriptor -----------------
bLength : 0x09 (9 bytes)
bDescriptorType : 0x04 (Interface Descriptor)
bInterfaceNumber : 0x00
bAlternateSetting : 0x00
bNumEndpoints : 0x02 (2 Endpoints)
bInterfaceClass : 0x08 (Mass Storage)
bInterfaceSubClass : 0x06 (SCSI transparent command set)
bInterfaceProtocol : 0x50 (Bulk-Only Transport)
iInterface : 0x00 (No String Descriptor)
Data (HexDump) : 09 04 00 00 02 08 06 50 00 .......P.
----------------- Endpoint Descriptor -----------------
bLength : 0x07 (7 bytes)
bDescriptorType : 0x05 (Endpoint Descriptor)
bEndpointAddress : 0x81 (Direction=IN EndpointID=1)
bmAttributes : 0x02 (TransferType=Bulk)
wMaxPacketSize : 0x0200 (max 512 bytes)
bInterval : 0x00 (never NAKs)
Data (HexDump) : 07 05 81 02 00 02 00 .......
----------------- Endpoint Descriptor -----------------
bLength : 0x07 (7 bytes)
bDescriptorType : 0x05 (Endpoint Descriptor)
bEndpointAddress : 0x02 (Direction=OUT EndpointID=2)
bmAttributes : 0x02 (TransferType=Bulk)
wMaxPacketSize : 0x0200 (max 512 bytes)
bInterval : 0x00 (never NAKs)
Data (HexDump) : 07 05 02 02 00 02 00 .......
---------------- Interface Descriptor -----------------
bLength : 0x09 (9 bytes)
bDescriptorType : 0x04 (Interface Descriptor)
bInterfaceNumber : 0x00
bAlternateSetting : 0x01
bNumEndpoints : 0x04 (4 Endpoints)
bInterfaceClass : 0x08 (Mass Storage)
bInterfaceSubClass : 0x06 (SCSI transparent command set)
bInterfaceProtocol : 0x62 (USB Attached SCSI - UAS)
iInterface : 0x00 (No String Descriptor)
Data (HexDump) : 09 04 00 01 04 08 06 62 00 .......b.
----------------- Endpoint Descriptor -----------------
bLength : 0x07 (7 bytes)
bDescriptorType : 0x05 (Endpoint Descriptor)
bEndpointAddress : 0x01 (Direction=OUT EndpointID=1)
bmAttributes : 0x02 (TransferType=Bulk)
wMaxPacketSize : 0x0200 (max 512 bytes)
bInterval : 0x00 (never NAKs)
Data (HexDump) : 07 05 01 02 00 02 00 .......
------------- UAS Pipe Usage Descriptor ---------------
bLength : 0x04 (4 bytes)
bDescriptorType : 0x24 (UAS Pipe Usage Descriptor)
bPipeID : 0x01 (Pipe ID=1)
bReserved : 0x00
Data (HexDump) : 04 24 01 00 .$..
----------------- Endpoint Descriptor -----------------
bLength : 0x07 (7 bytes)
bDescriptorType : 0x05 (Endpoint Descriptor)
bEndpointAddress : 0x82 (Direction=IN EndpointID=2)
bmAttributes : 0x02 (TransferType=Bulk)
wMaxPacketSize : 0x0200 (max 512 bytes)
bInterval : 0x00 (never NAKs)
Data (HexDump) : 07 05 82 02 00 02 00 .......
------------- UAS Pipe Usage Descriptor ---------------
bLength : 0x04 (4 bytes)
bDescriptorType : 0x24 (UAS Pipe Usage Descriptor)
bPipeID : 0x02 (Pipe ID=2)
bReserved : 0x00
Data (HexDump) : 04 24 02 00 .$..
----------------- Endpoint Descriptor -----------------
bLength : 0x07 (7 bytes)
bDescriptorType : 0x05 (Endpoint Descriptor)
bEndpointAddress : 0x83 (Direction=IN EndpointID=3)
bmAttributes : 0x02 (TransferType=Bulk)
wMaxPacketSize : 0x0200 (max 512 bytes)
bInterval : 0x00 (never NAKs)
Data (HexDump) : 07 05 83 02 00 02 00 .......
------------- UAS Pipe Usage Descriptor ---------------
bLength : 0x04 (4 bytes)
bDescriptorType : 0x24 (UAS Pipe Usage Descriptor)
bPipeID : 0x03 (Pipe ID=3)
bReserved : 0x00
Data (HexDump) : 04 24 03 00 .$..
----------------- Endpoint Descriptor -----------------
bLength : 0x07 (7 bytes)
bDescriptorType : 0x05 (Endpoint Descriptor)
bEndpointAddress : 0x04 (Direction=OUT EndpointID=4)
bmAttributes : 0x02 (TransferType=Bulk)
wMaxPacketSize : 0x0200 (max 512 bytes)
bInterval : 0x00 (never NAKs)
Data (HexDump) : 07 05 04 02 00 02 00 .......
------------- UAS Pipe Usage Descriptor ---------------
bLength : 0x04 (4 bytes)
bDescriptorType : 0x24 (UAS Pipe Usage Descriptor)
bPipeID : 0x04 (Pipe ID=4)
bReserved : 0x00
Data (HexDump) : 04 24 04 00 .$..
----------------- Device Qualifier Descriptor -----------------
bLength : 0x0A (10 bytes)
bDescriptorType : 0x06 (Device_qualifier Descriptor)
bcdUSB : 0x210 (USB Version 2.10)
bDeviceClass : 0x00 (defined by the interface descriptors)
bDeviceSubClass : 0x00
bDeviceProtocol : 0x00
bMaxPacketSize0 : 0x40 (64 Bytes)
bNumConfigurations : 0x01 (1 other-speed configuration)
bReserved : 0x00
Data (HexDump) : 0A 06 10 02 00 00 00 40 01 00 .......@..
---------- Binary Object Store (BOS) Descriptor -----------
bLength : 0x05 (5 bytes)
bDescriptorType : 0x0F (Binary Object Store)
wTotalLength : 0x0016 (22 bytes)
bNumDeviceCaps : 0x02
Data (HexDump) : 05 0F 16 00 02 .....
------------- USB 2.0 Extension Descriptor ------------
bLength : 0x07 (7 bytes)
bDescriptorType : 0x10 (Device Capability Descriptor)
bDevCapabilityType : 0x02 (USB 2.0 Extension)
bmAttributes : 0xF0E
LPMCapable : 1 (Link Power Management protocol is supported)
BESLAndAlternateHIRD : 1 (BESL & Alternate HIRD definitions are supported)
BaselineBESLValid : 1 (valid)
DeepBESLValid : 0 (not valid)
BaselineBESL : 15 (10000 µs)
DeepBESL : 0
Data (HexDump) : 07 10 02 0E 0F 00 00 .......
----- SuperSpeed USB Device Capability Descriptor -----
bLength : 0x0A (10 bytes)
bDescriptorType : 0x10 (Device Capability Descriptor)
bDevCapabilityType : 0x03 (SuperSpeed USB Device Capability)
bmAttributes : 0x00
Bit 0 Reserved : 0x00
Bit 1 LTM Capable : 0x00 (no)
Bit 7:2 Reserved : 0x00
wSpeedsSupported : 0x0E (Full-Speed, High-Speed, SuperSpeed)
bFunctionalitySupport : 0x01 (lowest speed with all the functionality is 'Full-Speed')
bU1DevExitLat : 0x0A (less than 10 µs)
wU2DevExitLat : 0x0020 (less than 32 µs)
Data (HexDump) : 0A 10 03 00 0E 00 01 0A 20 00 ........ .
-------------------- String Descriptors -------------------
------ String Descriptor 0 ------
bLength : 0x04 (4 bytes)
bDescriptorType : 0x03 (String Descriptor)
Language ID[0] : 0x0409 (English - United States)
Data (HexDump) : 04 03 09 04 ....
------ String Descriptor 1 ------
bLength : 0x10 (16 bytes)
bDescriptorType : 0x03 (String Descriptor)
Language 0x0409 : "Seagate"
Data (HexDump) : 10 03 53 00 65 00 61 00 67 00 61 00 74 00 65 00 ..S.e.a.g.a.t.e.
------ String Descriptor 2 ------
bLength : 0x14 (20 bytes)
bDescriptorType : 0x03 (String Descriptor)
Language 0x0409 : "Expansion"
Data (HexDump) : 14 03 45 00 78 00 70 00 61 00 6E 00 73 00 69 00 ..E.x.p.a.n.s.i.
6F 00 6E 00 o.n.
------ String Descriptor 3 ------
bLength : 0x12 (18 bytes)
bDescriptorType : 0x03 (String Descriptor)
Language 0x0409 : "NAC25CA9"
Data (HexDump) : 12 03 4E 00 41 00 43 00 32 00 35 00 43 00 41 00 ..N.A.C.2.5.C.A.
39 00 9.
Perguntas
- O que significa quando o disco é listado no gerenciador de dispositivos, mas não no Windows nem no gerenciamento de disco?
- Como posso tornar meu disco visível no Windows novamente e acessar os dados no disco?
Quando inicio o Windows, meu disco rígido USB externo não aparece:
Quando eu desligo e conecto novamente, ele aparece normalmente e permanece assim:
O que eu já verifiquei é que o Windows faz um desligamento/inicialização limpa desmarcando a inicialização rápida:
Infelizmente isso não ajuda. Também desmarquei se o Windows pode desligar esta porta USB específica:
Por fim, também desativei a economia de energia seletiva para USB nas configurações de energia:
O disco rígido USB também não aparece no Gerenciamento de disco nem no USB Tree Viewer nem no BIOS:
Agora estou ficando sem opções do que fazer. Alguma idéia de como posso fazer o Windows reconhecer este disco rígido desde o início?
Ontem, o monitor do meu pc disse que não tem nenhum sinal, mesmo que meu pc estivesse plugado como de costume. Eu até tentei um cabo diferente e uma fonte diferente (laptop), mas ainda não havia imagem, nem o menu do monitor aparecia mais. O pc e o laptop estavam bem, ambos funcionavam com a tv como tela alternativa.
No entanto, um dia depois, o monitor volta a funcionar como se nada tivesse acontecido. Isso é apenas temporário (como com falhas no disco rígido, eles se acumulam lentamente) e eu deveria considerar comprar um novo monitor (ele tem mais de 5 anos e foi usado diariamente por pelo menos 12h) ou perdi alguma coisa e o monitor está apenas multar?
Existe uma maneira de testar a integridade do monitor, pois é possível com discos rígidos com CrystalDiskInfo, por exemplo?
Eu luto com as duas instruções a seguir mencionadas nesta postagem do blog para o Windows Media Player 12 que mostra a arte da capa errada ao jogar
Em seguida (separadamente, caso contrário, você não obterá a guia Segurança) abra as propriedades de cada um no Explorer e faça uma busca detalhada na lista de controle de acesso para Todos (talvez seja necessário adicionar um).
Bem, eu não vejo "Todos", como posso adicionar esta opção "Todos"?
Agora, nas janelas ACL, marque Negar Gravação para esses arquivos
Quais opções eu tenho que marcar exatamente? Existem muitas opções disponíveis (Acesso total, Alterar, Ler, Executar, ...)
Parece que era possível antes de usar um WMP Enhancement, mas o [manual][1] que encontrei parece ser para uma versão mais antiga, já que não consigo encontrar essa opção no WMP 12.
[![Captura de tela][2]][2]
Ainda é possível reproduzir diferentes arquivos de áudio com diferentes níveis de volume normalizados automaticamente?
[1]: http://On%20https://www.windows-media-player.com/set-up-the-same-volume-level/#:~:text=1)%20In%20Windows%20Media %20Jogador,na%20%20seguindo%20tela%20foto. [2]: https://isstatic.askoverflow.dev/urKM6.png
O modo noturno do Windows 10 pode ser ativado ou desativado. Mas eu preferiria começar a ativá-lo passo a passo, como escurecer uma luz lentamente. Por exemplo, começando às 20h com 10% e adicionando 10% a cada 15 minutos ou mais. Como conseguir isso?
Estou usando um monitor externo comum com um PC e gostaria de poder ajustar o brilho do monitor automaticamente de acordo com o dia.
Portanto, pela manhã deve começar um pouco mais escuro e gradualmente ficar mais claro por volta do meio-dia. E à noite deve escurecer lentamente até a noite.
Como isso pode ser alcançado?